Questions tagged [htaccess]

The most common name of the per-directory settings file for the Apache server. WordPress stores the mod_rewrite configuration for "Pretty Permalinks" here. [url-rewriting] should be used for the WordPress rewrite system in general, [mod-rewrite] when you talk specifically about the Apache module.

Filter by
Sorted by
Tagged with
1
vote
1answer
139 views

WP install in sub-dir white screen

My WP moved from localhost to online, and now it shows a blank page (wp-admin is working normally). This is the structure: sub.domain.nl/dir1/dir2/WP-install Something must me off with the ...
1
vote
0answers
475 views

React Router with Wordpress

I am using React Router (React app in a home page) with WordPress. The problem is when a user first loads a page with client URL route, for example site . com/recommendations, they see a 404 error. I ...
1
vote
1answer
88 views

.htaccess too many redirects based on category slug

I moved my wordpress page up a directory and also changed a bunch of categories with new names. But when I try to set a 301 redirect via .htaccess and then access that category url, the browser errors ...
0
votes
0answers
104 views

Redirect after login when WordPress in subdirectory

I've a problem in my Wordpress website which is after I login from /wp-admin I didn't redirected to anywhere just keep seeing the login page without any errors. it was working fine when the site was ...
0
votes
1answer
673 views

Rewrite Page Parameters

i have a page call "city" http://localhost/wordpress/city/ and it get details from mysql by url id like http://localhost/wordpress/city/?id=paris and i want to change it like http://localhost/...
2
votes
3answers
356 views

Cannot mask WordPress page URL using .htaccess

.htaccess: <IfModule mod_rewrite.c> RewriteEngine On RewriteBase /wp_test/ RewriteRule ^index\.php$ - [L] RewriteRule ^the_image$ wp-content/uploads/2019/01/banner\.jpg [L] RewriteRule ^...
1
vote
2answers
91 views

How to change old permalink?

My old permalink structure is /index.php/%year%/%monthnum%/%day%/%postname%/. For example: https://example.com/index.php/2019/01/08/technological-innovation-for-agriculture-sector-in-india/ but I ...
1
vote
1answer
39 views

How To Fix 404 errors caused by Google Indexing Wordpress In Subdirectory

I moved WordPress out of the root of my server into a special folder of its own and now Google is indexing my posts together with that special WordPress folder thus creating some 404 error issues. ...
1
vote
2answers
89 views

Cleanup URL for a custom page in wordpress

I have a wordpress website in which I have a specific page for dictionary. This page is actually a custom page and does these things: site.com/dictionary lists all the words site.com/dictionary/?w=...
2
votes
2answers
38 views

HTAccess stops me from accessing WordPress Dashboard links

I have a WP site which I have not looked at for a while. I have just logged in to update aspects of it, including WP itself, now on 5.0.2. Now if I click on any of the Dashboard links - Posts, ...
1
vote
1answer
556 views

How can I fix the redirect chain after implementing ssl on wordpress?

After implementing ssl on wordpress, I wanted to force a redirection to a site with the following characteristics: non www, ssl, with trailing slash Unfortunately it only works in some cases. For ...
1
vote
1answer
21 views

redirect automatic page that serves custom posttype content

I registered blog as a custom post type. This content is queried on the page page-actueel-blog. But mydomain.com/blog also serves content (by default titles are queried). I don't want visitors to ...
0
votes
1answer
796 views

I can't access login page

I was copying my web from live host, but when I want to access admin dashboard, the url can't be accessed The url is changed to be like this : http://backstagewhisp.local/wp-admin/backstagewhisp....
2
votes
2answers
191 views

Setup Permanent 301 Redirects after moving to Https [closed]

i moved my site from http to https now i want to redirect the user into the new url but evry time i'm trying to edit .htaccess file i'm getting an error this is the working file content where xxxz ...
0
votes
1answer
400 views

How to use slug with subdomain?

I've migrated a Hubspot blog to a Wordpress site but now need to use the same subdomain that was used for the Hubspot blog on the new Wordpress site. Hubspot url: blog.sitename.com/blog/post-name ...
1
vote
0answers
19 views

Can't control Wordpress Addresses from admin panel

I have already created several sites in WordPress and I have always been able to manage the link of my site with or without https and with or without www through the settings in options > general, as ...
1
vote
1answer
126 views

