Help in changing background without affecting CSS layout

Last post 05-09-2008 3:58 AM by Dialion. 8 replies.

Sort Posts:

  • Help in changing background without affecting CSS layout

    05-08-2008, 11:24 PM
    • Loading...
    • Dialion
    • Joined on 05-02-2008, 2:51 AM
    • Posts 6

    HI, i am trying to change my background without affecting my CSS layout. i used style builder but it overrides my CSS layout.

  • Re: Help in changing background without affecting CSS layout

    05-09-2008, 1:28 AM
    • Loading...
    • vinz
    • Joined on 10-05-2007, 3:47 PM
    • Cebu Philippines
    • Posts 4,230

    Dialion :

    HI, i am trying to change my background without affecting my CSS layout. i used style builder but it overrides my CSS layout.

    Background of what? can you please elaborate more? 

    Don't forget to click "Mark as Answer" on the post that helped you. That way future readers will know which post fixed your problem.


  • Re: Help in changing background without affecting CSS layout

    05-09-2008, 1:41 AM
    • Loading...
    • Dialion
    • Joined on 05-02-2008, 2:51 AM
    • Posts 6

    i would like to show u my image, but i perss the insert/edit image it gives me image url? how do i show my image which are in my computer? background of my aspx.

  • Re: Help in changing background without affecting CSS layout

    05-09-2008, 1:49 AM
    • Loading...
    • vinz
    • Joined on 10-05-2007, 3:47 PM
    • Cebu Philippines
    • Posts 4,230

    Dialion :

    i would like to show u my image, but i perss the insert/edit image it gives me image url? how do i show my image which are in my computer? background of my aspx.

    As far as i know this forum does not allow you to upload image directly.You need to upload your image in the web server using a free image hosting like flicker or something and place your image there then after that map the link of the image..

    Don't forget to click "Mark as Answer" on the post that helped you. That way future readers will know which post fixed your problem.


  • Re: Help in changing background without affecting CSS layout

    05-09-2008, 2:01 AM
    • Loading...
    • Dialion
    • Joined on 05-02-2008, 2:51 AM
    • Posts 6

     

    The above is my website Homepage.aspx, i want to change the white background to my other pictures. but how?

     

     

  • Re: Help in changing background without affecting CSS layout

    05-09-2008, 2:10 AM
    • Loading...
    • vinz
    • Joined on 10-05-2007, 3:47 PM
    • Cebu Philippines
    • Posts 4,230

    You can use THEME Set to change your Layout background dynamically. see links below

    http://msdn.microsoft.com/en-us/library/0yy5hxdk(VS.80).aspx 

    http://msdn.microsoft.com/en-us/library/ykzx33wh.aspx 

    Don't forget to click "Mark as Answer" on the post that helped you. That way future readers will know which post fixed your problem.


  • Re: Help in changing background without affecting CSS layout

    05-09-2008, 2:23 AM
    • Loading...
    • Dialion
    • Joined on 05-02-2008, 2:51 AM
    • Posts 6

    How do i set my theme? and i got a JPG file ready to build the background. i dont understand the links u gave me just now.

  • Re: Help in changing background without affecting CSS layout

    05-09-2008, 2:42 AM
    • Loading...
    • vinz
    • Joined on 10-05-2007, 3:47 PM
    • Cebu Philippines
    • Posts 4,230

    Dialion:

    How do i set my theme?

    There are several steps on how to use Themes in ASPNET so i would suggest you to read on this article

    http://www.odetocode.com/articles/423.aspx

    BTW: When do you want to change the Image Background on the Page? I think you can handle or set the image URL dynamically in code behind part... For example if you wanted to change the Page background on Button Click ... all you need to do is give the page <Body> element an ID and set the runat="server" attribute like

    <body id="pagebody" runat="server"> 

    Then on Button click you can change it like this 

     this.pagebody.Attributes.Add("style", "background-color:Blue;");
            // IF setting the ImageURL then you can have something
     this.pagebody.Attributes.Add("style", "background-image: url(~/Image2.jpg)");

     

    Don't forget to click "Mark as Answer" on the post that helped you. That way future readers will know which post fixed your problem.


  • Re: Help in changing background without affecting CSS layout

    05-09-2008, 3:58 AM
    • Loading...
    • Dialion
    • Joined on 05-02-2008, 2:51 AM
    • Posts 6

    The main problem is after i have inserted my stylesheet, i dont know how to change the background colour..Between, i thought theme can be set through Properties of the aspx?

     Here is my Picture Before and After. the background totally covered away my CSS layout at the top. How do i prevent that?

     Before:

     

    After:

Page 1 of 1 (9 items)