do you have XML support installed ?

i don't realy know if you need it but you might ...

Steve

> -----Original Message-----
> From: Kelvin [mailto:[EMAIL PROTECTED]]
> Sent: 25 April 2001 18:38
> To: [EMAIL PROTECTED]
> Subject: [PHP-DB] WML vs PHP and MYSQL
> 
> 
> Hi,
> 
>        I am trying to retrieve data from MYSQL inside of PHP 
> code which I
> placed under WML page.
>        But every time I compile this file, it said compile 
> error.   Can
> anyone help?
> 
> ----------3.php-------------
> 
> <?php
> header("Content-type: text/vnd.wap.wml");
> echo("<?xml version=\"1.0\"?>\n");
> echo("<!DOCTYPE wml PUBLIC \"-//WAPFORUM//DTD WML 1.1//EN\"
> \"http://www.wapforum.org/DTD/wml_1.1.xml\";>\n\n");
> ?>
> <wml>
>       <card id="acctnum" title="Account Number">
>           <p>
>              <?php
>                 $password='1234';
>                 if ($acctnum == $password)
>                {
>                    include("dedb.inc");                      // DB
> connection file.
>                    $query="SELECT * FROM uget";
>                    $result= mysql_query($query) or die(mysql_error());
>                    $field=mysql_num_rows($result);
>                    srand(time());
>                    $num=rand(1,$field);
> 
>                    $query1="SELECT * FROM uget where number='$num'";
>                    $result1= mysql_query($query1) or 
> die(mysql_error());
>                    $row=mysql_fetch_array($result1);
> 
>                    print($row["message"]);
>                }
>               else
>                {
>                    print("Password wrong");
>                }
>              ?>
>           </p>
>       </card>
> </wml>
> --------------------------------------------------------------
> -------------
> 
> 
> Best Regards,
> Kelvin.
> 
> 
> 
> -- 
> PHP Database Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: 
> [EMAIL PROTECTED]
> 

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to