Tag Info

New answers tagged

1

See flush_rules in Codex: Because this function can be extremely costly in terms of performance, it should be used as sparingly as possible - such as during activation or deactivation of plugins or themes. Every attempt should be made to avoid using it in hooks that execute on each page load, such as init. Only flush rules when they change, not on ...


0

All the config were good, the problem was with my host provider. For the record, the htaccess for the site in the subfolder, when everything is ok : # BEGIN WordPress <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php ...


0

Try adding Options +FollowSymLinks to the top of the .htaccess file. If that doesn't work, verify that the host has AllowOverride enabled. Verify what they have the AllowOverride set to. mod_rewrite can be used to simulate a symbolic link. This is why mod_rewrite requires FollowSymLinks to be enabled, because it's a similar security thing. So if your host ...


0

Are you sure the rewrite module is enabled? Type: a2enmod rewrite If you are on Linux or equivalent for your platform/setup. You can also try: ls /etc/apache2/mods-enabled/ and look for the rewrite module in there?


1

a multi site approach wouldn't work since you will be creating multiple blogs, each will work as an individual WP installation, so each of them will hold multiple posts, pages, categories, etc that are not shared between blogs. The url you are proposing can't be defined using wordpress routing, so a custom code will need to be developed for this approach.


0

Well, what do you know -- there's a plugin for that: https://wordpress.org/plugins/redirection/ Under the "redirects" tab in the plugin's settings you can set as many redirect rules as you'd like.


0

In your .htaccess file, add this code below- Redirect 301 / http://mywebsite.com/blog/ Change mywebsite.com with your actual domain.


0

I would use HTACCESS redirects just to avoid any other users not aware of the change in the future from altering it easily through your CMS. However, if you're interested in something a bit more user friendly, there are a number of apps that build in additional slug lines for you in the page such as WP's redirection plugin: ...


1

If there is no clear evidence of any present redirect from the following sources: The htaccess, both under the public_html and under the public_html/folder (where folder is the directory having all the wp files), removing and regenerating them by mean of updating the permalinks, The .htaccess files were at some point deleted, and regenerated, The domain ...


0

A 406 Not Acceptable HTTP error usually indicates that the content type of your webpage is not in the Accept request header that your browser sent to the webserver. When you load a website, your browser sends a Accept header with the content types that it will accept, like text/html or text/xml. But when the webserver sends a format your browser doesn't ...


0

I like your solution checking the coockie from the .htaccess this will give a much quicker loading solution then my solution. .htaccess <IfModule mod_rewrite.c> RewriteEngine On # Rules to prevent php execution in uploads RewriteRule ^(.*)/uploads/(.*).php(.?) - [F] #redirect all FILES for login check (excluding PHP) RewriteCond ...


0

There is a option to mention your site address in General Settings. I think that is what you need to change.


0

Your problem comes from a fundamental misunderstanding of how WordPress loads the main loop. Here you have a main query that goes and grabs the posts to display in your post type archive. It then decides to load archive-recept.php based on that query. The call to paginate_links then provides the pagination for that main query. However, the main query isn't ...


0

Try adding this to your .htaccess file wherever the install is located. ErrorDocument 403 /specific_page.html Order Allow,Deny Allow from 111.222.333.444 you of course are changing that ip address to your own. if you already have an htaccess file containing info, add it to the top.


0

I offer following solution. It's required prepending this lines to index.php. if (!empty($_SERVER['REDIRECT_URL'])) { $_SERVER['REQUEST_URI'] = $_SERVER['REDIRECT_URL']; } I know this is a dirty hack, but WordPress rewrite mechanism based on $_SERVER['REQUEST_URI'] value. These rules tested only on links like (with another domain) ...


0

In your subdirectory, open your access and change it to the stock setting. root/subfolder: # BEGIN WordPress <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L] RewriteCond. %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule> # END WordPress That should work. ...


0

Found a solution for anyone who may stumble upon this. Basically, each part of a standard WordPress htaccess now has two RewriteConds: one for when it is in a subfolder, and another for when its not. Depending on that evaluation, the appropriate RewriteRule is applied. # BEGIN WordPress RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L] # add a ...


0

This is probably not very trivial to do. You need to take into account that wordpress needs the "forums" directory in the url to successfully detect that the requested content is forum post and not regular posts or pages. Therefor you need to change the value of REQUEST_URI in the htaccess file or add your own URL parsing code. the path of least resistance ...



Top 50 recent answers are included