Link to home
Start Free TrialLog in
Avatar of AkhilBMin
AkhilBMin

asked on

how can i apply external css rule to a <div runat="server">?

i've a <div> element on a .aspx page with some css rules defined in external .css file. It is working fine, but as soon as i add an attribute runat="server" inside <div>, the external css rule is not called. What could be the problem?
Avatar of sajay_j
sajay_j
Flag of India image

Could you please send the codes within page or URL?
Avatar of AkhilBMin
AkhilBMin

ASKER


<!-- HTML Page Code -->
<div id="divInvalidPwd" runat="server" visible="false">
</div
---------------------------------------------------
/* CSS */
#divInvalidPwd{position: relative; background-color: #FDFAF1; border: solid 1px #DAD9DA; height: 50px; width: 303px;}

Open in new window

Apply the codes as below. Hope it would work..I am not getting any error out of it.
<!---------------------------------------------------*/
/* CSS -->
<style>
#divInvalidPwd{position: relative; background-color: #FDFAF1; border: solid 1px #DAD9DA; height: 50px; width: 303px;}
</style>
 
<!-- HTML Page Code -->
<div id="divInvalidPwd" runat="server" visible="false">
</div>

Open in new window

<div id="divInvalidPwd" runat="server" visible="visible">
</div>
i actually need to put the css rulesets in an external .css file.
ASKER CERTIFIED SOLUTION
Avatar of AkhilBMin
AkhilBMin

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial