Jump to content

[SOLVED] textarea


dare87

Recommended Posts

I have this simple form that allows me to add news to my website, but I am running into a problem. I now have other people entering in information. The problem I am having is that I just right the news in html, because I want br and such but is there a way to just read the textarea as text and not html?

 

example of what I want.

 

How are you doing today?

 

I am doing fine, thanks.

 

Vs.

 

How are you doing today?<br><br>I am doing fine, thanks.

 

Here is my form.

 

<form name="composeNews" action="news_compose.php" method="post">
				<table align="center" width="100%" border="0" cellpadding="1" cellspacing="0">
				<tr>
					<td class="title" colspan="2">Compose - News</td>
				</tr>
				<tr>
					<td>Title:</td>
					<td><input type="text" class="required" name="title" id="focus" size="40" value="" maxlength="200"></td>
				</tr>
				<tr>
					<td> </td>
					<td>
						<input type="button" class="button" name="addURL" value="Add Link" onClick="addUrl();">
						<input type="button" class="button" name="addPicture" value="Add Image" onClick="addImg();">
						<input type="button" class="bold" name="bold" value="B" onClick="boldText();">
						<input type="button" class="italic" name="bold" value="I" onClick="italicText();">
						<input type="button" class="underline" name="bold" value="U" onClick="underlineText();">
					</td>
				</tr>
				<tr>
					<td>Article:</td>
					<td><textarea class="required" name="article" rows="5" cols="50"></textarea></td>
				</tr>
				<tr>
					<td> </td>
					<td><input type="submit" class="button" name="submit" value="Submit"></td>
				</tr>
				<tr>
					<td> </td>
					<td class="smallText">* Highlighted forms designate required fields.</td>
				</tr>
				</table>
			</form>

 

Thanks

 

 

 

 

Link to comment
https://forums.phpfreaks.com/topic/100731-solved-textarea/
Share on other sites

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.