View file wapirate/top/addsite.php

File size: 2.54Kb
<?php

header("Content-type: text/html; charset=ISO-8859-1");

echo "<?xml version=\"1.0\" encoding=\"ISO-8859-1\" ?>";

echo "<!DOCTYPE html PUBLIC \"-//WAPFORUM//DTD XHTML Mobile 1.0//EN\"\"http://www.wapforum.org/DTD/xhtml-mobile10.dtd\">";

echo "<html xmlns=\"http://www.w3.org/1999/xhtml\">";



echo "<head><title>wapirate.net top sites</title>";

      echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style/style.css\" />";

echo "<meta http-equiv=\"Cache-Control\" content=\"must-revalidate\" />

<meta http-equiv=\"Cache-Control\" content=\"no-cache\"/>

<meta name=\"description\" content=\"wapirate.net :)\"> 

<meta name=\"keywords\" content=\"free, community, forums, chat, wap, communicate\"></head>";

echo "<body>";

?>



<?php

echo "<onevent type=\"onenterforward\"><refresh><setvar name=\"lnk\" value=\"http://\"/><setvar name=\"imgu\" value=\"http://\"/></refresh></onevent>";

?>

<p align="center">

<?php

include("func.php");

include("conf.php");

$uid=$_GET["uid"];

$pwd=$_GET["pwd"];



connect($dbserver,$dbname,$dbuser,$dbpass);

echo "<img src=\"logo.gif\" alt=\"wapirate.net\"/><br/><br/>";

if((isadmin($uid,$pwd)) || (($res = login($uid,$pwd))==0))

{



    echo "<b>Add Site</b></p>";

   

    echo "<form action=\"addsf.php?uid=$uid&amp;pwd=$pwd\" method=\"post\">";

    echo "Site Name:<input name=\"snm\" maxlength=\"30\" type=\"text\" value=\"\"/><br/>";

    echo "Site Link: <input name=\"lnk\" maxlength=\"200\" type=\"text\" value=\"http://\"/><br/>";

    echo "Logo URL: <input name=\"imgu\" maxlength=\"200\" type=\"text\" value=\"http://\"/><br/>";

    echo "Email: <input name=\"email\" maxlength=\"200\" type=\"text\" value=\"@\"/><br/>";

    echo "Description: <input name=\"dsc\" maxlength=\"200\" type=\"text\" value=\"\"/><br/>";

    echo "Keywords: <input name=\"kwrd\" maxlength=\"200\" type=\"text\" value=\"\"/><br/>";

    echo "<select name=\"catg\" >";

    //cats

    $cats = mysql_query("SELECT * FROM cats ORDER BY name;");

    while ($cat = mysql_fetch_array($cats))

    {

    echo "<option value=\"$cat[0]\">$cat[1]</option>";

     }

    //cats

    echo "</select><br/>";

    echo "<input type=\"submit\" value=\"Add\"/>";

    echo "<br/><a href=\"cpanel.php?uid=$uid&amp;pwd=$pwd&amp;logm=gt\">Cancel</a><br/>";

    echo "</p><p align=\"center\">";

}else{

  echo "You don't have the privileges to do this";

}

echo "<br/><a href=\"index.php?uid=$uid&amp;pwd=$pwd\"><img src=\"images/home.gif\" alt=\"*\"/>Home</a>";

?>

</p>

</body>

</html>