admin

PHP – Passing Array in URL and Retrieve with Get

To pass an array in a url use the following: <?php $serialized = rawurlencode(serialize($args)); ?> <a href="testpage.php?args=">Test Page</a> To retrieve the array use the following: <?php $args =...

Read More

WordPress – How to integrate a plugin or widget into a theme

Generally I create an includes directory within my themes directory and place the plugins (inside their folders) within the includes directory. This way I can control the version of the plugin used. And it also keeps my clients from being tempted to upgrade...

Read More

WordPress – Starter Themes

Blank WordPress themes are a great way to start out your theme. It gives you the complete foundation and the biggest step required to making a WordPress theme. WordPress themes can contain some of the following files: Important Template Files (there are more...

Read More

WordPress – Display Custom Post Types (CPTs), Custom Taxonomies and Terms

Place any of the following code with your functions.php and it display on any page of your site, before the wordpress header. I use the code for debugging and understanding what custom post types and taxonomies exist, but you can expand on the snippets to...

Read More

WordPress MultiSite – How to get the Site URL from a Sub Blog

For any site on the network you can get the sites URL from Home_url() or site_url(), but if you are on a sub-blog and want the URL of your main blog you need to use network_home_url().

Read More