make sure LF are properly quoted in fullscreen javascript comments
authorGuillaume Cottenceau <gcottenc@gmail.com>
Tue, 13 Oct 2009 11:41:28 +0000 (13:41 +0200)
committerGuillaume Cottenceau <gcottenc@gmail.com>
Tue, 13 Oct 2009 11:41:28 +0000 (13:41 +0200)
bin/booh-backend

index 8d1dc4f00e304a8c0b46a5d9be697592311f00fd..99ae100c04c5fab7cdb011c59783ddc4fe65e812 100644 (file)
@@ -1270,7 +1270,7 @@ def walk_source_dir
 
             #- generate image.html (page with fullscreen images)
             if images.size > 0
-                captions4js = find_captions(xmldir, images).collect { |e| e ? '"' + e.gsub('"', '\"') + '"' : '""' }.join(', ')
+                captions4js = find_captions(xmldir, images).collect { |e| e ? '"' + quote_caption(e, true) + '"' : '""' }.join(', ')
                 thumbnailspage4js = image2thumbnailpage4js.collect { |e| "\"#{e}\"" }.join(', ')
                 for sizeobj in $images_size
                     html = $html_images.collect { |l| l.clone }