Module: Carousel
floridave
![]()
Joined: 2003-12-22
Posts: 27300 |
![]() |
Inspired from jCarousel lite a new module to add items to the sidebar in a vertical carousel. http://codex.gallery2.org/Gallery3:Modules:carousel Known issues: Dave |
|
mamouneyya
Joined: 2009-11-02
Posts: 337 |
![]() |
Why you chose the sidebar for it? it would be better to be placed horizontally under the resized photo, IMHO. Is it easy to modify that? |
|
mamouneyya
Joined: 2009-11-02
Posts: 337 |
![]() |
I've realized that this module is intended to show random/recent/popular items, rather than make you able to navigate the photos beside the one you are viewing. It will be really nice if you could add navigation functionality as well as an option to show the thumbnails below the resized photo. Thanks! |
|
floridave
![]()
Joined: 2003-12-22
Posts: 27300 |
![]() |
Quote:
Why you chose the sidebar for it? Because that is what I wanted it to do. Quote:
It will be really nice if you could add navigation functionality as well as an option to show the thumbnails below the resized photo. Then it would not be a carousel then would it? Sounds to me like you want some thumb-navigation. Dave _____________________________________________ |
|
floridave
![]()
Joined: 2003-12-22
Posts: 27300 |
![]() |
mamouneyya wrote:
Why you chose the sidebar for it? it would be better to be placed horizontally under the resized photo I have started on creating another module to go under the thumbs and photos. Dave _____________________________________________ |
|
mamouneyya
Joined: 2009-11-02
Posts: 337 |
![]() |
Looks like you disabled it, as I don't see anything similar in the bottom of the items in your site. Anyway, I am thankful you are working on that |
|
floridave
![]()
Joined: 2003-12-22
Posts: 27300 |
![]() |
Updated the module. Use the above attachment. Dave |
|
Lord Beowulf
![]()
Joined: 2010-03-31
Posts: 56 |
![]() |
Hey Dave, Looks pretty good, but I've found at least one minor bug and possibly another. The one is simply that if you re-enter the module configuration page with the "autoscroll" option checked, the fields associated with it aren't enabled. You have to uncheck and recheck to enable them. Again, minor, but anyway... BTW, what's the scale on those numbers for the scroll control? Seems like it's maybe milliseconds? The other behavior that to me looks like a bug, but may be intended is that with autoscroll off, the images all filled the bar in a column as opposed to being a single image that you could rotate through. Was that what was supposed to happen? At any rate, great start and I look forward to seeing this one grow! Thanks, Beo |
|
floridave
![]()
Joined: 2003-12-22
Posts: 27300 |
![]() |
Quote:
You have to uncheck and recheck to enable them. Again, minor, but anyway... yes it takes a bit of code to fix, no time to fix care to take a crack at it? Quote:
Seems like it's maybe milliseconds? I think so. Don't know for sure as I anm using a 4th party bit of code. Quote:
the images all filled the bar in a column.....Was that what was supposed to happen? No it is not intended. It does not function properly. I am thinking of dropping this 4th party JS code as it conflicts with the other carousel module. Dave _____________________________________________ |
|
Lord Beowulf
![]()
Joined: 2010-03-31
Posts: 56 |
![]() |
Hey Dave, If I have the time, my first priority would be to adjust the maximum limits on the scroll timing, but if you're considering changing the underlying code then maybe I should hold off. However, any adjustments I manage to make I'll be sure to feed back to you. Thanks again for all your hard work. Beo |
|
floridave
![]()
Joined: 2003-12-22
Posts: 27300 |
![]() |
Fixed the (u)hiding / (dis)able of the times if the auto scroll is selected. Quote:
The other behavior that to me looks like a bug, but may be intended is that with autoscroll off, the images all filled the bar in a column as opposed to being a single image that you could rotate through. I don't see that behavior now. Dave |
|
Lord Beowulf
![]()
Joined: 2010-03-31
Posts: 56 |
![]() |
Hey Dave, Found a bug in the carousel views. You're using "autostart" for the field in the admin page, but just "auto" on the views, so that field doesn't do anything. The fix is: $auto = module::get_var("carousel", "autostart", "800"); Beo |
|
floridave
![]()
Joined: 2003-12-22
Posts: 27300 |
![]() |
Thanks for keeping me on my toes! Dave |
|
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
Hi Dave, and Now if I modify your module so that it used the minified version of jcarousellite instead of the packed one it starts working. I have posted the modified files here and asked Lord Beowulf to test. Uli --- |
|
floridave
![]()
Joined: 2003-12-22
Posts: 27300 |
![]() |
Thanks, I am following the other thread as well and when Lord Beowulf reports back positively, I will update my module. Dave |
|
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
I know. Sorry for the double post. Oh and thanks for this really cool module :D Uli --- |
|
Lord Beowulf
![]()
Joined: 2010-03-31
Posts: 56 |
![]() |
I know you're following the other thread too, but it looks like it's working great now. Thanks to both of you for some great work. Beo |
|
floridave
![]()
Joined: 2003-12-22
Posts: 27300 |
![]() |
hukoeth & Lord Beowulf, Dave |
|
Armani2
Joined: 2007-05-09
Posts: 263 |
![]() |
Is there any reason why this module in which i have above my photo pages, would cause the site to become very sluggish when the album has many photos? I have one album with 30 or so photos and i see no sluggishness, when i load a photo from a album with 170 photos, it takes a long time for each photo to load? |
|
floridave
![]()
Joined: 2003-12-22
Posts: 27300 |
![]() |
Updated the zip file on the codex page to reflect the recent changes. Dave |
|
MarkRH
Joined: 2007-05-25
Posts: 241 |
![]() |
Was trying out this module as replacement for the ImageBlock module and I noticed that the check boxes for "Show on album & collection pages" and "Show on photo pages" on the settings page always seem to be checked even if I uncheck the photo pages option and save the settings. When I return back to the settings page, they are all checked again instead of reflecting their true state of being unchecked in the database. Behavior wise, the images are not shown on the Photo pages like I set it, it's just the Settings page not reflecting the Saved state. In my case I just show the number of images I want and turn off mouse scrolling; however, the tooltip still says to "use the mouse wheel to scroll" when it doesn't actually do anything. I'll probably just go into the code and change it to show the photo title or something. Anyway, thought you'd like to know. Thanks, Using Gallery 3.0.1 - gallery.markheadrick.com |
|
floridave
![]()
Joined: 2003-12-22
Posts: 27300 |
![]() |
Thanks for the feedback. Does the attached work better? Dave |
|
floridave
![]()
Joined: 2003-12-22
Posts: 27300 |
![]() |
Well? does it work better? Dave |
|
MarkRH
Joined: 2007-05-25
Posts: 241 |
![]() |
I'm sorry.. I've been caught up playing the new EverQuest 2 expansion LOL. This code does seem to work better. The state of the check boxes now seem to reflect their saved value. Oh, since I've configured it not to show anything on the actual photo pages, it seems like Google is indexing things much better. The images google is showing actually points to the page where the photo is. Thanks, Using Gallery 3.0.1 - gallery.markheadrick.com |
|
floridave
![]()
Joined: 2003-12-22
Posts: 27300 |
![]() |
Thanks, Dave |
|
IainY
Joined: 2011-03-28
Posts: 6 |
![]() |
Hello, I have included the Carousel module, but I have a couple of queries about it. When set to autoscroll, the Random Items block works fine, but the images in Recent and Popular Items just show the top x pixels where x seems to be proportional to the width set. Have I missed a setting somewhere? (Very likely!) Secondly the "scroll using mouse" option doesn't seem to work in IE7 (strictly speaking in Compatibility View when using IE8) - all the images are shown, instead of the number set in the options. The full thumbnails are shown in this case however, not just the cropped images. My implementation of Gallery is at http://modelmasterdecals.com/Gallery/index.php. I like the module very much - and so does the Site Owner, which is much more important! - but I would like to be put right about the way I am using it. Thanks, Iain |
|
floridave
![]()
Joined: 2003-12-22
Posts: 27300 |
![]() |
Quote:
When set to autoscroll, the Random Items block works fine, but the images in Recent and Popular Items just show the top x pixels where x seems to be proportional to the width set. Have I missed a setting somewhere? (Very likely!) I think it has to do with the very unusual aspect ratio you are using. I could be wrong but what if you have a taller item as the recent item? Dave |
|
IainY
Joined: 2011-03-28
Posts: 6 |
![]() |
Quote:
I think it has to do with the very unusual aspect ratio you are using. I could be wrong but what if you have a taller item as the recent item? Hi, thanks very much for the feeback. It certainly seems to have something to do with that. I deleted all the "unusual" items and everything was fine. I then put one of them back and now the Recent Items are fine but the Popular and Random Items are not. I haven't tried the scrolling issue again. Do you think that is connected too? The offending images do indeed have an unusual aspect ratio, so if we use more "normal" items throughout maybe everything will be OK. The images I picked were really just the first ones that came to hand. Unfortunately some of those which might be likely to be used in practice also have somewhat unusual aspect ratios. Thanks again, Iain |
|
IainY
Joined: 2011-03-28
Posts: 6 |
![]() |
Hello, Back again! I have deleted the offending images again and added a new Album whose images are an assortment of aspect ratios and sizes; everything looks OK in autoscroll mode. It looks as though there was something special about those earlier images which caused a problem. Maybe we'll just have to manipulate unusual images if it is felt essential to include them at all. Sadly, the IE7 problem hasn't been resolved, but the site owner likes the automatic scrolling anyway! Regards, Iain |
|
floridave
![]()
Joined: 2003-12-22
Posts: 27300 |
![]() |
I have zero interest in supporting IE. Dave |
|
IainY
Joined: 2011-03-28
Posts: 6 |
![]() |
Quote:
How do you expect the the behavior to work? Should the <div> get bigger as the next item shows? or should the height of the <div> be determined by the largest/tallest item in the whole album/gallery? Hello, Thanks for your interest. I suppose in an ideal world the <div> should get bigger as required when the next item shows, but I don't see a problem if it is easier to simply fix the <div> height in advance by reference to the largest/tallest item in the whole gallery (rather than in a given album since multiple albums would normally be used to generate the display). To my mind, the main objective would be to show the whole or as much as possible of the image in every case which the latter approach would achieve. I understand that this change could not be given high priority. Thanks again. Regards, Iain |
|
Rien Post
Joined: 2011-03-29
Posts: 1 |
![]() |
That's exactly what I needed to have a "latest entry" thumbnail in my sidebar (www.rienpost.com). Thanks! |
|
floridave
![]()
Joined: 2003-12-22
Posts: 27300 |
![]() |
Quote:
I don't see a problem if it is easier to simply fix the <div> height in advance by reference to the largest/tallest item in the whole gallery The simple solution is almost always the way to go. #g-carousel-rec { height: 200px; } and adjust the height as needed. Dave _____________________________________________ |
|
Armani2
Joined: 2007-05-09
Posts: 263 |
![]() |
Do you have any Ideas why Nav Carousel Is so sluggish with albums over say 400 photos? I have tried everyting... |
|
IainY
Joined: 2011-03-28
Posts: 6 |
![]() |
Quote:
The simple solution is almost always the way to go. It must be too simple for me, nothing changes! For the avoidance of doubt, I have added the above to http://modelmasterdecals.com/Gallery/modules/carousel/css/carousel.css. Is this right? Thanks very much for your further input. Regards, Iain |
|
floridave
![]()
Joined: 2003-12-22
Posts: 27300 |
![]() |
I don't see any of that css when viewing your site. I bet that the css was used durring devlopment and is not used. Try adding the code to your themes css. Dave |
|
IainY
Joined: 2011-03-28
Posts: 6 |
![]() |
Quote:
Try adding the code to your themes css. I have added the code to the screen.css file in the folder for my chosen theme - still no good I'm afraid. Is there anywhere else I could put it? Is it possible that the problem is theme dependent? I'll try your suggestion in another theme to see if that helps. Maybe the simple solution just isn't going to work. Regards, Iain |
|
Armani2
Joined: 2007-05-09
Posts: 263 |
![]() |
Dave Can you take a look Please? I have asked about this many times?????????? http://www.armaniphotography.com/gallery/index.php/Head-Of-The-Lagoon-20102/IMG_3693 |
|
floridave
![]()
Joined: 2003-12-22
Posts: 27300 |
![]() |
Armani2 wrote:
Do you have any Ideas why Nav Carousel Is so sluggish with albums over say 400 photos? No. Dave _____________________________________________ |
|
MarkRH
Joined: 2007-05-25
Posts: 241 |
![]() |
Noticed the following bug in /carousel/views/carousel_random.html.php: <? foreach ($photos as $photo): if (module::get_var("carousel", "mousewheel") == true) { $ctitle = "Use mouse wheel to scroll!"; } else { $ctitle = title; } ?> $ctitle = title; should be $ctitle = $photo->title; I also happened to discover that IE9 shows all 5 images instead of the 3 or 1 image that I set as being the height of the carousel if IE9 is set to compatibility mode (to see how things looked with older browsers). To get around this, I went into Settings -> Advanced and set the quantity values to 1 and 3 instead of 5. Now both modes of IE9 show the correct amount of images. But.. my case is special as I'm not really using this as a scrollable carousel but something to control where I display a set number of recent and random images on the sidebar. Regards, Using Gallery 3.0.1 - gallery.markheadrick.com |
|
Armani2
Joined: 2007-05-09
Posts: 263 |
![]() |
floridave wrote:
|
|
floridave
![]()
Joined: 2003-12-22
Posts: 27300 |
![]() |
MarkRH wrote:
Cheers! fixed. Dave |
|
jaywa
Joined: 2011-11-16
Posts: 5 |
![]() |
I modified the JCarouselLite JavaScript code to allow for a much better presentation of the photos in case of different aspect ratios (e.g. mixed portrait and landscape orientation). Use at own risk Instructions: |
|
floridave
![]()
Joined: 2003-12-22
Posts: 27300 |
![]() |
Cheers! Dave |
|
petri
![]()
Joined: 2005-12-15
Posts: 253 |
![]() |
Hi Dave, This is a really cool module, it is working well, smooth and clean. About the popular items : on what base is this working ? The number of time the photo page has been viewed ? Thank you in advance for your answer ------ |
|
floridave
![]()
Joined: 2003-12-22
Posts: 27300 |
![]() |
Popular is done with this bit of code in the view file: $photos = ORM::factory("item")->viewable() ->where("type", "!=", "album") ->order_by("view_count", "DESC") ->find_all($quantity); So it looks to see if the user has permission to view the item(s) Dave |
|
petri
![]()
Joined: 2005-12-15
Posts: 253 |
![]() |
It seems to work well, I was just asking that because of the albums... I have so many on the website. Is there no way to list albums out of the carousel ? |
|
floridave
![]()
Joined: 2003-12-22
Posts: 27300 |
![]() |
floridave wrote:
Only items are chosen not albums. If you want albums to show you would have to edit the code to not make that check. If an album gets listed in the popular carousel, then I'm making a mistake in the code as I understand how it works. Dave |
|
petri
![]()
Joined: 2005-12-15
Posts: 253 |
![]() |
So far I only get items...so it seems to work properly Thank you for this module Dave, it is really a nice one |
|
petri
![]()
Joined: 2005-12-15
Posts: 253 |
![]() |
Hello I was wondering if there is any RSS feed for this module, and if yes which one is it ? |
|
floridave
![]()
Joined: 2003-12-22
Posts: 27300 |
![]() |
@more rss feeds: http://gallery.menalto.com/node/95073 Dave |
|