What is Global WordPress Objects?

As I’ve mentioned in the comments – you shouldn’t need to modify / touch WordPress globals directly. It seems you are getting the errors because you are trying to load WordPress within Smart – this is a bit of a hacky approach. I’ve not used Smarty at all, but WordPress has its own way of … Read more

Buddypress Adding a Nav item and Calling Custom Fields [closed]

The problem is that you’re not specifying which template BuddyPress should use to display your content. There are a couple of ways to do it (see https://github.com/boonebgorges/buddypress-skeleton-component/blob/master/includes/bp-example-screens.php for a few options), but I suggest the following // This is the screen_function called in bp_core_new_nav_item() function all_conversations_link() { add_action( ‘bp_template_content’, ‘all_conversations_content’ ); bp_core_load_template( ‘members/single/plugins’ ); } … Read more

Image Upload Form is Disabling Comment Addition

Well, this is definitely a little hackish but what I ended up doing was changing the action on the form to “[mysite url]/wp-comments-post.php”. Then I took advantage of a few action hooks in wp-comments-post.php to hijack that page: add_action(‘pre_comment_on_post’, array($this, ‘process_image_upload’)); And if anyone is curious as to how I wrote the process_image_upload function (which … Read more

Unable to get posts with category on my page

add in standard WordPress post specific template tags here eg. the_title(), the_permalink, the_content, the_excerpt etc. endforeach; Like that comments says, call the function you need to display the title. The category argument appears to represent the category ID, not the slug. Try using category_name instead. [php] $myposts = new WP_Query(‘posts_per_page=5&category_name=basics’); while($myposts->have_posts()): $myposts->the_post(); // your output … Read more