Hi all. I'm working on embedding G2 in Drupal, which works great. I'd like to pop-up a window that will let a user pick a photo from an album.
1. I can create a pop-up window that shows an album. No prob.
2. I'd like to put a link into the template for G2 that will create text into the origial window, much like the img_assist module in Drupal. I haven't done this, but I know how to get this to work, so I'm not worried about it.
3. I'd like the hide the link that writes back to the parent window if the user isn't viewing the page where they pick the image. For instance, my users can use the galleries in other parts of the website where they aren't trying to pick an image. It doens't make any sense for the 'Pick this image' link on these pages.
I thought I'd try to append a name / value pair to the end of the url that opens the popup window. So, that raises two issues that I don't know how to deal with in Gallery.
1. How to test for the existence of the name / value pair and test in the HTML? how does the variable get into smarty so I can do something like {if $my_var == ""} create the link.
2. If I can figure out how to create the link and hide it on the pages where it isn't needed, how can I persist the name value pair so it is available if a user clicks to go to another page, like to page two in the pager? I guess I need to append the name/value pair to every link on the page. Is this possible?
Lot of questions. Thanks for the time. The basic integration between G2 and Drupal is amazing.