CSS problem

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • mynkow
    New Member
    • Jul 2007
    • 37

    CSS problem

    Hi,

    I have ASP.NET 2.0 website. I have 3 files. style.css, master.page and page1.aspx. I load the css from the master.page. If my URL is like this:

    This website is for sale! mywebsite.com is your first and best source for all of the information you’re looking for. From general topics to more of what you would expect to find here, mywebsite.com has it all. We hope you find what you are searching for!


    the CSS is loaded and everything is OK. But when I try this URL everything becomes a mess because the CSS could not be found.

    This website is for sale! mywebsite.com is your first and best source for all of the information you’re looking for. From general topics to more of what you would expect to find here, mywebsite.com has it all. We hope you find what you are searching for!

    note: ( double ' / ' )

    Can some1 tell me where is the problem and how can I avoid this without parsing the URL and replacing ' // ' with ' / ' because this is not a good solution.
  • Markus
    Recognized Expert Expert
    • Jun 2007
    • 6092

    #2
    Originally posted by mynkow
    Hi,

    I have ASP.NET 2.0 website. I have 3 files. style.css, master.page and page1.aspx. I load the css from the master.page. If my URL is like this:

    This website is for sale! mywebsite.com is your first and best source for all of the information you’re looking for. From general topics to more of what you would expect to find here, mywebsite.com has it all. We hope you find what you are searching for!


    the CSS is loaded and everything is OK. But when I try this URL everything becomes a mess because the CSS could not be found.

    This website is for sale! mywebsite.com is your first and best source for all of the information you’re looking for. From general topics to more of what you would expect to find here, mywebsite.com has it all. We hope you find what you are searching for!

    note: ( double ' / ' )

    Can some1 tell me where is the problem and how can I avoid this without parsing the URL and replacing ' // ' with ' / ' because this is not a good solution.
    Why would you have double forward slashes in the first place?

    Comment

    • mynkow
      New Member
      • Jul 2007
      • 37

      #3
      The question is not why I enter double ' // '. I have to solve this. If I try to do this with some page of microsoft website it is OK.

      Comment

      • drhowarddrfine
        Recognized Expert Expert
        • Sep 2006
        • 7434

        #4
        Using the double slash will never work because that's the path name to the file, just like on your computer. So forget about it. It won't work no matter what you do. That's not how the protocol works.

        Comment

        Working...