Office Address

41/D, West Brahmondi, Narsingdi

Phone Number

+880-1975374887

Email Address

[email protected]

get post publish date outside the loop in wordpress

To get post publish date outside the loop in wordpress use the following code. [php] $all_posts = get_posts(array(‘numberposts’=>-1, ‘post_status’=> ‘publish’)); //Get all published posts foreach ($all_posts as $single_post){ echo get_the_time(‘Y-m-d’, $single_post->ID); //The date is on Y-m-d format echo ‘<br />’ ; } [/php] Hope this code will help you. Thanks

Read More

Load jquery library from google CDN in wordpress

Add this code on wordpress theme functions.php to deregister the urgent jquery and load jquery library from google. [php] function load_cdn_jquery() { // only use this method is we’re not in wp-admin if (!is_admin()) { // deregister the original version of jQuery wp_deregister_script(‘jquery’); // discover the correct protocol to use $protocol=’http:’; if($_SERVER[‘HTTPS’]==’on’) { $protocol=’https:’; } […]

Read More

10 Useful WordPress functions to reduce your development time

This 10 Useful WordPress functions will certainly reduce your WordPress development time.I found this functions when i do some research for my projects. So i think i better share this with you. 1.Custom Excerpt Length By default, excerpt length is set to 55 words. To change excerpt length using excerpt_length filter, add the following code […]

Read More
  • September 10, 2012
  • PHP

8 useful PHP code snippets for developers

Today, i want to share you some useful PHP code snippets which may reduce your development time. 1.Send HTML Mail [php] <?php $to = "[email protected]"; $subject = "This is my test html email send using php mail function"; $body = "Body of your message here you can use HTML too. <br /> <h1> Header </h1> […]

Read More