Convert single apix to dash in permalinks

It’s stripped out with sanitize_title_with_dashes() through the sanitize_title filter at priority 10 (source), so you can replace it with a dash, just before with: add_filter( ‘sanitize_title’, function( $title ) { return str_replace( “‘”, “-“, $title ); }, 9 );

Permalinks 404 after Subdirectory to Root Migration

Please use this query in your Database using PhpMyAdmin UPDATE wp_options SET option_value = REPLACE(option_value, ‘oldsite.com’, ‘newsite.com’); UPDATE wp_postmeta SET meta_value = REPLACE(meta_value, ‘oldsite.com’, ‘newsite.com’); UPDATE wp_posts SET post_content = REPLACE(post_content, ‘oldsite.com’, ‘newsite.com’); UPDATE wp_posts SET post_excerpt = REPLACE(post_excerpt, ‘oldsite.com’, ‘newsite.com’); UPDATE wp_posts SET guid = REPLACE(guid, ‘oldsite.com’, ‘newsite.com’); This will change all your URL’s … Read more

Why is my RSS feed not working?

Your feed is there. You can check this by opening the source code of your homepage and find these lines: <link rel=”alternate” type=”application/rss+xml” title=”Talent Hero Media &raquo; Feed” href=”http://www.talentheromedia.com/feed/” /> <link rel=”alternate” type=”application/rss+xml” title=”Talent Hero Media &raquo; Comments Feed” href=”http://www.talentheromedia.com/comments/feed/” /> If you click on the first link you will be led to the source … Read more

Permalink will not change – it wants to have -2 slug [duplicate]

Some things that come to mind to try: Does this happen for all post types or just post or just custom post types? Are they hierarchical posts? You could read through the wp_unique_post_slug function (https://developer.wordpress.org/reference/functions/wp_unique_post_slug/) to see what might be triggering the suffix. Take a look through your database to see if there is any … Read more

Pagination using paginate_links

This is a problem with the paginate_links function and having your default permalink structure set to postname/custom but wanting the pagination to use default link structure. If you look at the code – https://core.trac.wordpress.org/browser/tags/4.8/src/wp-includes/general-template.php#L0 You can see the following at the top of the paginate_links function // Setting up default values based on the current … Read more

Post Name Permalink setup gives 404 error inside sub-directory

It’s happening because Nginx doesn’t interpret rewrite rules like Apache via mod_rewrite. You need to change your nginx vhost config file (nginx site config file, i.e /etc/nginx/sites-enabled/your-site-config.conf file) Add the following line inside server block location / { try_files $uri $uri/ /index.php?$args; } if the location / is already present, then remove the existing try_files … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)