WordPress multisite .htaccess causes 500 error on old *.php URLs

I have setup a new multisite WordPress install. Everything works fine, except Google is still crawling old URLs (which had a .php extension). These URLs are now showing a 500 error, which seems to be ...
1
vote
2answers
5k views

External content won't load in iframe in Safari

I'm trying to load external content into an iframe, & it is working in Chrome & Firefox, but it won't load in Safari. In Safari I get the error message: Refused to display 'my_content' in a ...
0
votes
1answer
97 views

Pretty URL via Rewrite

I'm building a dynamically populated profile page for my site users. This currently uses the following URL structure: https://example.com/members-list-profile/?&uid=XX I'd like to improve the ...
1
vote
0answers
42 views

joomla to wordpress migration and 404 errors issues [closed]

I had migrated my website from Joomla to WordPress with "FG Joomla to WordPress premium" the problem is that I have more than 2900 posts in my website they all are now imported in WordPress version ...
1
vote
2answers
51 views

Redirecting old permalink structure to new in htaccess

I recently changed the permalink structure on my 2-month-old blog to a user friendly one which means a whole bunch of 404s. I wish to redirect the following: https://example.com/poastname.html to ...
0
votes
0answers
62 views

URL Rewrite 404

I've got the following ReWrite rule: add_rewrite_rule("details\/([a-zA-Z0-9_]+)\/.*", "detail/?id=$matches[1]", "top"); Which seems to be adding in the following to my .htaccess, which now looks ...
1
vote
1answer
40 views

.htaccess rule to redirect old URLs to new structure [closed]

The old URLs were in the form: https://www.example.com/collection/item/item-name-123 The new URLs are in the form: https://www.example.com/collection/item/123 I'm attempting to redirect any hits ...
0
votes
2answers
2k views

main-domain of wordpress keep redirecting to subdomain

I was in process of deploying my wordpress website mysite.com/NewSite to mysite.com during the deployment I messed up something and my main site has started redirecting from mysite.com to mysite.com/...
0
votes
1answer
133 views

How to disable all logins except Network login in WordPress Multi site?

I have N number of sites in WordPress multi-site. I want to restrict individual site login i.e., http://www.example.com/site1/wp-admin http://www.example.com/site2/wp-admin Only Network admin can ...
0
votes
1answer
99 views

After moving Wordpress to its own directory, login doesn't work

My site keeps getting hacked, so I decided to move WordPress to its own directory so that I can generate and use static pages in the main directory with Simply Static. I am trying to move WordPress ...
1
vote
1answer
41 views

Unable to access folders in same level as wordpress installation

I've got the following structure www/ .htaccess /website1 /website2 /uploads/foo.pdf /websiteWP .htaccess .htacces in root (www/.htaccess) <IfModule mod_rewrite.c> RewriteEngine ...
1
vote
1answer
102 views

How disable canonical redirect wp-signup

I use wordpress 4.9.8. I want to close user access to site.com/wp-signup.php I added code in .htaccess <Files wp-signup.php> Order Allow,Deny Deny from all </Files> When I go to site.com/...
2
votes
1answer
169 views

How to install WordPress Multisite with different domains under the same subdirectory?

Currently I have a WordPress blog with one domain as following: http://example.com/blog All WordPress files are under blog directory. Now I want to create another site using WordPress Multisites ...
2
votes
2answers
62 views

.htaccess redirects no longer work

In May of 2016, I implemented several redirects on a client site using .htaccess. The client verified that all of the .htaccess redirects were working to their satisfaction before we closed out the ...
1
vote
2answers
448 views

How do I test to ensure that my wp-config file is protected?

Since order allow,deny is deprecated in 2.4 I wanted to rewrite the rules in my .htaccess file to use the new rules. Previously I was using: <files wp-config.php> order allow,deny deny ...
1
vote
1answer
309 views

WordPress keeps redirecting subpages without http to https homepage after switch

I just updated my WordPress site to a full SSL certificate. Everything is working as expected. Only 1 issue I can't solve. After the update I noticed the homepage is being redirected as expected but ...
1
vote
0answers
19 views

Wordpress sites in subfolders

I have a slightly different question to the usual 'how to put WP into a subfolder' I have two completely separate variants of the same WP site online - a live and a test one. The sites are in ...
1
vote
1answer
43 views

How to write .htaccess so that https is on for subpages only but not the home page

