Can Anyone Help me PLZ ????

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Can Anyone Help me PLZ ????

    Hi dudez !
    Here is da Registation page of my Lava Site!
    i 've tried many ways to make this page html, but i cant ! .. coz, i m a n00b ..

    Can anyone make this page html plz ??

    Here is my page >>>

    Code:
    <?php
    header("Content-type: text/vnd.wap.wml");
    header("Cache-Control: no-store, no-cache, must-revalidate");
    echo "<?xml version=\"1.0\"?>";
    echo "<!DOCTYPE wml PUBLIC \"-//WAPFORUM//DTD WML 1.1//EN\"". " \"http://www.wapforum.org/DTD/wml_1.1.xml\">\n";
    ?>
    <wml>
    <card id="Mobile Forum" title="Register Form">
    <p align="left">
    <?php
    include ("config.php");
    include ("core.php");
    connectdb();
    $sitename = mysql_fetch_array(mysql_query("SELECT value FROM ibwf_settings WHERE name='sitename'"));
    $sitename = $sitename[0];
    $brws = explode("/",$HTTP_USER_AGENT);
    $ubr = $brws[0];
    $ipr = getip();
    $uip = explode(".",$ipr);
    
    $isipbanned = mysql_fetch_assoc(mysql_query("SELECT * FROM ibwf_users ORDER BY regdate DESC LIMIT 0,1"));
    $bantime = $isipbanned['regdate'] + 300;
    
    $time = time();
    
    if((!canreg())||(isipbanned($ipr,$ubr)))
    {
    echo "Registration is disabled at the moment, please check later";
    }
    elseif($bantime > $time)
    {
    echo "<p>";
    echo "<img src=\"../images/notok.gif\" alt=\"X\"/>Registration limit for this IP is exceeded. Please try again after sometime.";
    echo "</p>";
    }
    else
    {
    if (!empty($_REQUEST['act']) && $_REQUEST['act'] == $_REQUEST['code'] && $_REQUEST['uid'] !== '' ) {
    $uid = $_REQUEST['uid'];
    $pwd = $_REQUEST['pwd'];
    $cpw = $_REQUEST['cpw'];
    $email = $_REQUEST['email'];
    
    if(trim($uid)=="")
    {
        echo "Username Empty. Please Type Your Name.<br/><a href=\"register.php\">Back</a>";
    }else if(trim($pwd)=="")
    {
        echo "Please Type Your Password.<br/><a href=\"register.php\">Back</a>";
    }else if(trim($cpw)=="")
    {
        echo "Please Type Your Password Again.<br/><a href=\"register.php\">Back</a>";
    }else if(spacesin($uid)||scharin($uid))
    {
        echo "Username is not valid!<br/><a href=\"register.php\">Back</a>";
    }else if(spacesin($pwd)||scharin($pwd))
    {
        echo "Password is not valid!<br/><a href=\"register.php\">Back</a>";
    }else if($pwd!=$cpw)
    {
        echo "Passwords doesn't match.<br/><a href=\"register.php\">Back</a>";
    }else if(strlen($uid)<4)
    {
        echo "Username must be 4 characters or more.<br/><a href=\"register.php\">Back</a>";
    }else if(strlen($pwd)<4)
    {
        echo "Password must be 4 characters or more.<br/><a href=\"register.php\">Back</a>";
    }else if(isdigitf($uid))
    {
        echo "Username must start with a letter from a-z.<br/><a href=\"register.php\">Back</a>";
    }else if(checknick($uid)==1)
    {
        echo "Username is reserved for Admins of the site.<br/><a href=\"register.php\">Back</a>";
    
    }else if(checknick($uid)==2)
    {
        echo "Please choose an appropriate username.<br/><a href=\"register.php\">Back</a>";
    
    }else if(trim($email)=="")
    {
        echo "You must enter a valid email address.<br/><a href=\"register.php\">Back</a>";
    
    }else if(register($uid,$pwd,$usx,$day,$month,$year,$ulc,$email,$info, $ubr)==1)
    {
        echo "Username already in use, choose a different one.<br/><a href=\"register.php\">Back</a>";
    }else if(register($uid,$pwd,$usx,$day,$month,$year,$ulc,$email,$info, $ubr)==2)
    {
        echo "Unknown mysql error try registering later.<br/><a href=\"register.php\">Back</a>";
    }else{
      echo "Registration completed successfully!<br/>";
      echo "<br/><b>Username: </b>$uid<br/>";
      echo "<b>Password: </b>$pwd<br/>";
      
      
      if(validation())
      {
      echo "Please give us up to an hour to validate you (normally it be done within 10 minutes) If you have not been after this period of time u can email the owner<br/>";
    echo '<p align="center">';
    echo '<a href="index.php">Home</a>';
    echo '</p>';
      }else{
      echo "<a href=\"login.php?loguid=$uid&amp;logpwd=$pwd\"><img src=\"../images/home.gif\" alt=\"*\"/>";
      echo "Login</a>";
      }
    }
    }
    else{
    ?>
    <small>
    [&#187;] 
    Allowed characters in userid and password are a-z, 0-9, and -_ only<br/>
    [&#187;] 
    No vulgar words are accepted in Username<br/>
    [&#187;] 
    Username and Password must contain at least 4 characters<br/>
    [&#187;] 
    Username must begin with a letter and cannot contain capitals<br/>
    [&#187;] 
    Password will be case sensitive<br/>
    [&#187;] 
    All The Fields Are Necessary!<br/><br/>
    </small>
    <?php
    $code = substr(md5(time()),0,5);
    
    echo 'Username:<br/> <input name="tfuid" format="*x" maxlength="15"/><br/>';
    
    echo 'Password:<br/> <input type="password" name="tfpwd" format="*x" maxlength="30"/><br/>';
    
    echo "Repeat Password:<br/> <input type=\"password\" name=\"tfcpw\" format=\"*x\" maxlength=\"30\"/><br/>";
    
    echo "I am:<br/>";
    
    echo "<select name=\"opsex\" value=\"M\">";
    
    echo "<option value=\"M\">Male</option>";
    
    echo "<option value=\"F\">Female</option>";
    
    echo "</select><br/>";
    
    echo "Country:<br/> <input name=\"tfloc\"  maxlength=\"100\"/><br/>";
    
    echo "Email:<br/> <input name=\"email\" maxlength=\"50\"/><br/>";
    
    echo "More Info:<br/> <input name=\"info\" maxlength=\"100\"/><br/>";
      
    echo "<b><u>Verification:</u></b><br/>Type the following code in the box below:<br/>";
      
    echo "<b>Code: </b> $code<br/>";
    
    echo "<input name=\"code\" type=\"text\" /><br/>";
      
    echo "<anchor>Register";
    
    echo "<go href=\"register.php\" method=\"post\">";
    
    echo "<postfield name=\"uid\" value=\"$(tfuid)\"/>";
    
    echo "<postfield name=\"pwd\" value=\"$(tfpwd)\"/>";
    
    echo "<postfield name=\"cpw\" value=\"$(tfcpw)\"/>";
    
    echo "<postfield name=\"day\" value=\"$(day)\"/>";
    
    echo "<postfield name=\"month\" value=\"$(month)\"/>";
    
    echo "<postfield name=\"year\" value=\"$(year)\"/>";
    
    echo "<postfield name=\"usx\" value=\"$(opsex)\"/>";
    
    echo "<postfield name=\"ulc\" value=\"$(tfloc)\"/>";
    
    echo "<postfield name=\"email\" value=\"$(email)\"/>";
    
    echo "<postfield name=\"info\" value=\"$(info)\"/>";
      
    echo "<postfield name=\"code\" value=\"$(code)\"/>";
    
    echo "<postfield name=\"act\" value=\"$code\"/>";
    
    echo "</go></anchor><br/><br/><br/>";
    echo '</p><p align="center">';
    echo '<a href="index.php">Home</a>';
    }}
    ?>
    </p>
    </card>
    </wml>
    Thanks In Advance
    Last edited by Guest; 06.06.11, 12:31.

    #2
    PHP Code:
    <?php
    header
    ("Content-type: text/html");
    echo 
    '<?xml version="1.0" encoding="UTF-8" ?>';
    echo 
    '<!DOCTYPE html PUBLIC "-//WAPFORUM//DTD XHTML Mobile 1.0//EN"';
    echo 
    '"http://www.wapforum.org/DTD/xhtml-mobile10.dtd">';
    echo 
    '<html xmlns="http://www.w3.org/1999/xhtml">';
    ?>
    <title>Register Form</title>
    <body>
    <p align="left">
    <?php
    include ("config.php");
    include (
    "core.php");
    connectdb();
    $sitename mysql_fetch_array(mysql_query("SELECT value FROM ibwf_settings WHERE name='sitename'"));
    $sitename $sitename[0];
    $brws explode("/",$HTTP_USER_AGENT);
    $ubr $brws[0];
    $ipr getip();
    $uip explode(".",$ipr);

    $isipbanned mysql_fetch_assoc(mysql_query("SELECT * FROM ibwf_users ORDER BY regdate DESC LIMIT 0,1"));
    $bantime $isipbanned['regdate'] + 300;

    $time time();

    if((!
    canreg())||(isipbanned($ipr,$ubr)))
    {
    echo 
    "Registration is disabled at the moment, please check later";
    }
    elseif(
    $bantime $time)
    {
    echo 
    "<p>";
    echo 
    "<img src=\"../images/notok.gif\" alt=\"X\"/>Registration limit for this IP is exceeded. Please try again after sometime.";
    echo 
    "</p>";
    }
    else
    {
    if (!empty(
    $_REQUEST['act']) && $_REQUEST['act'] == $_REQUEST['code'] && $_REQUEST['uid'] !== '' ) {
    $uid $_REQUEST['uid'];
    $pwd $_REQUEST['pwd'];
    $cpw $_REQUEST['cpw'];
    $email $_REQUEST['email'];

    if(
    trim($uid)=="")
    {
        echo 
    "Username Empty. Please Type Your Name.<br/><a href=\"register.php\">Back</a>";
    }else if(
    trim($pwd)=="")
    {
        echo 
    "Please Type Your Password.<br/><a href=\"register.php\">Back</a>";
    }else if(
    trim($cpw)=="")
    {
        echo 
    "Please Type Your Password Again.<br/><a href=\"register.php\">Back</a>";
    }else if(
    spacesin($uid)||scharin($uid))
    {
        echo 
    "Username is not valid!<br/><a href=\"register.php\">Back</a>";
    }else if(
    spacesin($pwd)||scharin($pwd))
    {
        echo 
    "Password is not valid!<br/><a href=\"register.php\">Back</a>";
    }else if(
    $pwd!=$cpw)
    {
        echo 
    "Passwords doesn't match.<br/><a href=\"register.php\">Back</a>";
    }else if(
    strlen($uid)<4)
    {
        echo 
    "Username must be 4 characters or more.<br/><a href=\"register.php\">Back</a>";
    }else if(
    strlen($pwd)<4)
    {
        echo 
    "Password must be 4 characters or more.<br/><a href=\"register.php\">Back</a>";
    }else if(
    isdigitf($uid))
    {
        echo 
    "Username must start with a letter from a-z.<br/><a href=\"register.php\">Back</a>";
    }else if(
    checknick($uid)==1)
    {
        echo 
    "Username is reserved for Admins of the site.<br/><a href=\"register.php\">Back</a>";

    }else if(
    checknick($uid)==2)
    {
        echo 
    "Please choose an appropriate username.<br/><a href=\"register.php\">Back</a>";

    }else if(
    trim($email)=="")
    {
        echo 
    "You must enter a valid email address.<br/><a href=\"register.php\">Back</a>";

    }else if(
    register($uid,$pwd,$usx,$day,$month,$year,$ulc,$email,$info$ubr)==1)
    {
        echo 
    "Username already in use, choose a different one.<br/><a href=\"register.php\">Back</a>";
    }else if(
    register($uid,$pwd,$usx,$day,$month,$year,$ulc,$email,$info$ubr)==2)
    {
        echo 
    "Unknown mysql error try registering later.<br/><a href=\"register.php\">Back</a>";
    }else{
      echo 
    "Registration completed successfully!<br/>";
      echo 
    "<br/><b>Username: </b>$uid<br/>";
      echo 
    "<b>Password: </b>$pwd<br/>";
      
      
      if(
    validation())
      {
      echo 
    "Please give us up to an hour to validate you (normally it be done within 10 minutes) If you have not been after this period of time u can email the owner<br/>";
    echo 
    '<p align="center">';
    echo 
    '<a href="index.php">Home</a>';
    echo 
    '</p>';
      }else{
      echo 
    "<a href=\"login.php?loguid=$uid&amp;logpwd=$pwd\"><img src=\"../images/home.gif\" alt=\"*\"/>";
      echo 
    "Login</a>";
      }
    }
    }
    else{
    ?>
    <small>
    [»] 
    Allowed characters in userid and password are a-z, 0-9, and -_ only<br/>
    [»] 
    No vulgar words are accepted in Username<br/>
    [»] 
    Username and Password must contain at least 4 characters<br/>
    [»] 
    Username must begin with a letter and cannot contain capitals<br/>
    [»] 
    Password will be case sensitive<br/>
    [»] 
    All The Fields Are Necessary!<br/><br/>
    </small>
    <?php
    $code 
    substr(md5(time()),0,5);

    echo 
    "<form action=\"register.php\" method=\"post\">";
    echo 
    'Username:<br/> <input name="tfuid" format="*x" maxlength="15"/><br/>';
    echo 
    'Password:<br/> <input type="password" name="tfpwd" format="*x" maxlength="30"/><br/>';
    echo 
    "Repeat Password:<br/> <input type=\"password\" name=\"tfcpw\" format=\"*x\" maxlength=\"30\"/><br/>";
    echo 
    "I am:<br/>";
    echo 
    "<select name=\"opsex\" value=\"M\">";
    echo 
    "<option value=\"M\">Male</option>";
    echo 
    "<option value=\"F\">Female</option>";
    echo 
    "</select><br/>";
    echo 
    "Country:<br/> <input name=\"tfloc\"  maxlength=\"100\"/><br/>";
    echo 
    "Email:<br/> <input name=\"email\" maxlength=\"50\"/><br/>";
    echo 
    "More Info:<br/> <input name=\"info\" maxlength=\"100\"/><br/>";  
    echo 
    "<b><u>Verification:</u></b><br/>Type the following code in the box below:<br/>";
    echo 
    "<b>Code: </b> $code<br/>";
    echo 
    "<input name=\"code\" type=\"text\" /><br/>";
    echo 
    "<input type=\"hidden\" name=\"act\" value=\"$code\"/>";
    echo 
    "<input type=\"submit\" value=\"send\"/>";
    echo 
    "</form>";

    echo 
    '</p><p align="center">';
    echo 
    '<a href="index.php">Home</a>';
    }}
    ?>
    </p>
    </body>
    </html>
    Did I help you?
    You can help me too
    Your donations will help me finance my studies.

    Comment


      #3
      @ Kei_ki7 :

      Thanks For Reply .... But its cant get username, pass, e-mail, sex from register Form !

      Than i Add this Code >>
      Code:
      echo "<input type=\"hidden\" name=\"uid\" value=\"$tfuid\"/>";
      echo "<input type=\"hidden\" name=\"pwd\" value=\"$tfpwd\"/>";
      echo "<input type=\"hidden\" name=\"cpw\" value=\"$tfcpw\"/>";
      echo "<input type=\"hidden\" name=\"usx\" value=\"$opsex\"/>";
      echo "<input type=\"hidden\" name=\"email\" value=\"$email\"/>";
      But No Improve ! ... Now The Page got Refreshed when i click in register Button !
      PLZ Help meh !

      Comment


        #4
        This method is post right?

        echo "<input type=\"hidden\" name=\"uid\" value=\"$tfuid\"/>";
        echo "<input type=\"hidden\" name=\"pwd\" value=\"$tfpwd\"/>";
        echo "<input type=\"hidden\" name=\"cpw\" value=\"$tfcpw\"/>";
        echo "<input type=\"hidden\" name=\"usx\" value=\"$opsex\"/>";
        echo "<input type=\"hidden\" name=\"email\" value=\"$email\"/>";
        Do you mean you added this code?
        If yes, then you really don't get the value, because you declare a value for those names
        Did I help you?
        You can help me too
        Your donations will help me finance my studies.

        Comment

        Working...
        X