FAQ

Frequent Asked Questions

What does BINS means ?

BINS Is Not Swigs. BINS is a fork of Swigs, which is not maintained anymore.

Does BINS run on Windows ?

I've never tried, but I don't think. It's written in Perl, which is portable, but it uses some *nix specific commands. Though it should not be so difficult to port, or maybe it can run with cygwin ?

When I visualize a big image, it don't fit in my window, I must scroll to see it, should I buy a bigger monitor ?

Yes. Or else, you can click on the big image. By default, browsers like firefox will display it automatically re-sized to your window.

How can I get bins to automatically rotate destination images ?

If your camera has a accelerometer to know which way is up, it will be done automatically. If not, you have to set manually the orientation of the images on your camera before downloading them on you computer. You can also use bins-edit-gui to set the orientation of the image. If you don't want to use the GUI, this can be done directly in the XML image description file. Put (or set if it is already there) the following tag in the <exif> section:

	
	<tag name="Orientation" priority="1">
	   left_bot
        </tag>
	
      

Adjust the left_bot to the orientation of your image (can be right_top, left_bot or bot_right).

Is it possible to give my own order number for each image ?

This can be done with two different ways.

  • You can prefix the name of images and directories with a number. You can use the add_num_prefix tool to help you. You have the possibility to choose to reverse sort with the reverseOrder option or the -r command line switch.

  • You can put an optional file album.list in your albums (a slibling file to album.xml) that lists the files in the order you want them displayed. If album.list doesn't exist in a directory the sorting by image name is done as usual.

Does BINS recreate all the albums even if I add or modify just a sub-album ?

For each picture, if it doesn't exists in destination album, it is processed. If it exists and the date of the source is greater than the date of the destination, it is also processed. If the destination is more recent, it is left unchanged. All the HTML is regenerated when bins is run.

Can I put some HTML in description fields ?

Yes, take a look at the -m option of bins_edit, see the man page.

I tried to change the color style (or e-mail, home page, other template customisation...) but I can't see any change on the generated album, is this a bug ?

Some customisation parameters are not implemented in all templates. For example, color style is not implemented in joi templates. Instead, it uses the more modern alternate stylesheets mechanism, with the customStyleSheet parameters, which is not supported by the swigs template.

How can I tell BINS to skip resizing the image (just use the default image) ?

Add this in the album.xml:

      
       <sizes>
          <size name="Full Size" shortname="Full" height="100%" width="100%">
       </sizes>
	
      

Its goes under the <bins> stanza.

Having two separate trees (source and HTML) is not efficient for my disk space usage, can I use only one tree ?

No, but you can use the linkInsteadOfCopy parameter to avoid any image file duplicate. Also, look at the linkRelative parameter. All is in the man page.

Having one description file per image is to complex to maintain, can I put all description fields for all images in just one file ?

Yes, try the bins_addtext tool.

Why special characters (like those with accents) are not correctly rendered ?

Have you copied the .htaccess in the root of your published album ? See Encoding here.

I've generated an album, but I can't find the search engine, where is it ?

For now, the search engine is only available with the swigs templates. Note that the search link will only show up with a browser supporting javascript.

The "Loading Data" screen took a bit too long to go to the search page, is this normal ?

It depends of the size of your album. You can enable compression on your web server to reduce this time. See Compression here.

Can I have several versions of an album in different languages without duplicating the pictures ?

Multi-languages albums are not handled by BINS, but you can do this manually with the mod_rewrite Apache module.

Say you have four albums trees corresponding to the same album in different languages, in four different directories named with the language code:

	/var/www/album/da/...
	/var/www/album/de/...
	/var/www/album/en/...
	/var/www/album/fr/...
      

To have only one copy of each picture, remove them from all trees except one (say en):

	find /var/www/album/{da,de,fr} \( -iname \*.JPG -o -iname \*.jpg -o \
	   -iname \*.gif -o -iname \*.png -o -iname \*.avi -o -iname \*.mpg \) \
	   -exec rm -f {} \;
      

And add a RewriteRule to your Apache configuration file to redirect all request for an image to the en tree :

	RewriteEngine on
	RewriteRule   ^/album/[^e][^n]/(.*\.(jpg|gif|png|avi|mpg))$ \
	              /album/en/$1 [NC]
      

I've put some image names in the excludeFiles parameter, but it doesn't seems to works. Can you explain how to use this stuff ?

This should be set to one regexp, so, for example, to ignore two images, the correct parameter should looks like :

      
        <parameter name="excludeFiles">
            dscn20(89|90)
        </parameter>
	
      

Why bins fails with "Assertion flags == 0 failed: file "Storable.xs", line 2336 at /usr/local/bin/bins line 4213." ?

See this post. You can find more details here.

What is the syntax used in templates ?

man HTML::Template