Connecting Tech Pros Worldwide Forums | Help | Site Map

Meta Tags

Cezary
Guest
 
Posts: n/a
#1: Jul 17 '05
Hello.

I was read PHP manual, but i'm not sure yet. Here is my meta tags in html:

<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=ISO-8859-2">
<META HTTP-EQUIV="Expires" CONTENT="0">
<META HTTP-EQUIV="Cache-Control" CONTENT="no-store, no-cache,
must-revalidate, max-age=0, post-check=0, pre-check=0">
<META HTTP-EQUIV="Pragma" CONTENT="no-cache">

<META NAME="title" CONTENT="test">
<META NAME="description" CONTENT="Test description.">
<META NAME="keywords" CONTENT="a b c">
<META NAME="robots" CONTENT="All">
<META NAME="copyright" CONTENT="x y z ">
<META NAME="author" content="x y z">

and here is in PHP:

// META TAGS CONFIGURATION
// Cache deactivate
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); // Date in the past
header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT"); // always
modified

// HTTP/1.1
header("Cache-Control: no-store, no-cache, must-revalidate");
header("Cache-Control: post-check=0, pre-check=0", false);

// HTTP/1.0
header("Pragma: no-cache");

header("Content-Type: text/html;charset=ISO-8859-2">;
header("Title: test");
header("Content-Description: Test description.");
header("Keywords: a b c");
header("Robots: All");
header("Copyright: xyz");
header("Author: xyz");

Is PHP code correct?
Any suggestions appreciated.

Greets,
Cezary.



R. Rajesh Jeba Anbiah
Guest
 
Posts: n/a
#2: Jul 17 '05

re: Meta Tags


"Cezary" <cezaryk@imail.net.pl> wrote in message news:<c7d74a$llv$1@nemesis.news.tpi.pl>...[color=blue]
> Hello.
>
> I was read PHP manual, but i'm not sure yet. Here is my meta tags in html:
>
> <META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=ISO-8859-2">
> <META HTTP-EQUIV="Expires" CONTENT="0">
> <META HTTP-EQUIV="Cache-Control" CONTENT="no-store, no-cache,
> must-revalidate, max-age=0, post-check=0, pre-check=0">
> <META HTTP-EQUIV="Pragma" CONTENT="no-cache">[/color]

AFAIK, the above Meta tags are kind of fix or HTML workaround for
the headers.
[color=blue]
>
> <META NAME="title" CONTENT="test">
> <META NAME="description" CONTENT="Test description.">
> <META NAME="keywords" CONTENT="a b c">
> <META NAME="robots" CONTENT="All">
> <META NAME="copyright" CONTENT="x y z ">
> <META NAME="author" content="x y z">[/color]

And the above Meta tags and attributes are pure HTML.
[color=blue]
> and here is in PHP:
>
> // META TAGS CONFIGURATION
> // Cache deactivate
> header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); // Date in the past
> header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT"); // always
> modified
>
> // HTTP/1.1
> header("Cache-Control: no-store, no-cache, must-revalidate");
> header("Cache-Control: post-check=0, pre-check=0", false);
>
> // HTTP/1.0
> header("Pragma: no-cache");
>
> header("Content-Type: text/html;charset=ISO-8859-2">;[/color]

All above are AFAIK, Ok.
[color=blue]
> header("Title: test");
> header("Content-Description: Test description.");
> header("Keywords: a b c");
> header("Robots: All");
> header("Copyright: xyz");
> header("Author: xyz");[/color]

Hmmm... AFAIK, no. These are not headers and can be called as
user-defined headers. But, I guess, there is no effect of these
headers. Also, think, if such user-defined headers are present, it
must be prefixed with "X" like header("X-Author: xyz").

--
| Just another PHP saint |
Email: rrjanbiah-at-Y!com
Closed Thread