Do I need to instantiate the XMLRPC class or any class in another class to access its methods?

So far as I know, the XML RPC class is not instantiated unless needed, which is when the request is to /xmlrpc.php. You would instantiate the class the same way the Core does: include_once(ABSPATH . ‘wp-admin/includes/admin.php’); include_once(ABSPATH . WPINC . ‘/class-IXR.php’); include_once(ABSPATH . WPINC . ‘/class-wp-xmlrpc-server.php’); /** * Posts submitted via the XML-RPC interface get … Read more

What’s the right way to share data between widgets?

Presumably, these are widgets that you are writing. If so, basic PHP class methods should do it– set a static class property to hold your “overlap” data. class Foo extends WP_Widget { static $overlap; /*constructs etc*/ function __construct($id = ‘twidg’, $descr=”Test Widget”, $opts = array()) { $widget_opts = array(); parent::__construct($id,$descr,$widget_opts); /*do stuff*/ } function widget() … Read more

Force WordPress to load a specific template

Depending on your home page, you either can set up a template file home.php (archive) or front-page.php (static page). In the according file, you can do whatever you want. Run additional queries, load content from whatever source etc. If this is not what you want, then you can have a look at the template_include filter … Read more

Meta Tags by Meta Box

This is really just a PHP question, but since there is no Core function to do this… I’d use !empty(). Otherwise just echo a string. $mcontent = get_post_meta($post->ID, “vw_citation_title”, true); if(!empty($mcontent)) { echo ‘<meta name = “citation_title” content = “”.$mcontent.'” >’; }

Custom blog setting directs blog to index page

As @Michelle rightly pointed out, blog.php is not part of the template hierarchy. Here is what the codex have to say about Custom Blog Posts Index Page Template To create a custom blog posts index template, include the following in the Theme: home.php Use only the home.php template file for the blog posts index. Do … Read more