SitePoint Sponsor

User Tag List

Results 1 to 6 of 6
  1. #1
    SitePoint Guru afridy's Avatar
    Join Date
    Mar 2007
    Posts
    966
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    Strange css alighment problem - pls help

    Hai folks,

    if you pls visit this link ( http://aone.lk/demos/pc_detail.php?pcid=31 ) you can see 4 thumbnail images. it has a horizontal aliment problem.
    how to fix it


  2. #2
    SitePoint Wizard bronze trophy C. Ankerstjerne's Avatar
    Join Date
    Jan 2004
    Location
    The Kingdom of Denmark
    Posts
    2,702
    Mentioned
    7 Post(s)
    Tagged
    0 Thread(s)
    You need to fix the faulty code and set a hight and width for the images first, as this may solve the problem.
    Christian Ankerstjerne
    <p<strong<abbr/HTML/ 4 teh win</>
    <>In Soviet Russia, website codes you!

  3. #3
    SitePoint Guru afridy's Avatar
    Join Date
    Mar 2007
    Posts
    966
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by C. Ankerstjerne View Post
    You need to fix the faulty code and set a hight and width for the images first, as this may solve the problem.
    you felt lazy to open ur firebug and shoot at those thumbs right
    frankly i did not get ur point. if there is a faulty code which i know, i would have fixed it already

  4. #4
    SitePoint Guru afridy's Avatar
    Join Date
    Mar 2007
    Posts
    966
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    hello, it fixed now. tx.

  5. #5
    SitePoint Wizard bronze trophy C. Ankerstjerne's Avatar
    Join Date
    Jan 2004
    Location
    The Kingdom of Denmark
    Posts
    2,702
    Mentioned
    7 Post(s)
    Tagged
    0 Thread(s)
    Well, I don't use Firebug. I am old-fasioned, so I debug by looking at the code

    For starters, go through the list at http://validator.w3.org/check?uri=ht...Inline&group=0

    You should also change your DOCTYPE to strict, rather than transitional. And ideally to HTML 4.01 too, but that's a different story intirely, and XHTML 1.0 Strict will do for all practical purposes.

    Specifically, you have a problem here:
    Code html4strict:
    <ul>
     <li><img src='./pc_photos/thumb_98778_2.jpg'</li>
     <li><img src='./pc_photos/thumb_7027_mypic.jpg'</li>
     <li><img src='./images/no_photo.jpg'</li>
     <li><img src='./images/no_photo.jpg'</li>
    </ul>

    You don't have a closing >. While this is technically valid in HTML, it's invalid XHTML, and in either case you shouldn't rely on it HTML, as no commercial browsers support it.
    Christian Ankerstjerne
    <p<strong<abbr/HTML/ 4 teh win</>
    <>In Soviet Russia, website codes you!

  6. #6
    SitePoint Guru afridy's Avatar
    Join Date
    Mar 2007
    Posts
    966
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by C. Ankerstjerne View Post
    Well, I don't use Firebug. I am old-fasioned, so I debug by looking at the code

    For starters, go through the list at http://validator.w3.org/check?uri=ht...Inline&group=0

    You should also change your DOCTYPE to strict, rather than transitional. And ideally to HTML 4.01 too, but that's a different story intirely, and XHTML 1.0 Strict will do for all practical purposes.

    Specifically, you have a problem here:
    Code html4strict:
    <ul>
     <li><img src='./pc_photos/thumb_98778_2.jpg'</li>
     <li><img src='./pc_photos/thumb_7027_mypic.jpg'</li>
     <li><img src='./images/no_photo.jpg'</li>
     <li><img src='./images/no_photo.jpg'</li>
    </ul>

    You don't have a closing >. While this is technically valid in HTML, it's invalid XHTML, and in either case you shouldn't rely on it HTML, as no commercial browsers support it.
    thanks C. Ankerstjerne for the valuable suggsions.
    how do i missed that >. hmm.. now i fixed it.
    sure ill take a look at doc type think also. coz i never bother about those declarations.
    my dream vewr just put the doc type and all for me when i take a new html or php page.


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
  •