ags
ags

Reputation: 7

pdatASP.NET Forms authentication CSS style not working

I've trying to follow this example.

There's one problem im facing is whenever im at the Login.aspx page or being redirected to there, my CSS styles does not show up. Only when i logged in successfully and when it redirect to default.aspx my css style is showing up properly.

Any ways to get my CSS working properly?

Update #1:

I've managed to add the to the webconfig like this:

  <location path="Styles/style.css">
    <system.web>
      <compilation debug="true" targetFramework="4.5"/>
      <httpRuntime targetFramework="4.5"/>
      <authentication mode="Forms">
        <forms name=".ASPXUSERDEMO" loginUrl="Login.aspx" protection="None" timeout="60"/>
      </authentication>
      <authorization>
        <deny users="?"/>
      </authorization>
      <globalization requestEncoding="UTF-8" responseEncoding="UTF-8"/>
    </system.web>
  </location>

But one issue is my pages are not longer secured by forms authentication anymore. How can i fix it? thanks!

Upvotes: 0

Views: 147

Answers (1)

Elshan
Elshan

Reputation: 7693

Try to add css with relevant tags:
Example: add this part after html tag : http://pastebin.com/jxFsG5xc

<style type="text/css">
        h3 {
            font-family:Verdana;
        }
        #Msg {
             font-family:Verdana;
             color:red;
        }
</style>

css tutorials - http://www.w3schools.com/css/

Upvotes: 1

Related Questions