Category Archives: Themes

Use WordPress Themes and Functions on Other PHP Pages

Free Favicon

WordPress is a great content management system but there are still times when you either just want to add a page to your website that is not a part of WordPress or when perhaps you just want to give make sure all the pages on your website whether they are in WordPress or not all have the same look and feel. Thankfully WordPress has made it easy to make WordPress functions available on other PHP pages.

I recently wanted to redo Free Favicon and make sure the blog and the website all had a new fresh look. I had a theme in mind for the blog and want to make sure the rest of the pages had the same theme and look.

The first step is to include the WordPress wp-load.php file. This is the key to using WordPress functions, like loading theme files, outside of WordPress. For Free Favicon I simply added the code to load the wp-load.php file in the header template that the site was already using by adding a line similar to the following:

include($_SERVER['DOCUMENT_ROOT'].'/path to your wordpress install/wp-load.php');

Once wp-load.php was included you can access all of the WordPress functions so I could call the header and footer functions from the theme and have the site themed using the same WordPress theme the blog was using.

//call the theme header
get_header();

//call the theme footer
get_footer();

The only problem I ran into after getting the pages themed with the WordPress theme was how to change the title of the PHP pages with the new header. The original PHP pages had a section at the top of each of them that defined the title for the page. I just ran the WordPress filter wp_title and assigned the defined page titles from the PHP pages to be displayed using the WordPress theme.

function assignpagetitle() {
  global $documenttitle;
  return $documenttitle;
}
add_filter('wp_title', 'assignpagetitle');

Overall it was a pretty painless upgrade to Free Favicon, and a very easy way to make sure the whole site had a consistent look and feel. There are still some pages I left without the new theme and eventually I will probably getting around to fixing them as well.

3 Easy Tools to Name the Theme

A common question from people as they are searching for a theme for their WordPress website is what theme is ____ website using? If you know HTML/CSS it is pretty easy to look at the code and determine what the theme is and where that website got it from. If you don’t know HTML/CSS here… Continue Reading

WordPress Paradise Themes

It is possible that you landed here at WordPress Paradise looking for one of the WordPress Themes called Paradise. Makes sense really the domain name WPParadise.com is a great name for a WordPress theme. If you are looking for one of the WordPress themes called Paradise here are three possible themes that you might actually… Continue Reading

Traffica WordPress Theme

InkThemes has released the Traffic theme and it is a beautiful theme perfect for businesses and personal websites of all sizes. It is available as a free theme from the WordPress Theme repository as well as an upgraded theme directly from InkThemes. The screenshot below is the upgraded version but even the free version offers… Continue Reading

5 Favorite Free Responsive Themes

I get a lot of questions from new clients that are new to WordPress about what theme to choose. For those clients that have limited budgets it is always an interesting discussion because creating a custom theme for WordPress is a rather time consuming and therefore more expensive proposal. While I am always happy to… Continue Reading