Jump to content

include meta tags


speedy33417

Recommended Posts

I have a website where I recently changed my source code to including the metatags with PHP script as opposed to fully coding the declaration part in HTML. The website ranked pretty good on Yahoo's generec search; always on the first page.

Now a few weeks later my site does not rank on Yahoo anywhere!!! I've tried all the keywords that I've had and my website has fallen off the grid altogether.

 

Does it have anything to do with the php including the meta tags or is it a Yahoo thing? My site has no adult content and is a basic small business website and see no reason for it to be flagged or anything like that.

What can I do?

 

Link to comment
https://forums.phpfreaks.com/topic/97913-include-meta-tags/
Share on other sites

Sorry, I can't provide link, but here's the code.

 

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<meta http-equiv="imagetoolbar" content="no" />
<meta name="keywords" content="<?php include("includes/keywords.php"); ?>" />
<meta name="description" content="<?php include("includes/description.php"); ?>" />
<link rel="stylesheet" type="text/css" href="includes/theme.css" />

 

The php script generates the same HTML code that was in its place.

By doing View Source on IE I verified that as well.

Link to comment
https://forums.phpfreaks.com/topic/97913-include-meta-tags/#findComment-500948
Share on other sites

Your include area should look something like this:

<HEAD>

<TITLE>CateringUnlimited.Com - Central Coast / San Luis Obispo Caterer</TITLE>

<?php include('includes/keywords.php') ; ?>

 

The keywords.php should look simular to this:

<META name="Description" content="Kickin Butt Company.">
<META name="Keywords" content="money good,money great,money oh yeah">

 

Hope this helps.

Link to comment
https://forums.phpfreaks.com/topic/97913-include-meta-tags/#findComment-500949
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.