In this artcle we will learn how to save and show a custom field as order item meta in woocommerce. Here I suppose to save a COLOR custom field with each of order item in woocommerce.
I have put a working code which force to add custom value for your product images. You can set ATL value as per your need. It might be like your product title or product category name + Product Title whatever combination you want.
If you are working with WordPress site then you had faced this issue many time. This is common issue of WordPress. Sometimes any piece of code takes enough time to execute and due to this WordPress requires more memory than allocated .
How to change UTC time to your local time using PHP is big question in PHP programming language. Today, PHP Tricks provide you a simple and quick function to covert UTC/GMT time to your local time using DateTimeZone PHP class.
In this article, I elaborate how to Use Shortcodes in WordPress Sidebar Widgets. I proposed two methods to do this in simplest way. Go through the article and leave your comment.
This jQuery codehelps you add smooth SCROLL animation when you click to Go To link in your web page. I am using .animate jQuery function in following code. In this tutorial you will learn how you can create an animated scroll to top or any element with jQuery. Create Button or Link First we need… Continue reading
A PHP function that helps to get list of next days form current day. There are many way but I created one of best solution using foreach and strtotime in-built PHP functions.
Here you can learn how to add client side validation on Browse/Upload button. JQuery helps a lot to add such type of client side validation on HTML DOM.
Getting blank page or dead white page is big issue with Magento. So PHP Tricks provide you easy function to avoid blank page error in your Magento site.
I made a PHP function which returns a random string using Alphabets [a to z] and [A to Z], Numbers [0 to 9]. It is very easy to use and can be easily modified.
To get posts on basis of their meta content, You can use get_posts function as given below:
A function that helps you to redirect to any custom page after posting WordPress comment. WordPress provides many filters to do this custom redirection. Few of tricks are explaining in this article .
Here In this article, You will know how to add metaboxes for Custom posts in write screen inside WordPress admin section. WordPress provides some functions to add a section where you can manage your additional content of post. In this example, I am adding a metabox as name “Images” under my custom post (lets consider post type is… Continue reading
Apply additional Style in WordPress Comment Form In this trick, You get many name of classes where you can add additional style/CSS to override default styling of Comment form. WordPress allows you to add CSS to get new look of Comment section in posts/pages. The WordPress comment form is generated using the function <?php comment_form();… Continue reading
The image that shows for the author comes from the email address set for that user which goes to a corresponding Gravatar. The display name and bio come from the User settings area in the Admin.
The body_class wordpress filter is nice for adding a lots of classes to the body tag that have information about what kind of page is currently being displayed. Probably for styling purposes. But for whatever reason, it doesn’t include a class for the current category (or categories) for a single post. This following code adds all… Continue reading
In a login script, remember me feature is used to preserve the login name and password entered by the user. And it can be populated in the login form at the time of login. It minimizes the user effort by preventing to enter login details for each time. Now we are going to see an… Continue reading
An article which helps you to add Template page in your WordPress website.We can start with a sample file and copy page.php, rename it on your choice and put it inside the theme folder ../wp-content/themes/mytheme/ .