December 11, 2009

UniqueText Area

Textarea is an HTML component used kodescript display text or in the form and format text. What is its function? Textarea usually used to display an HTML or javascript code so you can easily be copied to the clipboard. 


Code:
<textarea cols="20" name="textarea4" rows="5" style="-moz-border-radius-bottomright: 15px; -moz-border-radius-topleft: 15px; background-color: #ffdaaf; border: 2px ridge rgb(127, 69, 0); color: black; line-height: 1.5em; text-align: justify;" wrap="off"> 
Your text here is filled
</textarea>


Result:
  • width: width of text area
  • height: height text area
  • background-color: background color of text area
  • text-align: text alignment
  • padding: distance between the writing
  • border: thick thin margins text area
  • solid: color of the margins of text area
 note:
  • border: 1px solid # CA3DD9; «for the setting, 1px is a thick, solid line is the type of
  • -moz-border-radius: 7px; «code for rounded corners (rounded corner) but could only in Mozilla

Textarea with HighLight button/Select All button
This highlights button will make it easier for visitors to copy the whole text or code in the given

Code:
<form>
<input onclick="javascript:this.form.textarea.focus();this.form.textarea.select();" value="Select All" type="button"><br>
<textarea cols="20" name="textarea" rows="5" style="-moz-border-radius-bottomright: 15px; -moz-border-radius-topleft: 15px; background-color: #ffdaaf; border: 2px ridge rgb(127, 69, 0); color: black; line-height: 1.5em; text-align: justify;" wrap="off">
Your text here is filled
</textarea>
</form>

Result:

  • <div align="center" -> show that the position will be key in the middle, so if you want a position on the edge of the left, stay left instead to the words. And if you want to be on the edge of the right, stay right locker with the word.
  • <input onclick="javascript:this.form.txt.focus();this.form.txt.selec()"> -> This code means that when the highlight button is clicked, the entire text contained within it will be highligt (the mark or in block), so you do not alter this paper.
  • Value = "Highlight All" -> Highlight All words are words that will appear in the button, so if you want to change this text please replace with the word you want.

Textarea will automatically block the text when clicked
When clicked will automatically block all text, then copy or press Ctrl-V on the keyboard.

Code:
<textarea cols="20" name="textarea" rows="5" style="-moz-border-radius-bottomright: 15px; -moz-border-radius-topleft: 15px; background-color: #ffdaaf; border: 2px ridge rgb(127, 69, 0); color: black; line-height: 1.5em; text-align: justify;" wrap="off" onclick="this.focus(); this.select();">
Your text here is filled
</textarea>

Result:


note:
You must go to EDIT HTML mode to insert the script, because if you are in Compose mode there will be undesirable characters and the code will be extended to the right.

No comments:

Post a Comment

Let's us sharing

Recent Comment

Grab This Widget