ASPX templates
Version 4.x > ASPX templates > Media gallery fade and active View modes: 
User avatar
Member
Member
mailtohemalatha.rajaram-gmail - 4/22/2010 11:50:30 AM
   
Media gallery fade and active
Hi,

I have two media galleries in a page, when I click onthe first gallery n accessing those files ,i want the other gallery to become faded or invisible. how to do that? any suggestion will do....thank you
Hema

User avatar
Kentico Developer
Kentico Developer
kentico_ondrejv - 4/24/2010 2:57:55 PM
   
RE:Media gallery fade and active
Hello,

I suggested you solution for your goal via an e-mail. Nevertheless I came up with slightly better solution. Please try this one:

1) You will still need to implement following workaround to be able to use multiple Media galleries on the page: http://devnet.kentico.com/Knowledge-Base/Web-parts---Controls/How-to-have-two-Media-Gallery-webparts-within-one-.aspx

2) And finally, there is nothing easier than add this expression to 'Visibility' property of the Media gallery webpart (you can click the gray triangle icon to enable macro editor):

{%fileid2 == ""%}

It enforces hiding whole Media Gallery 1 webpart when the file detail from Media gallery 2 is shown. Put simply, when query string fileid2 is set within the URL it returns false which hides whole Media Gallery 1.

Likewise, please add another query string macro to Media Gallery 2 webpart, in 'Visibility' property:

{%fileid == ""%}

Should you need more about macros, please see it here: http://devnet.kentico.com/docs/devguide/appendix_a___macro_expressions.htm

Best regards
Ondrej Vasil