This is a discussion on "Using CSS Rule together with CSS Class in server side controls" within the Web Page Design section. This forum, and the thread "Using CSS Rule together with CSS Class in server side controls are both part of the Design Your Website category.
|
|
|
|
|
![]() |
||
Using CSS Rule together with CSS Class in server side controls
|
||
| Notices |
![]() |
|
|
LinkBack | Thread Tools |
|
|||
|
Using CSS Rule together with CSS Class in server side controls
Hi,
I design my web site in Dreamweaver and then use Web Developer 2005 Express for the dynamic stuff. I then amalgamate all the work I have done in Dreamweaver into 2005 Express. However with the new server side controls I do not know how to add a CSS class together with a CSS rule. In the normal client side control in Dreamweaver I have - <input name="txtPassword" type="password" class="Input" id="SpacerBottom" /> In the server side controls the ID keyword is used now - <asp:TextBox ID="txtPassword" runat="server" Style="z-index: 107" CssClass="Input" ></asp:TextBox> I have tried to use the name="txtPassword", but it ignores this. I would really like to know how I can use a class and an id selector with the new server side controls and would really appreciate some help on this. Many thanks, Polly Anna |
|
|
|
||||
|
Re: Using CSS Rule together with CSS Class in server side controls
Wouldn't it be better to just do a formname input {} in a style sheet? Maybe I am just missing the point entirely.
Last Blog Entry: Apps every Mac based web dev should consider (Jul 10th, 2008)
|
|
|||
|
Re: Using CSS Rule together with CSS Class in server side controls
Hi moojoo, not sure how I can use the solution you mention. Could you point me in the right direction as to what this actually does?
Many thanks, Polly Anna |
|
||||
|
Re: Using CSS Rule together with CSS Class in server side controls
Well, say you had a form named foo. What you could do is declare styles for the elements only contained within forms with the id of #foo.
#foo input { padding:6px; width:125px; border:solid #CCCCCC; border-width:1px; } #foo textarea { border:solid #CCCCCC; border-width:1px; } #foo input.mybutton { width:75px; } etc. http://www.sitepoint.com/article/style-web-forms-css
Last Blog Entry: Apps every Mac based web dev should consider (Jul 10th, 2008)
Last edited by moojoo; Aug 3rd, 2006 at 14:17. |
|
|||
|
Re: Using CSS Rule together with CSS Class in server side controls
Thank you - and yes it is obvious, but I just couldn't see it.
Many thanks, Polly Anna |
|
||||
|
Re: Using CSS Rule together with CSS Class in server side controls
This is a good article on styling web forms with CSS as well if you need it.
http://www.sitepoint.com/article/style-web-forms-css
Last Blog Entry: Apps every Mac based web dev should consider (Jul 10th, 2008)
|
![]() |
| Tags |
| using, css, rule, together, class, server, side, controls |
| Thread Tools | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Java server side technologies | asim | Webforumz Cafe | 0 | Jun 20th, 2007 07:47 |
| Server-side form validation strategy.... | ginzotech | ASP.NET Forum | 0 | Jun 1st, 2007 15:25 |
| Trouble with Server Side Includes | BGarner | Classic ASP | 3 | Jan 20th, 2007 17:16 |
| Server side executables | Donny Bahama | PHP Forum | 4 | Dec 30th, 2006 17:59 |
| Client-Side VS Server Side Scripting | redev2006 | JavaScript Forum | 1 | Jul 30th, 2005 19:30 |