I just created some pages (not posts) on a wordpress site, and a strange thing happens :
each page have a distinct permalink, that works.
A few time afterwards, I try to access to the page via the permalink, but it leads me to another page that has its own permalink.
For example : http://www.benevolat.org/partenaires/ gives me the page for which permalink is http://www.benevolat.org/assurance-responsabilite-civile-association/.
I tried to modify the permalinks, to change the permalink structure, but the results are the sames. The only structure that works is the default one (?page=XXX).
The only topics I have found on the wordpress forums deal with 404 errors, but it is not my case.
Have you ever faced this ?
Thanks for your help,
Jérémie
Related
I am trying to set permalinks as:
domain.com/category_name
domain.com/postname
And I can't find a way to make this work.
On screenshot down below you have my settings of permalinks, thats the set-up I want, but I am getting an 404 on category pages.
I tried to reset clear htaccess and flushed permalinks to recreate it. (its writable)
I tried to put "." as category base.
Nothing helps.
If I set in settings custom structure : /%category%/%postname%/, and I set category base to ".". That works, but I get post pages under category and I dont want my post page URL to have a category in it.
Anything is helpful! :) Thank you
Okay, I found some solution if someone needs it in future:
I left my settings in permalink as
Custom structure: /%category%/%postname%/
Category base: .
And I installed plugin: "Permalink Manager Lite" and used it to manually remove category from the URL of each posts.
I have WordPress installed in a subfolder of my domain. I want to keep it there, so that it is accessible only through http://www.example.com/mywordpress.
I have an issue with permalinks. If I use postname permalinks, all my pages (with different templates applied) redirect to the homepage, while my archives (including custom post type archives and singles) are displaying correctly. If I use custom structure permalinks and I prepend anything to the postname – for example /test/%postname%/ – all pages display correctly while custom post type archives and singles display a 404 error.
This happens whenever I refresh permalinks and also after replacing .htaccess with one from a brand new WP install.
The odd thing is also how the permalinks are displaying in the browser url field:
if I use /%postname%/
pages (not working) display as
http://www.example.com/mywordpress/postname – they all display the
homepage contents
CPT archives+singles (working) display as
http://www.example.com/mywordpress/postname
if I use /test/%postname%/
pages (working) display as
http://www.example.com/mywordpress/postname – so without the
prepended text!
CPT archives+singles (not working) display as
http://www.example.com/mywordpress/test/postname – displaying a 404
error
My custom post types have slugs translated to different languages with WPML. I thought that might cause the issue, however I tried to deactivate all plugins included WPML and still no luck.
Does anyone know what might cause that?
I figured it out. I was using reserved terms as custom taxonomy slugs (https://codex.wordpress.org/Reserved_Terms). By changing them to something else everything started working normally again!
I am listing out all of posts on the post page. Also the categories are listed in a sidebar. For some reason some links are redirecting to a post page. Can someone explain why this might be happening? The .htaccess file is the default that comes with wordpress as well. I am stumped. Also, my permalinks look like this /weekly-insights/%year%/%monthnum%/%day%/%postname%/. I have tried refreshing my permalinks as well. If anyone could help me out where I am going wrong it would be appreciated. Again, I am just trying to click a category link and have it go to that particular page.
I have a WordPress site where my front page is showing the latest posts.
If I have my permalinks set as plain showing...
https://example.com/paged?=2
The page loads. However, If I change the permalinks to Post name, giving me...
https://example.com/page/2/
That results in a 404.
.htaccess seems to be set up correctly. The first page has posts and the links are being generated in the pagination controls. Using Post name as the permalink setting my posts are properly linked...
https://example.com/my-wordpress-post
But https://example.com/page/2/ does not work.
Any ideas? I really need to set the permalinks to Post name. Could it be a server issue?
First thing I would recommend is to confirm your .htaccess file is set up correctly to process permalinks. If you create a new page, can you access that page with his human-friendly permalink, for example? If not, you may need to fix your .htaccess file to handle those rewrites properly.
Otherwise, can you provide more context for this issue? Is it safe to assume you have your homepage set up with a list of paginated posts?
I figured this out. Instead of selecting Post Name, I select the Custom Structure radio button instead and manually added /%postname%/ and then clicked saved.
Then it worked. :)
I have a wordpress multi-site:
site1.local.loc [with subdomains on my local] and I would like to have three pages on this.
site1.local.loc/works - (posts page, but I want 'Works' as my title)
site1.local.loc/about - (static page)
site1.local.loc/contact - (static page)
Since 'Works' is my posts page where I keep putting in content, I changed my permalinks for this site to:
/works/%postname%/
However, when clicking on 'view post' at the end of posting anything, it leads me to a '404' page which means there is a disconnect. This is also the case for viewing any page. Is my .htaccess file faulty?
How do I solve this? Also how do I make all my posts appear in my 'Works' page (as in, how to make that page the posts page?)
Thanks!
Updated: I've found out that I get a 404 for any page that I create for a site in a wordpress network.
You do not have to touch .htaccess file.
Make a custom post type that is called works. All those posts made in that custom post type will have that url that you desire. There is no other way to do it. (even if there is, it must be dirty) That is celanest way, and since wp does it by itself you can expect that nothing will go wrong wnen you update, install plugins, etc.
Create a category called "Works" that would then show all posts added to that category by simply going to /works/ all posts would then be shown as /works/post-name/.
You will need to change the permalink structure to /%category%/%postname%/
Check this in administration
Settings > Permalinks > Post name