The root of my domain successfully redirects to a subdirectory, meaning example.com redirects to example.com/abc. example.com has no WordPress install. example.com/abc has its own WordPress install. ...
0
votes
2answers
190 views

Redirect only PDFs in different folders?

I need some help with google indexing old PDF pages. Here is the situation: I have a new URL of new.example.com. The website was rebuilt and the company name has changed. The URL used to be old....
0
votes
2answers
30 views

I used single quote to design HTML of my WordPress blog. Now site redirects to index.php everytime than page.php or single.php

I am actually building a custom theme for my blog and I use single quotes for HTML everywhere like: <div class='div'></div> Does this cause me redirection to index.php?? My site ...
1
vote
3answers
706 views

Force www to non-www on a subdomain in WordPress?

Forcing www to non-www is simple at the primary domain level. What about at the subdomain level? If I am correct the "issue" is that it is at two levels of depth so you can't force a subdomain to be ...
7
votes
3answers
1k views

Does this .htaccess security setting really work?

What does this .htaccess do? Am I correct in thinking that all it does is prevent automatic brute force attacks? So, to access the wp-login.php you have to manually type in the URL of the domain so ...
2
votes
0answers
68 views

Alias 'wp-content' directory to something shorter (framework?)

I recall seeing this as a feature of a Wordpress Development Framework, so I know it's possible (can't remember the framework). I am interested in how to condense the Wordpress-generated urls to ...
1
vote
2answers
410 views

How to redirect subcategories to a page?

I want to redirect all subcategories who belong to the category named symptoms to a same page. I did this: RewriteRule ^category/symptoms/(.*)$ https://my-site/com/list/$1 [L,R=301] Wordpress ...
0
votes
1answer
154 views

Non-wordpress subdomain on Multisite Installation

I have Wordpress multisite and I want to exclude one subdomain from multisite. I am a little bit confused. Wordpress multisite directory: /var/www/XYZ (domain example.com, subdomain: 1subdomain....
1
vote
0answers
153 views

How do I configure wordpress structure for development using git and composer

I've been developing in other languages and web frameworks and I'm now starting with a Wordpress project. I'm used to using git and a package manager, but Wordpress development poses some unique ...
0
votes
1answer
508 views

Unable leverage Browser Caching on AWS Bitnami stack (Apache) through W3TC and Cloudfront CDN

I followed many tutorial about leveraging browser caching nevertheless I couldn't configure it succesfully, in fact GTmetric (PageSpeed and YSlow) notified me many static file that don't have a cache ...
1
vote
0answers
11 views

Admin Panel Slowdown After SSL Verification

a few days ago I did SSL verification for my website. I've imported the following rules on IIS after receiving the http 500 error frequently today. <rule name="Imported Rule 1"> ...
1
vote
1answer
164 views

Https Redirect infinite loop in Mobile browsers

I have recently installed SSL on my website and made some changes in htaccess to rewrite http to https routes. It is working perfectly fine in desktop browsers but not in Mobile browsers. Not sure ...
1
vote
1answer
51 views

Redirect All Search Links Containing - to + on Wordpress

I deleted all my wordpress tags via phpmyadmin, and most of my post content contains tag links, now I redirected all the tag links to search using .htaccess, I.E example.com/tag/stack-exchange/ ...
0
votes
0answers
247 views

Deny php execution in /wp-includes - using .htaccess in /wp-includes VS root folder

Trying to secure my WP site. In an attempt to deny php execution from the wp-includes folder wondering if these two methods are effectively doing the same thing? 1) add new .htaccess file to root of ...
1
vote
1answer
33 views

Only Allow Front End Access

I am new to wordpress and am looking at a way to only allow users access to the front-end of my site. It is a one page vlog site, but I am forcing users to register to view. Is this handled in wp-...
1
vote
0answers
40 views

Wordpress category with 404 error

Okay, so I'm facing a weird problem as I'm receiving 404 errors on blog category pages and I already did the most popular tricks to solve it, such as: re-install Wordpress update permalinks update ....
0
votes
0answers
58 views

Events Calendar Multisite 404 for events

I haven't seen any solutions that work for me or apply to my use case. but, I have a url like https://www.example.com/site1/event/some-event-2017-01-17/2018-08-30/ this will throw a 404 page not ...

1
3 4
5
6 7
24