Is there a way to change the view counts on folders (not individual pics, that would take WAY too long)?
For example, I am moving a gallery from a different software package that I had been using for years to Gallery3 but want to be able to keep the folder counts and thus the total views if possible. My old gallery has over 10,000,000 views and I would like to be able to update the counts to keep right on going.
How could I do this? The reset_views module is not the solution I am looking for. Thank you.
Posts: 607
I'm not real clear on the view calculations, but I believe they are derived/accumulated from the individual photo views within the album. I'm not sure if a database edit would 'fix' your counts for you.
Hopefully, someone more knowledgeable will chime in.
Posts: 88
even if there was just a counter offset that could be hard-coded in, that would work also.
Posts: 88
I found a way to adjust the individual photo counts using phpmyadmin, but that is not the most elegant solution. is there a way to adjust the total views at the folder level?
Posts: 25961
There is a reset counts module what does it lack?
Dave
____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 88
It only sets the count to 0 for items/folders, right?
What I want to do is to be able to set the count to whatever it was in my old gallery as I am changing software packages.
Posts: 88
dave, i found how to change the counts on the item level. is there a similar way to change the count at the album/folder level?
Posts: 25961
Not at this time. It could be expanded to do so.
How should the UI work while still allowing the user to reset the items in the album?
If you can mock something up of how the UI should work (expand the existing UI with some screen-shots & some text of your new ideas/look) I should be able to make this happen.
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 25961
http://codex.gallery2.org/Gallery3:Modules:reset_counts
updated to version 2 you will be able to reset the album count not with the albums context menu.
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 88
dave, i think all that would be needed would be to change the "reset the items count in this level" to "set the count for this album" and give an input box at the album level.
alternatively, if you MUST set each individual item in order to have the count working, you could have an option to set individual items in this album which pops up a tiny thumbnail and the current count for the item then have an input box for each item in the album so you could just enter an updated value and tab to the next item, enter the updated value, tab to the next, etc. one "done" button at the bottom would update the entire thing.
make sense?
i am not at my home computer so i can't make any screen mockups at this time.
Posts: 25961
What I came up with was:
When browsing an album you can reset the individual items or albums with the context menu (thumbnail menu)
If you want to reset a bunch of items in the album you have to go into the album and use the album menu (above navigation) to reset all the items in that album.
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 88
i understand but maybe we are having issues over the word "reset".
what i want to do is bring an album from my old software into gallery3 and be able to change the view counts to match what was in the old software. its easy enough to get a listing from my old software of the view counts... i want to be able to easily change the counts to match the old software once the photos are brought into gallery3, not reset them to 0.
example...
old software package
photo 1 = 1022 views
photo 2 = 2022 views
photo 3 = 3022 views
total = 6066 views
import photo 1/2/3 into gallery3... all will have 0 views, album will have 0 views.
need quickest and easiest way to update the views in gallery3 to match the old software package. easiest way i have found so far is to go into phpmyadmin and use the "change" command on the items table.
does this make sense?
Posts: 607
you're not going to be able to 'auto' adjust the counts... you'd have to modify each photo, then modify the album count ...
unless you were to write your own import module, you're going to have to do it ^^^ this way
Posts: 25961
If by 'old software' you mean G2 then the counts are migrated/imported using the import module. If not, then you would have to adjust items manually or write some script to do the lookup of the views accordingly.
Looks to me like you have 4 different items (I consider a album a item) with 4 different view counts. So your import script will have to look at the counts for each item and update the count in G3 accordingly.
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 88
I am not looking for an import script. I was merely posting an example. I don't care if photo one, photo two, and photo three all have zero views. I just want the folder itself to have 6066 without having to change every single item inside..
Posts: 607
ah, then you should be good with the updated module - it allows album level count changes now.
Posts: 88
I must have missed it. Can you tell me how?
Posts: 25961
When browsing an album, you can reset the individual items or sub-albums with the context menu (thumbnail menu).
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 88
ok, found it. problem is that after updating the new sub-album, it doesn't update the count on the index page for total views, so it appears that each photo has to be updated individually in order to make this work. ARRRGGGGHHH
Posts: 25961
Sorry to here that. I still fail to see what you want to do. How is the root album info displayed? We have given you the tool to update albums (individuality) and all items in the albums as well. I have even updated the module to do what I was thinking you wanted it to do.
I will leave it up to you to update the DB manually with the data you want.
Oh well.... Can't please all the people all the time.
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 88
No need to be upset, Dave, as I appreciate your help and what you did. The problem arose because once I changed the view count of a gallery at the sub-folder level, the new count did not appear to recurse upward toward the index level. I see now what the issue was... when I wanted to set the total views of a new folder, changing the views of that folder only changed the views on THAT specific page. The total images viewed on the index did not change because it does not count how many times the folder page was viewed. So in order to achieve what I am trying to achieve, at this point it seems that each individual image needs to be adjusted on its own, unless you can think of a way to do it some other way.
My structure (Disney Photo Gallery) is as follows:
INDEX (which contains PARKS) --> AREAS IN PARKS --> ATTRACTION/SHOW --> GALLERY 1 --> PHOTO 1, PHOTO 2, PHOTO 3, ETC.
I thought that if you changed the value of GALLERY 1 at that level, it would reflect on the INDEX and update the total views. It doesn't... PHOTO 1 needs to the adjusted, along with PHOTO 2, PHOTO 3, etc.
Please head over to http://www.themagicinpixels.com/gallery3 to see how my gallery is set up.
Posts: 607
Dave, maybe allow adjusting the root gallery count then?
Posts: 25961
I can't think of another way without redoing to the code.
You are correct. That is the behavior/behaviour: by design.
I could that I guess. should not be that hard to do, remove a if() or 2.
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 88
That would be awesome!
Posts: 25961
Version 3 attached.
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 88
hoping this works perfectly... sounds like it should, but i am getting a validation error max.length. where would i increase the number of allowed digits? my other gallery over 10,000,000 hits. thanks, dave.
Posts: 25961
admin_reset_count.php
find:
->rules("valid_numeric|length[1,5]");change to
->rules("valid_numeric|length[1,9]");Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 88
dave, version 3 changed how many times the index page was viewed, but did not change the total photos view counter. if you go to my gallery (themagicinpixels.com/gallery3)... your newest version changed the top line in the right sidebar ("This page has been viewed 5,270 times") but did not change the total images viewed, located 3 lines down in the sidebar ("Total Views: 761,272 "). THAT is what I was trying to change.
i think i may have come up with a solution, however, in the interim. if i create a password protected/hidden album with one image inside of it, i could set the one image to whatever count i want it to be, and that would affect the total images viewed. because it's hidden from the general public, they would never know. does that make sense?
again, I thank you for your help and patience with this.
Posts: 88
yup, my proposed solution did the trick, with help from your reset_counts modification. if you can think of a more elegant solution, i would love to hear it but for now the task that i was seeking has been accomplished (and a helluva lot easier than changing 6000 images photo counts in cpanel)...
Posts: 25961
I don't know how or where that "located 3 lines down in the sidebar ("Total Views: 761,272 "). " comes from so......
Glad you fond a solution.
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 88
its actually over 11,000,000 now reflecting the solution that i had implemented. look at the top of the sidebar on the upper right.
Posts: 25961
I see it but what module is it?
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 88
"about this album" - i believe.
Posts: 25961
Come on! I want to help ... but that is not very helpful.
So I have to install this (or perhaps some other) module and see if it has this functionality, to see if it displays some "total views..." Then figure out how it gt this total and make some other module function in some way to get this total.
I'm putting out a lot of effort here and I get "i believe'.
I hope you know that, by design, items that are viewed are not cascaded in each direction. Only the item (albums are items) get counted on each view, that is by design.
Off to install the "about this album module' to see how it works.
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team