Page 1 of 1

custom form field elements

Posted: Sat Dec 01, 2007 6:09 am
by jasondsouza
Can anyone tell me how to get customized form field elements... like custom Checkbox i.e a blue checkbox o reddish radio button...

Posted: Sat Dec 01, 2007 7:13 am
by Tails5
As far as I know, you cant colour the check boxes themselves, they always show as white with a black tick, unless its a custom button that changes image when you **** it, but then you have to make an **** function.

Posted: Mon Dec 03, 2007 1:06 pm
by jasondsouza
k thanks.. for the info ... will try that out.. but can you elp me out with that...

Posted: Mon Dec 03, 2007 2:57 pm
by Tails5
Well once you've got the images, you need to make it like this:

Code: Select all

void changeColour ()
{
    ****.form1.redcheckbox.    src='redcheckbox-checked.jpg'
}
I'm not exactly sure though, I'm not that good at javascript.

Posted: Mon Dec 03, 2007 10:15 pm
by Flipper3
Just like Tails5 said, you need to use images and Javascript. However, this is greatly discouraged by all web designers, etc and is very difficult to do when submitting forms and finally it doesn't support all users.

Posted: Tue Dec 04, 2007 11:27 am
by jasondsouza
do you have an article regarding such things... like why is it discouaged... because i saw it on delivi's site.. one of smoky's members...

Posted: Tue Dec 04, 2007 8:09 pm
by Lixas
maybe there was flash elements ?!

新加的空白文章1

Posted: Tue Nov 17, 2009 7:41 pm
by nopq478
这是新加的空白文章1,可以在UBB可视化编辑器中,添加和修改文章内容。

Form colors

Posted: Wed Nov 25, 2009 12:48 am
by Gebbo
jasondsouza wrote:Can anyone tell me how to get customized form field elements... like custom Checkbox i.e a blue checkbox o reddish radio button...
Have you tried CSS ? that might be able to do it..

Posted: Tue Jan 04, 2011 7:12 pm
by -_lonely_-_potato_-
jasondsouza wrote:Can anyone tell me how to get customized form field elements... like custom Checkbox i.e a blue checkbox o reddish radio button...
Hi, bro. I only know a thing or two about <input type="text"> (text fields - form)

Simply add this to your style sheet or css source:
input[type="text"].rounded_inputs {
font-family: Verdana;
border: 1px solid #B3B3B3;
border-bottom-left-radius: 6px 6px;
border-bottom-right-radius: 6px 6px;
border-top-left-radius: 6px 6px;
border-top-right-radius: 6px 6px;
color: #999;
height: 19px;
padding: 2px;
}
And for displaying the form, enter this html code:
input type="text" name="category2" size="25" class="rounded_inputs" value="Your Name" onBlur="if (this.value == '') {this.value = 'Your Name';}" onFocus="if (this.value == 'Your Name') {this.value = '';}"></td>
</tr>
<tr>
<td><input type="text" name="category3" size="25" id="GRCategory3" class="rounded_inputs" value="Your E-mail" onBlur="if (this.value == '') {this.value = 'Your E-mail';}" onFocus="if (this.value == 'Your E-mail') {this.value = '';}"></td>
Hope this helps.

Your buddy, THE lonely Potato.