SEO Tips
Competition SEO Analysis
About embedding php
Surrounded by the script tag<script language="php"> echo("wahooooooooo! It works"); </script> |
Surrounded by <?php ?><?php echo("this is a simple php script"); ?> |
Include Files
Include files
Sometimes, it is good to extracts functions, classes, constants and common initialisations to a separate file that can be included in many files, avoiding to rewrite the same code.
can be used in more than one file. Other times, it is good practice to extract a list of constants or operations common to several scripts to a separate script and inclusion of files.
require files
require files are like include files except the script will not execute if the file is missing. Declared like this:
require('filename.php');
Avoid the inclusion of a file more than once.
Sometimes, because of the way code is written, a file will be included more than once (like a header) and it may hinder the execution of the script, give bad results or simply look ugly. include and require functions have a similar function which keeps track if the files has been included or not: include_once and require_once respectively
Functions
PHP Arrays
Defining an array is done the following way
$myarray = array();
filling it is done like this:
$myarray[0]=”first value”;
$myarray[] .= “second value”; // automatically added as next array spot
sometimes, we need to fill in several elements at once, just pass the elements the array function:
$myarray=array(“value one”,”value 2”, “value 3”,”value 4”);
arrays don’t have to be indexed on numbers, they can be associative. Associative arrays are similar to a dictionary where you look up a word and get the associated definition… in here, you enter a key (word) and you get its value (definition).
$myarray=array();
$myarray[“www”]=”world wide web”;
$myarray[“http”]=”Hypertext Transfer Protocol”;
$myarray[“tcp”]=”transfer control protocol”;
echo(“Definition for www is” . $myarray[“www”]);
sometimes, it is useful to know if an array has been set… you do this by using the isset fonction.
isset($myarray[“www”]) -> is true in the previous example
isset($myarray[“computer”] ) -> is false in the previous example, it’s not assigned
in cases where array indices are sequential, it is not necessary to specify each array index. For example:
$myArray[5]=1;
$myArray[]=6654;
$myArray[]="hello”;
Will result with the following array: array([5]=>1, [6]=>6654,[7]=>"hello")
Please note that any array element can be itself an array. For example:
$myArray=array(array(1,2,3,4),array(“apples”, “oranges”, “trees”), “mixed_array”=>array(“mixed”,”array”,123,);
As you can see, array contents can be of any variable type and assigned any associative key if needed… though if it will be used with a foreach statement, indices are not necessary and will default to sequential ordering, starting with 0.
SEO: optimize keywords for search engines
SEO TIP : Analyze your logs
See what keywords people are coming with (search terms) and see how you can optimize those words. Done well, putting these words in bold/ customizing page with search result can actually increase visitor satisfactionSEO TIP: Picking the right keywords
The more a word is popular, the more you will have competition for that keyword. Although it is good to rank well with these words, sometimes ranking number one for a less popular synonym may bring more traffic... sometimes even optimizing a particular page (not your main page) for a common spelling mistake can bring in traffic (not everyone spells perfectly)SEO TIP: Get the right Keyword Density
Forget what you learned in English class, repetition is good in SEO. Obviously it is important to make sense otherwise people will go away quickly and never come back... but repeat the important words, especially in titles, descriptions and header tags.SEO TIP: Domain match/ Subdomain match
If you can put your important keywords in the domain/ subdomain, it can help... especially if it is an exact match for the search expressionSEO TIP: Optimize the links
The links within your website should contain the important keywords to optimize. Ideally, links from other domains also should contain the keywordsSEO TIP: Diversify keyword optimization
Have some pages optimized for certain keywords and others optimized for other keywords. That way you can get even more trafficSEO TIP : do a comparative analysis
Tools such as google ad sense allow you to see how popular some keywords are... it will even suggest related wordsTOP SEO Mistakes
There is no perfect SEO strategy and opinions differ on what is most important. However, certain mistakes will certainly hurt your website SEO wise:
- Duplicate content - may get penalties and content will not rank. Instead, redirect to existing content and write variants of the text that will register on their own, if you must use nofollow links
- Not using SEO Friendly URLs - not only do you lose opportunity to include keywords in the url but egines will actually index your website slower if they realize it is a dynamic website
- Moving whole domain without redirecting - when you get a new domain, you get a temporary boost for fresh content but you lose all the reputation that your website has built including all backlinks and traffic associated with it. Make sure you at least redirect from the old content to new content (and preferrably transferring to corresponding pages and not a simple homepage redirect for all pages)
- Moving pages around within a website without redirecting - For many reasons, pages tend to move around due to the dynamic nature of the web. Make sure the people do not end up in a 404 when you move content around. Not only will people appreciate the redirect but it will help your rankings.
- Not Adding fresh content - by adding content on a regular basis, visitors are encouraged to come back... even engines love new content
- No descriptive tags - title/ meta tags though they may appear less useful than before are used
- No sitemap - sitemaps make everyone's life easier and help engines index your content faster. Make sure you submit them too.
- Not having a way to retain the visitors - mailing lists, social network presence are a good way to make sure you can contact the users later
- Preview search results - Different engines will use different algorithms to figure out how to present your data... make sure you preview your pages in search results and social networks like facebook
- Have the domain offline - Have at least one page, preferrably with target content
SEO your URLs
Optimization of content is important but also remember to optimize URLs as they have great importance in the eyes of search engines.
A good title tag
A similar set of rules for a good title tag apply... informative, short, most important keywords placed in the beginning but no need to include the domain name as it is already there from the actual domain name.
On Drupal, for example, this can consist in installing the pathauto module because it automatically renames nodes from "node/1" to a friendlier url based on the title of the article. You could do that manually but even with pathauto enabled you can still rename the URL to a friendlier name if you wish.
Optimize non HTML file names too
Remember to also SEO optimize non HTML files such as images, multimedia content and documents. Images are particularly important as some people may end up on your site after searching for images on google.
Domain name match
Also, if you have not yet settled for a domain name, try to include your targeted keywords in the domain name as they have a great weight, especially in the case of an exact match.
Use subdomains
Subdomains can be a good way to group content but also include keywords
Use local domains
Although I would suggest get a .com domain first, if you are present in more than one country then you may want to consider getting a localized domain name, it boosts in local rankings
Online Shopping Cart sales optimization
Why is SEO done? most times, to drive business... and the shopping cart is the unavoidable selling point of web sites. Having a site with products is a great way to get started making money, driving traffic is another great step in the right direction... digging further, increasing sales from current visitors is another important aspect. Here are a few tips to that aspect:
Shopping carts sales tip #1: high quality touched pictures
Web shoppers always hesitate when shopping online because they do not have the object physically in their presence. The more appealing the picture, the better for the user. make sure it is in focus with a nice mono color:pleasing contrasting background; make sure also their size is optimized... if it is too slow, then you have a problem
Shopping carts sales tip #2: all details filled in, appealing description
it is not enough to list a product, make sure all details are filled in; if options are available, talk about them... if some nice buzz words apply, put them in, imagine you were trying to pitch the product to the most difficult client and add the details, make the people want to own it
Shopping carts sales tip #3: related products
Sometimes, the people will like your website but the page they are there for is for a product they are not interested in; make sure that you have a few suggestions... preferably based on search terms or products they browser... or maybe past customer behavior
Shopping carts sales tip #4: cross selling
when people buy a toothbrush, suggest they buy toothpaste too... sell any related products, telling why this is a good pick with that product
Shopping carts sales tip #5: upselling
if they buy one product, suggest an upgrade to that product (with possibly a discounted amount for the upgrade). If they buy one month subscription, suggest a yearly subscription with a month free... or if they buy one item, suggest free shipping on the second (especially if shipping cost is not an issue)
Shopping carts sales tip #6: reminders for non completed sales
sometimes for one reason or another, sales will get interrupted. It does not necessarily mean your customer is not ready to buy... sometimes, they just have forgotten to complete the sale. if you have their info, send them a friendly reminder email; if they visit a partner site/ sister site or revisit the site, suggest they take action (with maybe a limited time offer)
shopping carts sales tip #7: make pages sharable
people like to ask for advice when buying online... make it easy for them to share the product they are looking at... all standard sharing advice applies
shopping carts sales tip #8: Gift lists/ wish lists
Sometimes, like for a wedding, people have gift lists or sometimes they have a wish list. Provide a way for people to provide such a list, their friends are more likely to purchase that item from you.
shopping carts sales tip #9: Order has coupon for next purchase
when people order, provide a time limited coupon for another purchase. Not only does it make the client feel better about their purchase but it builds brand loyalty... if they bought once and satisfied, likely to come back... and who knows, bring some friends
Shopping carts sales tip #10: Order assistant
a lot of people have difficulties choosing... some even hate picking a product... why don't you offer them a simple wizard which will ask them a few questions that will help them narrow their choices. This is especially true when you have a lot of products, but this can also work with smaller catalogs where you can insert selling points/ pitch throughout the wizard... pick important features to the customer and explain them in detail.
SEO Optimization: Backlinks
What are backlinks?
Backlinks are the web pages that point back to your website. The more you have, the more you appear on top of search engines. Not link are created equal though: the more popular a link is, the more it brings you up. For example, a link with a high page rank will bring you lots more bonus points on google... Fine, lets get all page rank 10 links... brilliant idea, except generally, it is harder to get listed on high page rank sites like wikipedia.
Types of links
There are several types of links:
It is important to distinguish further how sites link to each other:
- Two way links - Great way to get started... many people will link to you if you link to them. These links are also called reciprocal links. you link to me, I link back to you... they are useful but not as potent as one way link in the eyes of search engines. It is still a good way to get started.
- One way links - someone links to your website. Generally the best scenario but they are also the most difficult type of links to get. A good way to get some are web directories (paid or free). Also, have your URL in your profiles, your posts in communities. In the long run, the best way to get links is through having fresh quality content... people will tend to link to you naturally.
- Three way links: Person A links to site B, Site B links to site C and site C links to site A... Many times the links go through an intermediary
Homepage links vs deeplinks:
- home page links - hyperlinks that point to your main web page. The more you have, the more your ranking go up.
- deep links - links that link back to a specific page within your website (not the main page)
Ways to get links
A few ways exist to get links.
- Web directories such as DMoz are a great way to start
- Ask your partners - many times, they will be happy to link to you
- social networks - great way to engage potential visitors which in turn - if they like your content will post your link too
- Profiles - make sure all your profiles link to you
- Forum posts - always have your url in your forum post. Not worth much for each link but hey
- Paid links - can boost temporarily your popularity but not necessarily the best way in the long run. Not only do many of the paid services eventually lose their page rank but as soon as you stop paying, you lose all these links
- Fresh content & RSS feeds - that is the best way in the long run to get increasing number of links to your content. Combined with publishing to social networks. It is a great way to get links in the long run, builds brand awareness... and get the traffic of visitors coming back.
Not all are considered traditionally SEO per say like engaging social media... but keep in mind the more people come to your web site, the more they will talk about you, the more physical links you will get... which equals more traffic... which is the reason you are doing SEO in the first place
So which links are best/ which should I focus on?
Ideally, you should aim for one way links that are nested within a page of content from a high ranking site (also called an authority web site) but they are not always easy to get into unless you have quality content or money to spend. Again because quality content is king for SEO, it makes the process a lot easier if you have such content... sometimes you may get linked to without asking.
Of course, until you get such links, 2 way links are a good way to get started. Links in forum posts, user profiles are always a good plus. Posting links in social networks like twitter and facebook may help though not necessarily directly. Note that due to recent changes, posting on google plus may effect rankings of your contacts in google search results.
Whatever you do, avoid getting links from bad neighborhoods. and be careful about blackhat SEO... it may give you a temporary boost, but big sites like BMW or walmart have learned the hard way after they had been delisted/blacklisted by google for trying to game the system.
SEO - Ensure content is bookmarkable
Going through the web, for many reasons, web sites will break navigation (either through one big flash animation, englobing the site in a frame or dynamic loading through AJAX).
Yes engines such as google bot will find it but this is bad for SEO and traffic for several reasons:
- People can not bookmark the content, they can not come back to it as easily even if they liked the content
- People can not share a particular piece of relevant content thus will not bring people to your site. This is especially relevant when you want to develop virality - and be able to do it more than once: if the only thing people can share is the site's main page then after they have shared it once, never any incentive to share it again.
- people tend to come back more to user friendly sites... and allowing to come back to a specific page does go a long way
- It is bad for your SEO - Because your site's content is not as easily shared, you will never get any deeplinking... only homepage links
I understand that in some cases, it might not be an option (example no control over content generation) but still try to have a way to actually navigate straight to the content.
Content is king for SEO
There will be many tips to boost your SEO throughout this SEO tutorial. However, lets start with a tip that is not directly related to SEO. If you remember one tip, it is this one:
Fresh quality content is king for SEO
If you want your site to do better, make a daily commitment to add more content to your site.
Yes, with this font, it almost feels like shouting but this I wanted to make sure it sinks in... obviously we are not just done yet with traffic boosting techniques and there will be other tips throughout this SEO tutorial that do make a difference too. However, if you remember just this one tip, you are already off to a good start :)
Search engines like googlebot love fresh content, they get a temporary boost in ranking. A good way to do this is publish content gradually on a daily basis. Not only does it keep the search engines happy but it will actually get visitors interested and give them an incentive to come back more often.
It may be tempting to just put crappy content or duplicated content from sites like wikipedia... but this is a big no no:
- Duplicated content is detected automatically by search engines and will eventually get you penalties in robots rankings
- crappy content may get visitors to come in once but eventually visitors blacklist the site in their mind
A good way to insure that you have content added regularly is to write a chunk of articles in advance and schedule them to be published at regular intervals (daily or twice a day is good... more content is always good but does not hurt but does not necessarily help your cause)
Some sites I have done like sharepoems.com have ranked very quickly for the targeted keywords simply because there was a lot of original content.
Basic SEO Tips
In this page we talk about Basic SEO tips. Do not mistake the word basic for unimportant though... they are steps that are assumed to be taken by all websites that want to ranks. Yes, depending on the engine, some of that information may be ignored but it is still very important information to have because even if it does not affect the ranking, it can affect the way the information is displayed.
Title tag optimization
It is very important to have title filled in with every page and have it contain what is on the page. A good title should have the site name, the section or information about page content, target keywords and anything you care about most yet remain concise. Place all important keywords near the beginning as they are what the search engine.
Meta tags optimization
will not necessarily help you in rankings with google but they are still used by many engines to help direct what is displayed in search results. In case of content that is not as search engine friendly like flash animations, meta tags are particularly important. Some of the important meta tags are:
- description : describe the page content in one sentence or two max
- keywords : important keywords that are not necessarily mentioned in the page
- author : can be good to have though not as important
Optimize page sections with <h> tags
With wysiwyg editors, it can be tempting to skip use of the header tags because you can get the same formatting differently. However, header tags are vital for search engine optimization because they tell search engines that the current line has more weight. Make sure you include important keywords