Hi all,
I'm using monoslideshow, a $20 flash-based gallery program, to do a front-page gallery on a site. (Not an external site, sorry, so I can't show it.) I tried a few of the other gallery modules but I already knew monoslideshow and I like the look of it. Getting it integrated with Drupal wasn't too hard but there were a few tricks to learn along the way, so I'm documenting them here.
Step 1: preparing Drupal
You'll need to install SWF Tools and you'll need to turn on the PHP Filter module if you're on 6.x and not already using it.
Step 2: create a node and tweak the CSS
There's more than one way to do static content at the top of a list of node posts, but this is the way I did it. What I did was post a story and make it "sticky at the top of a list" and "promoted to front page", then I tweaked the CSS to remove the normal node title so that all that was visible in the node was the flash gallery itself. You could certainly modify your theme instead or do it any of a dozen other ways, but this was easy and worked well for my site.
One you create your node, you just need to note the number of the node. Then, in your CSS, do something like this to hide the title:
#node-7 h2 {
display: none;
}
Depending on your theme and config you might need to tweak this or hide additional elements.
Step 3: Install monoslideshow and get it working
Monoslideshow needs three files to work, monoslideshow.swf, monoslideshow.js, and monoslideshow.xml. I put monoslideshow.swf and monoslideshow.js in a monoslideshow directory under /sites/default/files, and I put monoslideshow.xml under sites/default/files directly. This is because SWF Tools looks in the files directory by default. If you put the files somewhere else you'll need to tweak SWF Tools. For my gallery I put the images into a directory under files as well, and you can get more complex in the monoslideshow config with additional gallery directories, but I just used one. So, my final setup looks like:
/sites/default/monoslideshow/monoslideshow.swf
/sites/default/monoslideshow/monoslideshow.js
/sites/default/monoslideshow.xml
/sites/default/gallery/picture1.jpg ...
Monoslideshow comes with a default index.html file that runs standalone outside of Drupal. Because monoslideshow has a lot of options, I suggest you get your gallery up and running just the way you want it using that before you try to put it into your Drupal site.
Step 4: Create the node content
If everything else worked, this is pretty easy, although working out the right variables was the hardest part of this since SWF Tools is a bit different than how monoslideshow works normally.
Your node content should be set as PHP and look like this.
<?php
print swf('sites/default/files/monoslideshow/monoslideshow.swf', array('params' => array('height' => '200', 'width' => '680'), 'flashvars' => array('showLogo' => 'false')));
?>
Obviously, tweak the height and width to your liking. showLogo disables the monoslideshow product logo when the slideshow loads.
That's it for the config. As I said, monoslideshow is very customizable and has a nice clean look, which is why I like it. YMMV. :)
Comments
intergrating monoslideshow
@tdailey
I am currently working on getting mss ready for drupal 6.
Just need to work out how to get the flickr feed able to be included.
Some of the functionality added:
* dependencies = image, image_gallery
* image import for lots of images (optional)
* relies on a parent gallery to hold the albums (I use this for weddings, this way they are separate from each other)
* added a thumbnail selector in the edit image gallery page, this adds the thumbnail to the album
* dynamically creates the xml file, so images can easily be added or removed or changed
I think there was a couple more, but you get the idea
great Stonjie! I'm willing
great Stonjie!
I'm willing to test when you have something ready to look at.
Hi tdailey, I'm quiet new to
Hi tdailey,
I'm quiet new to Drupal, I came from a Joomla! world and there is a lot of differences between them. First I'd like to thank you for sharing your experience with the community, I don't understand something though; in step3, which CSS file should I edit to remove the normal node, I can't find a CSS file containing the node I created!
Any help?
Thanks in advance :-)
******************************************************************
TOTORO is my neighbor! Drupal is TOTORO's little brother and my friend.
Welcome drutoro, I'm a big
Welcome drutoro, I'm a big Totoro fan. :)
You need to edit the theme's css file, which is in:
/themes/[themename]/style.css
You can put the section anywhere, really, although it could be overridden if there is a later style declaration that contradicts it.
Worket perfectly
It worked!
Actually I didn't understand that I have to ADD something to the CSS file :p
Really thanks for the help tdailey :-) .. And yeah! good to meet a big fan of my hero TOTORO ;-)
******************************************************************
TOTORO is my neighbor! Drupal is TOTORO's little brother and my friend.