kows
Dec 27th, 2003, 03:26 PM
this was originally posted by shaunyboy.. when i tried to reply it said it was an invalid thread, so, i'll just repost it all..
ok, i'm just learnign php, and am kinda stuck. I am doign abotu submitting values, then an output being displayed, and it never works! i know that my code is right, as i am copying it out a book, or using examples off the internet!
both files are in my localhost directory on my pc, and other php pages which dont involve submitting stuff work fine!
All i get when i click the submit botton is a blank page!
here is an example of some code:
HTML PAGE:
<html><head> <title> String Manipulation</title> </head>
<body>
<form action="strings.php" method="post">
<b>Enter some text here:</b><br/>
<textarea name="txt" rows="3" cols="45"></textarea><br/>
<input type="radio" name="fcn" value="strlen">
Find the text length
<input type="radio" name="fcn" value="strrev">
Reverse the text<br/>
<input type="radio" name="fcn" value="strtoupper">
Chaneg to uppercase
<input type="radio" name="fcn" value="strtolower">
Chaneg to lowercase<br/>
<input type="radio" name="fcn" value="ucwords">
Make the first letters uppercase<hr/>
<input type="submit" value="Manipulate">
</form>
</bosy>
</html>
PHP RESULTS PAGE:
<html><head> <title>Results</title> </head>
<body>
<?php echo( $fcn($txt) ); ?>
</body>
</html>
please help
ok, i'm just learnign php, and am kinda stuck. I am doign abotu submitting values, then an output being displayed, and it never works! i know that my code is right, as i am copying it out a book, or using examples off the internet!
both files are in my localhost directory on my pc, and other php pages which dont involve submitting stuff work fine!
All i get when i click the submit botton is a blank page!
here is an example of some code:
HTML PAGE:
<html><head> <title> String Manipulation</title> </head>
<body>
<form action="strings.php" method="post">
<b>Enter some text here:</b><br/>
<textarea name="txt" rows="3" cols="45"></textarea><br/>
<input type="radio" name="fcn" value="strlen">
Find the text length
<input type="radio" name="fcn" value="strrev">
Reverse the text<br/>
<input type="radio" name="fcn" value="strtoupper">
Chaneg to uppercase
<input type="radio" name="fcn" value="strtolower">
Chaneg to lowercase<br/>
<input type="radio" name="fcn" value="ucwords">
Make the first letters uppercase<hr/>
<input type="submit" value="Manipulate">
</form>
</bosy>
</html>
PHP RESULTS PAGE:
<html><head> <title>Results</title> </head>
<body>
<?php echo( $fcn($txt) ); ?>
</body>
</html>
please help