IT Community - Software Programming, Web Development and Technical Support

Appearance of Form Fields.

This is a discussion on Appearance of Form Fields. within the HTML, CSS and Javascript Coding Techniques forums, part of the Web Development category; Hi all.... Can anyone discuss briefly about the Appearance of Form Fields. How can I control the width of a ...


Go Back   IT Community - Software Programming, Web Development and Technical Support > Web Development > HTML, CSS and Javascript Coding Techniques

Register FAQ Members List Calendar Mark Forums Read
  #1 (permalink)  
Old 09-29-2007, 12:21 AM
itbarota itbarota is offline
D-Web Architect
 
Join Date: Jun 2007
Posts: 547
itbarota is on a distinguished road
Default Appearance of Form Fields.

Hi all....

Can anyone discuss briefly about the Appearance of Form Fields.

How can I control the width of a select box?
<select name="province" size="1" style="width: 50mm">
...
</select>

Thanks & Regards
itbarota...

Last edited by itbarota : 09-29-2007 at 12:23 AM.
Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 09-29-2007, 12:29 AM
itbarota itbarota is offline
D-Web Architect
 
Join Date: Jun 2007
Posts: 547
itbarota is on a distinguished road
Default Re: Appearance of Form Fields.

Hi all...

How can you format numbers as right-aligned in a text field?

Thanks & Regards
itbarota...
Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 09-29-2007, 12:34 AM
Pvinothkumar Pvinothkumar is offline
D-Web Analyst
 
Join Date: Sep 2007
Posts: 237
Pvinothkumar is on a distinguished road
Default How can you format numbers as right-aligned in a text field?

Hi....


<Form>
<input type="text" name="textfieldName1" size="5" value="1" style="text-align:right">
</FORM>

Thanks.....
Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 09-29-2007, 12:43 AM
itbarota itbarota is offline
D-Web Architect
 
Join Date: Jun 2007
Posts: 547
itbarota is on a distinguished road
Default Re: Appearance of Form Fields.

Hi all....

How do you change the color of the text in a text box after an onChange?

Thanks and Regards
itbarota....
Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 09-29-2007, 12:46 AM
Pvinothkumar Pvinothkumar is offline
D-Web Analyst
 
Join Date: Sep 2007
Posts: 237
Pvinothkumar is on a distinguished road
Default How do you change the color of the text in a text box after an onChange?

Hi.....

<form>
<input type="text" onChange="this.style.color='red'">
</form>

Thanks....
Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #6 (permalink)  
Old 09-29-2007, 12:57 AM
Pvinothkumar Pvinothkumar is offline
D-Web Analyst
 
Join Date: Sep 2007
Posts: 237
Pvinothkumar is on a distinguished road
Default How do you change the color of the text in a text box after an onChange?

Hi.....

OnChange=neg( this )
function neg( fld )
{
fld.style.color = ( parseFloat(fld.value) < 0 ) ? 'white' : 'black';
fld.style.backgroundColor = ( parseFloat(fld.value) < 0 ) ? 'red' : 'white';
}

Thanks....
Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #7 (permalink)  
Old 10-05-2007, 08:36 AM
itbarota itbarota is offline
D-Web Architect
 
Join Date: Jun 2007
Posts: 547
itbarota is on a distinguished road
Default Re: Appearance of Form Fields.

Hi all....

How do I use my own graphic button to reset all the text fields in a form?

Thanks & Regards....
Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #8 (permalink)  
Old 10-05-2007, 08:38 AM
Pvinothkumar Pvinothkumar is offline
D-Web Analyst
 
Join Date: Sep 2007
Posts: 237
Pvinothkumar is on a distinguished road
Default How do I use my own graphic button to reset all the text fields in a form?

Hi.....

<form name="formName">
<input type="text">
</form>

<a href="#" onClick="this.href='javascript:document.formName.r eset()'"><img src="button.gif" width="16" height="16" border="0"></a>

Thanks......
Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #9 (permalink)  
Old 10-05-2007, 08:42 AM
itbarota itbarota is offline
D-Web Architect
 
Join Date: Jun 2007
Posts: 547
itbarota is on a distinguished road
Default Re: Appearance of Form Fields.

Hi all....

How can I use an image object to clear my form instead of using the normal reset button?

Thanks & Regards....
Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #10 (permalink)  
Old 10-05-2007, 08:46 AM
Pvinothkumar Pvinothkumar is offline
D-Web Analyst
 
Join Date: Sep 2007
Posts: 237
Pvinothkumar is on a distinguished road
Default Can I use an image object to clear my form instead of using the normal reset button?

Hi all...

<form name="myForm">
<a href="#" onClick="document.myForm.reset()"><img src="reset.gif"></a>
</form>

Thanks...
Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #11 (permalink)  
Old 10-05-2007, 08:49 AM
itbarota itbarota is offline
D-Web Architect
 
Join Date: Jun 2007
Posts: 547
itbarota is on a distinguished road
Default Re: Appearance of Form Fields.

Hi all.....

How can I create an option in a select statement with a particular style?

Thanks & Regards.....
Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #12 (permalink)  
Old 10-05-2007, 08:52 AM
Pvinothkumar Pvinothkumar is offline
D-Web Analyst
 
Join Date: Sep 2007
Posts: 237
Pvinothkumar is on a distinguished road
Default How can I create an option in a select statement with a particular style?

Hi....

var opt = new Option('text of option','value of option');
opt.style.color = 'red';
myselect.options[1] = opt;

myselect.style.fontFamily = 'Courier';

Thanks.....
Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #13 (permalink)  
Old 10-05-2007, 08:55 AM
itbarota itbarota is offline
D-Web Architect
 
Join Date: Jun 2007
Posts: 547
itbarota is on a distinguished road
Default Re: Appearance of Form Fields.

Hi all......

How can you format numbers as right-aligned in a text field?

Thanks & Regards
itbarota....
Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #14 (permalink)  
Old 10-05-2007, 08:59 AM
Pvinothkumar Pvinothkumar is offline
D-Web Analyst
 
Join Date: Sep 2007
Posts: 237
Pvinothkumar is on a distinguished road
Default How can you format numbers as right-aligned in a text field?

Hi.....

<form>
<input type="text" dir="rtl" />
</form>

Thanks.....
Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How can I disable form fields? GDevakii HTML, CSS and Javascript Coding Techniques 7 08-04-2008 07:04 PM
popup date selector return dates to different form fields. itbarota HTML, CSS and Javascript Coding Techniques 3 01-08-2008 10:19 PM
How can I reset the value of form fields if the page is revisted? itbarota HTML, CSS and Javascript Coding Techniques 2 12-05-2007 04:48 AM
How do I use my own graphic button to reset all the text fields in a form? Pvinothkumar HTML, CSS and Javascript Coding Techniques 1 11-02-2007 12:02 AM
How can I pass a hidden value to a form and submit that form when a text link is clic itbarota HTML, CSS and Javascript Coding Techniques 1 10-17-2007 08:07 AM


All times are GMT -7. The time now is 01:06 PM.


Copyright ©2004 - 2007, DiscussWeb. All Rights Reserved.

SEO by vBSEO 3.0.0