In WordPress we can add our very own thumbnail size we want so we can use in our customization. Add this code in your favorite functions.php. Using add_image_size function of WordPress. In my case I create a 285×148 size of thumbnail. The first option is the name of image that you can use to call […]
Here is a code you can add in your functions.php in your WordPress template. This code will remove the auto adding of html “p” tag in your content.
We all know adding Social media icons on wordpress is easy as 1,2,3. There are lots of social media plugins we can find in WordPress repository but what if sometimes we don’t want to use a WordPress plugin just to add a social media button like Pinterest. In Woocommerce we need to hook a function […]
Sometimes you don’t want to crawl a single page or some posts to the robots of Google, Yahoo, Bing, etc. Now I will teach you how not the a page or post to be crawled by robots. You can add this code on your header.php. 1. using is_page function of wordpress Using the is_page function […]
Sometimes using a find and replace using a text editor like our favorite Notepad++ and Sublime can do the trick but the problem is when you are migrating your WordPress site, the widgets or mostly the text widgets are breaking and didn’t add in our widget section. That is too bad when you have lots […]
This is a snippet tutorial that we can use everytime we need to modify the wordpress excerpt to the length we want. Put this code in your functions.php?and enter the number of length you want let say my example is 35.
This snippet is a example on how we can add a Google Analytic code in our theme. In my case I would like to add it on the footer. You can manually add the Google Analytic in footer but this code we will add it using our functions.php Then replace the UA-XXXX-X from the code […]