[PHP] PHP function using a WML variable from a select list as to access the right data in a MYSQL database

2001-02-08 Thread Kato Strandjord

I use apache server on win2000, php4, mysql and wml which I test local on my
harddrive.

The code under is working fine when I test it on emulators like UP SDK from
phone.com. or other, but i have fooled it to use static variables which is
not the solution i want.
My problem is. How can I use my variable:
print "";
in this code under so that I can use its value in my php function:
$tabfag=finnMeldinger($fagnr);
I can see the WML variable if i print it out in WML, but i can not print it
out as a variable in PHP. I have fooled the php function and put a static
variable in it, instead of the dynamic WML variable, which is generated from
a select list. I have tried for a week but al kinds of tricks did not work.
At one time i got the value from WML to PHP, but it came out like this
"=so480". The sign = was impossible to remove, so i could not use it. The
correct value is "so480" with out the "="

";
echo "http://www.wapforum.org/DTD/wml_1.1.xml\">";
?>




";//HELP1
require ("funksjoner.php");
$tabfag=finnfag();
if (mysql_num_rows($tabfag) > 0)
{ 
while ($row = mysql_fetch_array($tabfag)) 
{ 
print "$row[fagbeskrivelse]"; 

}//while 
}//if 
$temp=$fagkode; 
?> 
Done. 
 
 
 
 
 
 

 
//HELP2 
 0) 

{ 
while ($row = mysql_fetch_array($tabfag)) 
{ 
print "$row[dato]"; 
}//while 
}//if 
?> 
Done. 
 
go $(fagkode) $(dato)// just another test, and is working fine so i can see both WML 
variables from other cards 
 
 
 
 

 
 
 
 




-- 
PHP General 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] Parse WML to PHP?

2001-02-08 Thread Kato Strandjord

How is it possible to parse a WML strin variable with a value="SO480", and
parse over to a PHP strin variabl , so you can use it to in a PFP function.
I get a error messages in M3gate WAP emulator, an UP SDK emulator telling me
this"unsupported content-type: text/html"



-- 
PHP General 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] Storing and getting variables between php functions?

2001-02-09 Thread Kato Strandjord

HI is it possible to do what i have shown with the 3 php files under? I want
that a variable stored in a another php file like this, and then i want to
get the stored variable  from a 3rd php file. How can i do this, i have
tried it but it does not work. When i get the variable in the 3rd php file
it is empty. It seems like i cant store variable outside the function, and
then use it in other functions in the same php file. Is that true! In JAVA
and C++ this was a piece of cake...
Thanks in advance from a frustrated student from Norway.

--
php file called setget.php

--
 php file called set.php

---
php file called get.php

--



-- 
PHP General 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]