'Nanogallery2 - tags with spaces
I'd like to have tags with spaces in but I can't appear to do it. The gallery is working fine and tags partially work but I cant get spaces into them. My code looks like this (I've also tried it using the tags in the title with a #)
<div id="nanogallery2"
// gallery configuration
data-nanogallery2 = '{
"thumbnailWidth": "auto",
"thumbnailHeight": 200,
"itemsBaseURL": "https://nanogallery2.nanostudio.org/samples/",
"thumbnailLabel": { "display": "false" },
"galleryFilterTags": true,
"galleryFilterTagsMode": "multiple",
"thumbnailHoverEffect2": "imageScaleIn80",
"allowHTMLinData": "true"
}'
>
<!-- content of the gallery -->
<a href="berlin1.jpg" data-ngtags="first way" data-ngthumb="berlin1t.jpg">Berlin 1 #first</a>
<a href="berlin2.jpg" data-ngtags="second way" data-ngthumb="berlin2t.jpg">Berlin 2 #Second</a>
<a href="berlin3.jpg" data-ngtags="third way" data-ngthumb="berlin3t.jpg">Berlin 3 #Third</a>
</div>
Is there a way to add spaces into the tags? Any help would be much appreciated.
Solution 1:[1]
Replace spaces with
inside data-ngtags attributes.
<a href="berlin1.jpg" data-ngtags="first way" data-ngthumb="berlin1t.jpg">Berlin 1 #first</a>
Solution 2:[2]
Open jquery.nanogallery2.js and jquery.nanogallery2.core.js files and
find & replace
item.setTags(tags.split(' '));
to
item.setTags(tags.split(','));
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|---|
Solution 1 | lccv |
Solution 2 | Ayhan Kesicioglu |