SitePoint Sponsor

User Tag List

Results 1 to 5 of 5
  1. #1
    SitePoint Enthusiast
    Join Date
    May 2008
    Posts
    50
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Trouble accessing background images

    I have recently signed up with HostGator to host my first website.

    I have a limited number of documents (3 x HTML, 1 x CSS and 3 x background images) that I have transferred to HostGator via Filezilla FTP. When viewed in IE or Firefox from my own PC, these files look good (considering it's a first attempt) however once transferred to my server I cannot see the background images?

    According to the instructions from HostGator, all publicly accessible files should be placed in the public_html directory - which they are - however my background images are in a sub directory called backgrounds. The CSS file refers to these as backgrounds/filename.jpg etc but these are not being picked up on the internet.

    Is there an obvious reason for this? What am I doing wrong?

    Thanks

  2. #2
    SitePoint Wizard bronze trophy Tailslide's Avatar
    Join Date
    Feb 2006
    Location
    Bedford, UK
    Posts
    1,687
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    There's two usual reasons for problems - firstly, paths not being correct. Just double-check that they really are in a folder called backgrounds and that they are referenced correctly from wherever the stylesheets are kept.

    Secondly - check that you haven't given them a name that might trigger the adblocks such as "banner" or "ad".

    Best way for us to tell you is if you post a link.
    Little Blue Plane Web Design
    Blood, Sweat & Rust - A Land Rover restoration project

  3. #3
    SitePoint Enthusiast
    Join Date
    May 2008
    Posts
    50
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Tailslide

    My 2 (not 3 as I originally stated) background images are referred to with the css file as:

    h1 {
    color: #ffffff;
    background: #85792f url(backgrounds/header-back.jpg) repeat-y right;
    font-size: 220%;
    padding-top: 31px;
    padding-bottom: 31px;
    padding-left: 5px;
    margin: 0;
    }

    and

    #navigation {
    background: #85792f url(backgrounds/navigation-back.jpg) no-repeat; width: 160px;
    height: 1600px;
    padding-top: 10px;
    line-height: 150%;
    border-right: 2px solid #123456;
    }

    They do appear to me to be referenced correctly, but perhaps you can confirm.

    I'm not sure if you're referring to a link to the website, but if so it's

    www dot golfing-around dot com (apologies for the naming, I've only made 9 posts and needed 10 as I may have been a spammer!)

    Thanks for your help.

  4. #4
    SitePoint Enthusiast
    Join Date
    May 2008
    Posts
    50
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Reading through another members posts, I stumbled across an answer that suggested that the sub-directory folder may be case sensitive on the server, but not on my PC. I made the change and voila they appeared (albeit slowly).

    I'll need to look into why they were so slow (3-5 seconds), but any advice is appreciated. They are 81kb and 479kb respectively. Is this far too big? Can anyone point me in the right direction for optimizing picture size / quality etc.

  5. #5
    SitePoint Wizard bronze trophy Tailslide's Avatar
    Join Date
    Feb 2006
    Location
    Bedford, UK
    Posts
    1,687
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    If you mean the 2 golfing images then I can see them with no problem (FF, IE7 and IE6)
    Little Blue Plane Web Design
    Blood, Sweat & Rust - A Land Rover restoration project


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •