SEO Content Top

Building an SEO CMS – Part 5

October 5, 2009

Filed under: Building SEO CMS — Tags: — Nathan @ 9:01 pm

In todays installment we will be giving you a few tips on how to get the content onto the page. as well as a basic script, we will be doing this in a number of stages, and the first will be the header tags. when coding in php you need to consider how you are going to be outputting the data. One of the things I like to work with is a templating engine as it gives you the seperation between website logic and display. Therefore I will seperate the codes logic to the display in this blog.

Today I am going to write about the logic to the header tags, there is a lot of debate as to what to include however I am only going to include title, keywords and meta description – ill leave the debate about the benefits for another day. this code is going to be keeping it as basic as possible, and we will hook up with the database next time.

Now for some code:

<?

$title = ‘Page Title’;
$metakw = ‘Meta Keywords’;
$metadesc = ‘Meta Description’;
?>

<html>
<head>
<title><? echo $title; ?></title>
<meta name=”keywords” content=”<? echo $metakw; ?>” >
<meta name=”description” content=”<? echo $metadesc; ?>” >
</head>

and this is about it for this article, next time we will be connecting to the database and then starting to build the page that is shown.

Building a SEO CMS – Part 4

August 25, 2009

Filed under: Building SEO CMS — Tags: , , — Nathan @ 9:32 pm

In the latest part of the series, I am going to explain one of the technologies we will use to build the SEO CMS. In this article I am going to be providing you with a sample .htaccess below, as well as explain what is it will do.

Firstly I am going to explain what a .htaccess file is. A .htaccess file is a configuration override file which has recursive properties, with those overrides being overridden with a .htaccess file in a subfolder of the main .htaccess file. Don’t worry if you do not understand this as you will learn these facts over time, or alternatively you can contact us to help you with any .htaccess issues you may be having.

Sample configuration:

RewriteEngine on

RewriteCond %{HTTP_HOST} ^example.com
rewriterule (.*) http://www.example.com/$1 [R=301,L]

RewriteRule ^([A-Za-z0-9-]+)/$ index.php?page=$1
RewriteRule ^([A-Za-z0-9-]+)/([A-Za-z0-9-]+).html$ index.php?page=$1

So what are those 5 lines which are key to your website actually doing? Well I am going to be splitting this down into two sections, the first two lines and the second set of two lines.

Line 1:

RewriteEngine On. This enables the apache mod_rewrite option which allows us to send a URL to apache, and have apache process the data and come out with what would be the real URL which would be expected.

Canonicalization fix
The First two lines are a fix for the common URL canonicalisation problem of http://example.com not redirecting correctly. This line is effectively pushing all traffic which maches the domain to the www. version, whilst employing the correct 301 redirect.

Mod_rewrite

The next two lines are the bit that ensures you do not have to output a querystring. what they are doing is allowing your web browser to input a URL in the format http://www.example.com/reddwarf/ and translate it into http://www.example.com/index.php?page=reddwarf. With this input you now have the control to check for database rows which correspond to this and provide all of hte data as you would normally expect.

Building a SEO CMS- Part 3

August 16, 2009

Filed under: Building SEO CMS — Tags: , , , , , — Nathan @ 9:42 pm

Choosing a hosting platform is a key decision when you are building a system from a SEO perspective. A lot of our clients like to use .com top level domains whilst wanting to appear on Google UK listings. As we have mentioned on many previous blog posts this can be overcome by using a UK based web host provider, such as NH-Hosting.

At the same time we also have the problem of building a website from the ground up, and as such choosing the correct hosting platform can provide you with a great foundation, and the incorrect one a huge disadvantage.This is why I am going to explain my decision to use the LAMP package (Linux, Apache, MySQL, PHP) to build the site upon.

Linux – Linux is a extremely stable and secure operating system which isolates every users file permissions, as per any other Unix platform. In reality it does not matter what the platform is in terms of search engine optimisation, but security must be a major consideration and whilst the Microsoft platforms are becoming even more secure with each new patch, the fact remains Unix platforms have a tendency to have bugs / security flaws found and patched even quicker.

Apache – According to recent statistics, Apache hosts 47.12% of websites on the internet, and this is not by coincidence. This is down to the fact Apache is a extremely reliable, customisable and cost effective platform to host your website on. A couple of the modules we will be working with in this article require apache on the web server to allow us to work with the website.

MySQL – This is another of the obvious choices, however it is more due to the ease with which it will connect to a PHP web server and reliably store the data.

PHP – This is the last decision, it is a programming language which has modules that work extremely efficiently with all of the other modules, and allows us a number of extremely useful functions which will make the building of this SEO CMS easier to build.

Older Posts »
SEO Content Footer