Where do I build my updated website?

It’s really up to you. As a developer, I prefer working locally but if you do not develop but only add/remove/update themes and plugins, then a subdomain can be great. This way, you can freely break your website without disturbing anyone. Nowadays, lots of hosts providers are offering to create staging website in one click. … Read more

WPDB prepare – like % – placeholders?

Yes, they’re normal. They were added in 4.8.3 to fix an SQL injection vulnerability. You can read an article describing the technical reasons for this happening here and the ticket for the change here. The placeholder characters are replaced by the random characters on the last line of $wpdb->prepare() with the $wpdb->add_placeholder_escape() function, which calls … Read more

How can I remove paginated SEO titles from my WordPress site?

I’ve fixed the problem with this code: <title> <?php global $page, $paged; wp_title(‘|’, true, ‘right’); bloginfo(‘name’); $site_description = get_bloginfo(‘description’, ‘display’); if ($site_description && (is_home() || is_front_page())) echo ” | $site_description”; if ($paged >= 2 || $page >= 2) echo ‘ | ‘ . sprintf(__(‘Sayfa %s’, ‘twentyten’), max($paged, $page)); ?> </title>

wp_signon by user’s login by their particular role

/* Add code below wp_set_auth_cookie( $user->ID, true, false ); */ $current_user = wp_get_current_user(); if($current_user->roles[0]==’personal_account’){ wp_redirect(site_url(‘/profile’)); }else if($current_user->roles[0]==’corporate_user’){ wp_redirect(site_url(‘/corporate-profile’)); }