Search Result for: Wordpress Category

Articles

Use Short code in template or php code

Trying to output shortcode in a PHP or template file, wrap your code in the shortcode function like so: <?php echo do_shortcode("[your-short-code]");
Read More

Display WordPress Categories in a List

Use the following code to create a list of categories in WordPress. <?php //$taxonomy = 'genre'; //$orderby = 'name'; $show_count = false; $pad_counts = false; $hierarchical =
Read More

PHP Limit the amount of text being displayed in a string

Use the following PHP function to limit the number of characters ($limit) to be returned from the original string ($source). //limit text function limit_text($limit, $source =
Read More

WP Plugins unable to display, WP unable to check versions

Check wp-config.php file ig the following is uncommented: //define('WP_HTTP_BLOCK_EXTERNAL', true); or if the following is enabled define('FS_METHOD', 'direct');   Else use
Read More

Create an options page

Use the following code in functions.php to create an options page   if( function_exists('acf_add_options_page') ) { $option_page = acf_add_options_page(array( 'page_title'
Read More

tag.php not including tags from custom post types

Ran into a very funny problem when creating a template, basically, when a tag was clicked and the template sourced the tag.php page it was not quering any posts in any of the
Read More

Simple but effective .htaccess blocking for IP address

This is a simple but very effective way to block people from accessing folders in your website. Simply create a .htaccess page and place the following code: #Order deny,allow JOE
Read More

Display the second or third level menu items in WordPress

Display the second or third level menu items in WordPress. Surprisingly WordPress does not have this feature built into
Read More