February 25, 2015 – 4:01 pm
I like WordPress, but sometimes it works in weird ways.
I recently needed to get information such as the title and some custom fields of the Page I was on. That’s easy, but the Page happened to be ‘News’ which was served from index.php. That apparently isn’t so easy.
To do it, I needed the Page ID. That’s something a lot of people can probably hard-code, but this is a multi-site theme, so no can do. Instead I had to use get_option( ‘page_for_posts’ );.
Here we have it:
<?php $page_id = get_option( ‘page_for_posts’ ); ?> <h1><?php echo get_the_title($page_id) ?></h1>
February 4, 2015 – 1:53 pm
WordPress Hosting Comparison is a website I launched this week. The website lists the main web hosts in the industry that supply managed hosting. The website doesn’t include providers of what I would deem to be more bare bones systems, where you would receive root access to a (virtual) box, but instead focuses on providers who offer tailored hosting solutions ready to go.
Not all of the providers offer a WordPress-specific hosting option, but many do. However, all of the web hosts and all of the web hosting packages within the comparison will fully support WordPress. Many of the providers have WordPress only packages, and some have WordPress pre-installed and optimised with their own in-house plugins tailored specifically for their own servers.
The website itself is built in Ruby on the Rails framework. I created the website as an opportunity to learn a little more about…