Jump to content

[SOLVED] how to replace new line posted html form by <br>


jaas

Recommended Posts

hi,

 

 

My code goes like this :

 

<HTML FORM action="text.php" method="post">

 

here I am submitting

textarea = "I

                  am

                  jaas"

</HTML FORM>

 

when it goes to browser it goes like

some path?textarea=I00A00am00A00jaas

 

actually there are some different characters.to give example I am using '00A00' instead of that.

 

After that I am fetching this in a php code "text.php" as follows :

 

<?php

$tmp_text = $_GET["textarea"];

 

echo $tmp_text;

?>

 

 

Result is "I am jaas" and not the expected.

 

Please tell me the way out.

 

Regards.

 

MySQL? Huh? And the question... What? Please rephrase it. Your HTML is incorrect. Forms look like this:

 

<form action="nextpage.php" method="post">
<textarea name="comment"></textarea>
</form>

 

And how is the value of the textarea ending up in your URL if you are using 'post' as your method. Doesn't make sense.

Hi guys, I have a similar issue.

I have a website where I post reviews for plays, musicals, etc.

On the Review page, I have something like this, to output Title, Image, and the Review Text

 

<h1><?php echo $row_rs_review['reviewTitle']; ?></h1><br />

<p><img src="_revIMG/<?php echo $row_rs_review['reviewIMG']; ?>"/> </p>

<p><?php echo $row_rs_review['reviewDesc']; ?><br />

 

The problem is that all of my reviews are long and often separated by paragraphs. How can I display the text properly without being shown continuously?

 

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.