Options

Passworded gallery thumbs

brandofamilybrandofamily Registered Users Posts: 2,013 Major grins
Is there a way to add a class to the featured thumb for a passworded gallery? I'd like to make it so when the thumb of a passworded gallery is hovered the image changes. However, I do not believe there is a unique class for the thumb of a passworded gallery if there is a featured image like there is if it's the standard SM generated "locked gallery" thumb.

I seem to remember that I was given some JS once to add a class to the passworded gallery "passwordPage" when one did not exist.

Comments

  • Options
    brandofamilybrandofamily Registered Users Posts: 2,013 Major grins
    edited July 8, 2012
    I guess I'm looking for something like this
    YE.onAvailable("content", function () {     if (YD.hasClass(this, "galleryPassword") || YD.hasClass(this, "passwordPage"))     {         YD.addClass(document.body, "passwordBody");     } });
    
    But to add a class to the gallery thumb for a passworded gallery if it's a featured image...
  • Options
    brandofamilybrandofamily Registered Users Posts: 2,013 Major grins
    edited July 31, 2012
    No thoughts at all?
    I know I come up with crazy ideas sometimes but I thought someone here would know how to do this with all the brain power on this site.:D
  • Options
    J AllenJ Allen Registered Users Posts: 359 Major grins
    edited August 1, 2012
    No thoughts at all?
    I know I come up with crazy ideas sometimes but I thought someone here would know how to do this with all the brain power on this site.:D


    toni, have you tried something like this yet?

    .category_The_Broadway_Dance_Center_2012 
    .photoLarge:hover:before 
    {content:"Password Protected!!";
    font-size:24px;position:absolute;top:5px;right:5px;
    color:#fff;background-color:red}  
    
    




    you could use an image with type of rule also...something like this, but you'd have to tweak the position and add your dimensions into it:
    .category_The_Broadway_Dance_Center_2012 
    .photoLarge:hover:before 
    {content:url(/photos/647730640_gJCNb-O.png);
    position:absolute} 
    
    



    obviously this can be applied to a whole category via css...I'm sure you could write a script that would look for "locked" galleries and apply this css to all locked galleries.....let me know your thoughts on it.
    -Joe Allen
    My Smugmug Site
  • Options
    brandofamilybrandofamily Registered Users Posts: 2,013 Major grins
    edited August 1, 2012
    J Allen wrote: »
    toni, have you tried something like this yet?

    .category_The_Broadway_Dance_Center_2012 
    .photoLarge:hover:before 
    {content:"Password Protected!!";
    font-size:24px;position:absolute;top:5px;right:5px;
    color:#fff;background-color:red}  
    
    


    you could use an image with type of rule also...something like this, but you'd have to tweak the position and add your dimensions into it:
    .category_The_Broadway_Dance_Center_2012 
    .photoLarge:hover:before 
    {content:url(/photos/647730640_gJCNb-O.png);
    position:absolute} 
    
    

    obviously this can be applied to a whole category via css...I'm sure you could write a script that would look for "locked" galleries and apply this css to all locked galleries.....let me know your thoughts on it.

    Thanks for input. I have no idea how to write script. I'm a cut and paste guy. How exactly will this script work? Do I apply it in the cutom header section?

    I'm actually trying to get this to work for all locked galleries and have a set hover image to show it's locked and requires a password.
  • Options
    J AllenJ Allen Registered Users Posts: 359 Major grins
    edited August 1, 2012
    Thanks for input. I have no idea how to write script. I'm a cut and paste guy. How exactly will this script work? Do I apply it in the cutom header section?

    I'm actually trying to get this to work for all locked galleries and have a set hover image to show it's locked and requires a password.


    For now, just give it a try in your CSS and see what you think...you'll only see the change on this page:

    The_Broadway_Dance_Center_2012


    I'll look into a script for you so it applies on locked galleries...
    -Joe Allen
    My Smugmug Site
  • Options
    brandofamilybrandofamily Registered Users Posts: 2,013 Major grins
    edited August 1, 2012
    J Allen wrote: »
    For now, just give it a try in your CSS and see what you think...you'll only see the change on this page:

    The_Broadway_Dance_Center_2012


    I'll look into a script for you so it applies on locked galleries...

    I tried it. It's pretty close to what I would like. I'd rather have a stock png file but we can work on that. If you can get ti to work for all locked galleries that would be great.
  • Options
    brandofamilybrandofamily Registered Users Posts: 2,013 Major grins
    edited October 8, 2012
    J Allen wrote: »
    For now, just give it a try in your CSS and see what you think...you'll only see the change on this page:

    The_Broadway_Dance_Center_2012


    I'll look into a script for you so it applies on locked galleries...
    J Allen wrote: »
    Any chance you have time to look at this?
Sign In or Register to comment.