STYLE SWITCHER

Wordpress

Advanced Custom Fields for WordPress Developers.

Content editing made easy Use the Advanced Custom Fields plugin to take full control of your WordPress edit screens & custom field data.

Add fields on demand

Our field builder allows you to quickly and easily add fields to WP edit screens with only the click of a few buttons!

Add them anywhere!

Fields can be added all over WP including posts, users, taxonomy terms, media, comments and even custom options pages!

Show them everywhere!

Load and display your custom field values in any theme template file with our hassle free developer friendly functions!

Website
More

How To Limit Words and Characters in content WordPress

1. Words Length:

Remove  the <?php the_content();?>  insert the below code
<?php $content = get_the_content();
  $trimmed_content = wp_trim_words( $content, 60, '<a href="'. get_permalink() .'">...[ read more ]</a>' ); ?>
  <p><?php echo $trimmed_content; ?></p>
(Change the 60 to your desire words length)

2. Character Length :

Remove  the <?php the_content();?>  insert the below code
<?php echo substr(strip_tags($post->post_content), 0, 46);?>
//(Change the 46 to your desire string length)
More

Thrive Comments for wordpress

Build an Army of Engaged Visitors That Will Grow Your Site For You

Thrive Comments is the newest alternative to the native WP comments. It’s a WordPress plugin that will bring a whole array of previously unavailable features to your WordPress comments.

Key Differences: Thrive Comments vs. Disqus

The main difference between Thrive Comments and Disqus is the scope of the programs. Since Disqus is part of a universal, multi platform network, it adds some interesting functionality, as well as a few constraints.

The Disqus system outsources comments to their network, so while the comments appear on your website, everything is controlled and hosted on the Disqus network.

Website
More

Add Google reCAPTCHA in WordPress

Google reCAPTCHA is becoming popular since the day of its announcement. The performance of this product is not been evaluated yet because of its age.
I have covered basic tutorial about how to code custom script with Google reCAPTCHA.

functions.php

/*Add Google captcha field to Comment form*/

add_filter('comment_form','add_google_captcha');

function add_google_captcha(){
echo '<div class="g-recaptcha" data-sitekey= "=== Your site key === "></div>';
}

/*End of Google captcha*/

single.php

<script src='https://www.google.com/recaptcha/api.js'></script>
<script type="text/javascript">
jQuery("#submit").click(function(e){
var data_2;
jQuery.ajax({
type: "POST",
url: "http://yourblog.com/wp-content/themes/yourtheme/google_captcha.php",
data: jQuery('#commentform').serialize(),
async:false,
success: function(data) {
if(data.nocaptcha==="true") {
data_2=1;
} else if(data.spam==="true") {
data_2=1;
} else {
data_2=0;
}
}
});
if(data_2!=0) {
e.preventDefault();
if(data_2==1) {
alert("Please check the captcha");
} else {
alert("Please Don't spam");
}
} else {
jQuery("#commentform").submit
}
});
</script>

google_captcha.php

<?php
$data;
header('Content-Type: application/json');
error_reporting(E_ALL ^ E_NOTICE);
if(isset($_POST['g-recaptcha-response'])) {
$captcha=$_POST['g-recaptcha-response'];
}
if(!$captcha){
$data=array('nocaptcha' => 'true');
echo json_encode($data);
exit;
}
// calling google recaptcha api.
$response=file_get_contents("https://www.google.com/recaptcha/api/siteverify?secret=Your secret key&response=".$captcha."&remoteip=".$_SERVER['REMOTE_ADDR']);
// validating result.
if($response.success==false) {
$data=array('spam' => 'true');
echo json_encode($data);
} else {
$data=array('spam' => 'false');
echo json_encode($data);
}
?>
Website
More

Adding dynamic title to WordPress

Using a good <title> tag is incredibly important for ranking high in the Search Engines. This code snippet will dynamically generate a dynamic <title> tag to improve your WordPress site’s SEO and should be placed in your WordPress site’s header.php replacing your existing <title>.
<title><?php bloginfo('name'); if(wp_title('', false)) { echo '|'; } else { echo bloginfo('description'); } wp_title(''); ?></title>
More

jQuery Googleslides

GooglePhotosTNW
A jQuery plugin to display your Google Photos.
Website
More

SyntaxHighlighter

jssyntax
SyntaxHighlighter comes with almost 30 brushes out of the box. One of the most requested feature has been the ability to dynamically load them without having to load them all on the same page.
Website
More

Underscores + Bootstrap

underscore
UnderStrap combines the Underscores starter theme (by Automattic) and the mobil-first, responsive grid framework Bootstrap (by Twitter) into a perfect foundation for your next WordPress theme project.
Website
More

Jetpack – wordpress plugin

thumbnail-jetpack
Jetpack adds powerful features previously only available to WordPress.com users including customization, traffic, mobile, content, and performance tools.
Website
More

Rapid Front-End Prototyping With WordPress

1680__1050__auto__-wp-content-uploads-2015-01-jquery-to-wp-plugin
Prototyping is one of the best things that can happen within a project, yet it is extremely underutilized. Prototyping makes a project better suited to users, elevates user experience, increases the quality of your final code, and keeps clients happy.
Website
More