127.0.0.1
Member
Posted 4 months ago #
Hi folks,
I'm using WP 3.3.1 and tried all versions of Custom Permalinks. I use this plugins only for categories. However, I see my theme's 404 page when I try to read a post in any category.
I use this structure on permalinks : /%category%/%postname%.html
Any ideas would be appreciated. Thanks.
http://wordpress.org/extend/plugins/custom-permalinks/
Bogieknight
Member
Posted 3 months ago #
Not wishing to hijack your post but I'm having the same issue. Hopefully someone in the know will shed some light on this.
gloria_munoz
Member
Posted 3 months ago #
gloria_munoz
Member
Posted 3 months ago #
Bogieknight
Member
Posted 3 months ago #
Hello Gloria,
Thanks for the tip. I tried it but unfortunately it didn't work for me :(
nike2000
Member
Posted 3 months ago #
127.0.0.1
Member
Posted 3 months ago #
Hey guys,
I have a solution. Get the version 2.7.9 and replace line #161 with this SQL query:
$sql = "SELECT $wpdb->posts.ID, $wpdb->postmeta.meta_value, $wpdb->posts.post_type FROM $wpdb->posts ".
"LEFT JOIN $wpdb->postmeta ON ($wpdb->posts.ID = $wpdb->postmeta.post_id) WHERE ".
" $wpdb->postmeta.meta_key = 'custom_permalink' AND ".
" $wpdb->postmeta.meta_value != '' AND ".
" $wpdb->posts.post_status = 'publish' AND ".
" ( $wpdb->postmeta.meta_value = LEFT('".mysql_escape_string($request_noslash)."', LENGTH($wpdb->postmeta.meta_value)) OR ".
" $wpdb->postmeta.meta_value = LEFT('".mysql_escape_string($request_noslash."/")."', LENGTH($wpdb->postmeta.meta_value)) ) ".
"ORDER BY LENGTH($wpdb->postmeta.meta_value) DESC";
this works for me.
Bogieknight
Member
Posted 3 months ago #
Hi 127,
When you say 'version 2.7.9' do you mean WP version or custom permalinks version? Sorry if this seems like a banal question, but I'm not very accomplished in this area!
127.0.0.1
Member
Posted 3 months ago #
You should use version 2.7.9 of the plugin, of course ;)
Bogieknight
Member
Posted 3 months ago #
I gave that a go but it didn't work. What I did notice though was whatever I put in the 'custom structure' box it failed to work.