Remove year and month in URL using .htaccess

Assuming you have already changed the permalinks structure as @RickHellewell suggests, then you can do something like the following near the top of your .htaccess file (before the existing WP front-controller) to redirect the old URLs (with the stated format) in order to preserve SEO. RewriteRule ^\d{4}/\d\d/([a-z-]+\.html)$ /$1 [R=301,L]

Are Categories, Tags and Custom Taxonomies any different in regards to SEO?

Short answer: No. When you’re working with SEO, there are three things to take into account: Site content Site meta descriptions Site findability (it’s a word, I swear!) Site Content Search engines will parse your site’s content looking for content and keywords. Create good, useful content and it will be fetched, parsed, and recorded appropriately. … Read more

Current post’s author name in the author meta tag

You cad add it via functions.php with a hook, instead of inside the loop (you don’t really want to add a loop to header.php): function add_author_meta() { if (is_single()){ global $post; $author = get_the_author_meta(‘user_nicename’, $post->post_author); echo “<meta name=\”author\” content=\”$author\”>”; } } add_action( ‘wp_enqueue_scripts’, ‘add_author_meta’ );

Pretty Permalinks

You should add your own custom query variable first: function add_search_store_query_var($vars) { $vars[] = ‘search_store’; return $vars; } add_filter( ‘query_vars’, ‘add_search_store_query_var’); And then add rewrite rule: function add_search_store_rewrite_rule() { add_rewrite_rule(‘stores/([^/]+)$’, ‘index.php?page_id=<YOUR SEARCH PAGE ID>&search_store=$matches[1]’, ‘top’); } add_action(‘init’, ‘add_search_store_rewrite_rule’); You can then use get_query_var(‘search_store’); to get search term. Just remember to flush rewrite rules, before you … Read more

WordPress custom taxonomy URL rewrite on spelling errors

It also doesn’t matter which URL part is changed, except the last one. So this still shows the content of the original page. Yes, because your taxonomy’s rewrite is hierarchical with the permalink structure /treatment/<term slug> (e.g. /treatment/psychosomatic) or /treatment/<term slug>/<term slug>/… (if the term is a child term, e.g. /treatment/psychosomatic/psychosomatic-dysfunction), so as long as … Read more

Multiple Domain Names – One WP Install (non-Multisite) – Default Each Domain name to Category Archive

Here’s two different solutions (editing the specifics for your use case): Doing a Redirect: 1.) At the top of your /wp-config.php file add the following: if ( is_yoursite_blogger_domain( $_SERVER[‘SERVER_NAME’] ) ) { $domain = str_replace( ‘www.’, ”, $_SERVER[‘SERVER_NAME’] ); define( ‘WP_SITEURL’, ‘http://’ . $domain ); define( ‘WP_HOME’, ‘http://’ . $domain ); } else if ( … Read more

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