Jump to content

How can i make this a text-area instead of a input box?


phpnoob11

Recommended Posts

Hello, im using punbb and want to make a about me profile section, so far i have corrected the database column legth so it can fit in more that just one line (i have edited a existing field yahoo and renamed it so it now says bio next to it...) however if i edit the max lenght so users can see the bio better because its a input box it just one really long line box, but what i want is a text area?

 

Can some one please help me... i have tried just changing the input id= to text area equlas however it doesnt save the input and doesnt do anything...

 

<div class="sf-box text">
<label for="fld<?php echo ++$forum_page['fld_count'] ?>"><span><?php echo $lang_profile['Yahoo'] ?></span></label><br />


<span class="fld-input"><input id="fld<?php echo $forum_page['fld_count'] ?>" type="text" name="form[yahoo]" value="<?php echo(isset($form['yahoo']) ? forum_htmlencode($form['yahoo']) : forum_htmlencode($user['yahoo'])) ?>" size="200" maxlength="450" /></span>

</div> 

is what im trying to change

 

this is what i am trying to change it too

					<div class="sf-box text">
						<label for="fld<?php echo ++$forum_page['fld_count'] ?>"><span><?php echo $lang_profile['Yahoo'] ?></span></label><br />

						<span class="fld-input"><TEXTAREA NAME="fld<?php echo $forum_page['fld_count'] ?>" type="text" name="form[yahoo]" value="<?php echo(isset($form['yahoo']) ? forum_htmlencode($form['yahoo']) : forum_htmlencode($user['yahoo'])) ?>"  ROWS=3 COLS=30 >
</TEXTAREA></span>
			

i tried that the above but that didn't do anything... showed the textarea but it would not save anything...

 

any help please?

 

Thank you :)

 

i can post the whole profile.php if it helps?


I have tried asking on the punbb forums however i think punbb is dead and nobody answer questions anymore... :(

 

Thank you guys.

thanks for your reply when i try

 

<textarea name=""ld<?php echo $forum_page['fld_count'] ?>" type="text" name="form[yahoo]" value="<?php echo(isset($form['yahoo']) ? forum_htmlencode($form['yahoo']) : forum_htmlencode($user['yahoo'])) ?>"
 </textarea>
 
it will show the textarea box but it will be filled with loads of random html and the submit box seems to disappear.... so i think the rest of the goes in the textarea instead...
 
Is that what you mean with putting it the values inside?

The value needs to go between the open and close tag:

<textarea name="myTextArea" cols="30" rows="10">My Value</textarea>

Note: I would highly recommend reviewing the textarea link provided earlier (https://developer.mozilla.org/en-US/docs/Web/HTML/Element/textarea). There are quite a few errors in your textarea code. To help fix the errors, you should run the form through the W3C validator:

http://validator.w3.org/

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.