Grow your CSS skills. Land your dream job.

Loading content with Ajax messes things up

  • # December 25, 2009 at 9:18 am

    Hello everybody,

    I have an issue with the portfolio part of the website I am building. You can check it out here :

    http://vanillaandcaramel.com/portfolio

    So basically all my content is in a div with an id of "#slider". When you click on a thumbnail, I remove the current content from this div and load the content of the #slider div that’s in another html page. Two problems though :

    – First, as you can see there is a weird shift of the whole div to the right, outside the wrapper. This state is fully functional though, I am using fancybox to display additional images of the artwork (when you click on "view more")

    – When I refresh the page, the shift to the right disappears, but now fancybox doesn’t work anymore? I must say that I am new to jQuery and Ajax, so I find it hard to debug by myself.

    – Third thing, I was wondering how I could, when clicking on a specific thumbnail, load the page scrolled down to the related project. I tried using page jumps (<a name="blabla"> etc) which work when js is disabled, but not when it’s not…

    Thanks for your help,
    Krimo.

Viewing 1 post (of 1 total)

You must be logged in to reply to this topic.

*May or may not contain any actual "CSS" or "Tricks".