Home
 
 

Twitter

 

get the grid view by default – Sight 1.0.1 Wpshower Theme Part II

This is the follow up to this article. Unfortunately I spent a lot of hours trying to get this to work and didn’t succeed.
When I wrote the other article I thought I had figured out…

So I can get the grid view by default, showing the right icons and all. But the one thing I couldn’t do was to get the rollover-effect on the first load of the page. Since I suppose most people don’t play around with the grid/list toggle… it is not that useful.

 
  1. Leo says:

    I agree! I have been playing around with the grid view. Thanks for the help. I was 1-2 steps away from where you were. Now I am playing with the color background vs the image fading only (ie not showing the titles and such in the yellow background rollover).
    I figured out with Firefox that it works: script.js file lines 93-119
    /*** COlor changes here for rollover ***/

    function grid_update(){
    $(‘#loop’).addClass(‘grid’).removeClass(‘list’);
    $(‘#loop’).find(‘.thumb img’).attr({‘width’: ’190′, ‘height’: ’190′});
    $(‘#loop’).find(‘.post’)
    .mouseenter(function(){
    $(this)
    .css(‘background-color’,'#FFF’)
    .css(‘opacity’,’.5′)
    .css(‘hover’,'filter: alpha(opacity=20)’)
    .find(‘.thumb’).show()
    .css(‘z-index’,'-1′);
    })
    .mouseleave(function(){
    $(this)
    .css(‘background-color’,'#FFF’)
    .css(‘opacity’,’100′)
    .css(‘hover’,'filter: alpha(opacity=100)’)
    .find(‘.thumb’).show()
    .css(‘z-index’,’1′);
    });
    $(‘#loop’).find(‘.post’).click(function(){
    location.href=$(this).find(‘h2 a’).attr(‘href’);
    });
    $.cookie(‘mode’,'grid’);
    }

    But if you try this on a Explorer browser the rollover does not work due to a conflict. I have the alpha bit in there… but I believe I screwed the pooch somewhere. Any ideas?
    Cheers,
    Leo

  2. 12557 says:

    hey guys . i searched hours for help .

    your code doenst work . it is just working after u switched the view once . is that right ?

    i tried it on my website but the there was a error in the script.js .
    are u shure with the lines 45-63 ? I think 45 is right but 63 cuts the code.

    for my one website i just need the gridview working for the 3rd loop . is dont need the switching . can u help me with that ?

  3. alpipego says:

    @12557:
    Could you clarify what you mean with “the 3rd Loop”?

If you have something to say...

 

 
Notify me of followup comments via e-mail.
You can also subscribe without commenting.

 
 
 

Categories

Bookmarks

Get in Touch

Search