to all guru
how can i insert meta tags and keywords in existing htm fiiles using PHP
example.
<!-- this is the file where i insert the code -->
sample1.htm
<html>
<head>
<title>insert here </title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body>
</body>
</html>
and in insert.php
<html>
<head>
<title>Insert keyword</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<?
$act=@$HTTP_POST_VARS['Submit'];
if ($act=="Submit") {
// this is where i insert my keywords
$pcont=$_POST['text'];
$fp = fopen("sample1.htm","w");
fwrite($fp, $pcont);
fclose( $fp );
}
if ($act=="Reset") {
echo "";
}
?>
<body>
<form name="keyword" method="post" action="insert.php">
<table width="100">
<tr>
<td>Description
</td>
<td> <input type="text" name="description">
</td>
</tr>
<tr>
<td>
Keyword
</td>
<td> <textarea name="text" cols="45" rows="5"></textarea>
</td>
</tr>
</table>
<input type="submit" name="Submit" value="Submit" onclick="return submitme(keyword)">
<input type="submit" name="Submit" value="Reset">
</form>
</body>
</html>
and the output of sample1.htm
<html>
<head>
<!-- this meta name should be insreted after i process the insert.php -->
<meta name="description" content="Spoilers, body, ground effects, spoilers, wings, wood dash kits, auto graphics, body side molding, roof racks, chrome rocker and fender trim, fender flares, razzi, xenon, truck and auto Accessories..">
<title>insert here </title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body>
</body>
</html>