How to change featured content to a different tag in WordPress Twenty Fourteen?

In twenty fourteen theme, we’d like to know how to change the features content tag. Currently it’s set as featured. Now, we would like to know how to code this for different page templates. We notice in page.php there is a piece of code calling the template part featured-content. <?php if ( is_front_page() && twentyfourteen_has_featured_posts() … Read more

Unicode character in PHP string

This question looks embarrassingly simple, but I haven’t been able to find an answer. What is the PHP equivalent to the following C# line of code? string str = “\u1000″; This sample creates a string with a single Unicode character whose “Unicode numeric value” is 1000 in hexadecimal (4096 in decimal). That is, in PHP, … Read more

mysqli_real_connect() – authentication method unknown to the client Warnings

I keep getting the following warnings in my debug log: PHP Warning: mysqli_real_connect(): The server requested authentication method unknown to the client [mysql_old_password] in /wp-includes/wp-db.php on line 1379 PHP Warning: mysqli_real_connect(): (HY000/2054): The server requested authentication method unknown to the client in /wp-includes/wp-db.php on line 1379 PHP Deprecated: mysql_connect(): The mysql extension is deprecated and … Read more

Nested shortCode functions in the functions.php file

I’m trying to get a shortcode function (newStuff) to display inside of another function (oldStuff), but I’m running into trouble. Both shortCode functions are listed below, as well as what I’ve tried. Can someone please help me get the “newStuff” function displaying inside of the “oldStuff” function? Thanks! Current Functions function newStuff(){ return ‘ only … Read more

1+1 php counter inside the update_post_meta

how do you create a 1+1 php counter inside the update_post_meta? this is the code i have so far: $count = 1; update_post_meta($bid_id, ‘draftnumber’, $count++); but the counter is not moving, so i tried another one: $counting = $counting + 1; update_post_meta($bid_id, ‘draftnumber’, $counting); but it’s not working, am i not allowed to use $count++ … Read more