PhotoPost Community

PhotoPost Community (http://www.photopost.com/forum/)
-   Photopost Pro How Do I...? (http://www.photopost.com/forum/photopost-pro-how-do-i/)
-   -   recent images link not working if sort is anything but last 7 days (http://www.photopost.com/forum/photopost-pro-how-do-i/137275-recent-images-link-not-working-if-sort-anything-but-last-7-days.html)

DannyITR July 16th, 2008 08:56 AM

recent images link not working if sort is anything but last 7 days
 
I have a little box on my homepage to sort images:

» Recent Photos
Of last 24 hours
Of last 3 days
Of last 7 days
Of last 30 days
Of last 180 days
Of last 365 days
Of All Time

The link that was given to me on this forum was:

http://www.mysite.com/gallery/showga...mit=last7&cat=

Which would display photos form the last 7 days. If I change 7 for anything else it doesn't seem to work. Why not?

Chuck S July 16th, 2008 09:38 AM

The links within our program are working fine here as shown

PhotoPost PHP Photo Sharing Gallery with vBulletin Forum Integration

If your hacking your code no doubt this is an issue with whatever hack not being correctly coded as in our software we only have those 4 conditionals coded so anything else you would need to code in those limits in the php file to know what to do. ;)

DannyITR July 16th, 2008 02:45 PM

Quote:

Originally Posted by Chuck S (Post 1228363)
The links within our program are working fine here as shown

PhotoPost PHP Photo Sharing Gallery with vBulletin Forum Integration

If your hacking your code no doubt this is an issue with whatever hack not being correctly coded as in our software we only have those 4 conditionals coded so anything else you would need to code in those limits in the php file to know what to do. ;)

Thanks Chuck. I found the code in showgallery.php (line 269) that looked like it took care of the sorting and I added a few lines for sort times of 3, 30 and 180 days. It didn't seem to fix the problem though. Are there more modifications required?

bold added by me:
Quote:

else {
if ( $cat == "fav" ) {
list( $tuserid, $tusername, $tmail ) = get_userinfo( "", $User['userid']);
$thecatname = "$tusername {$Globals['pp_lang']['favorites']}";
}
elseif ( $cat == "all" ) {
$thecatname = $Globals['pp_lang']['callimages'];
}
elseif ( $cat == "last1" ) {
$thecatname = $Globals['pp_lang']['clastday'];
}
elseif ( $cat == "last3" ) {
$thecatname = $Globals['pp_lang']['clast3'];
}

elseif ( $cat == "last7" ) {
$thecatname = $Globals['pp_lang']['clast7'];
}
elseif ( $cat == "last14" ) {
$thecatname = $Globals['pp_lang']['clast14'];
}
elseif ( $cat == "last30" ) {
$thecatname = $Globals['pp_lang']['clast30'];
}
elseif ( $cat == "last180" ) {
$thecatname = $Globals['pp_lang']['clast180'];
}


Chuck S July 16th, 2008 03:58 PM

Not the right place you want to look here

Code:

Content visible to verified customers only.

DannyITR July 16th, 2008 08:39 PM

Quote:

Originally Posted by Chuck S (Post 1228402)
Not the right place you want to look here

Code:

Content visible to verified customers only.

Worked like a charm! Thanks.

Chuck S July 16th, 2008 08:48 PM

Glad to help out

DannyITR January 21st, 2010 07:09 PM

On the most recent version of photopost the links to display recent photos of a certain time period are as follows:

Code:

Content visible to verified customers only.
Where 1 can be changed for the number of days. Seems to work without any file modifications.

Chuck S January 21st, 2010 09:10 PM

On the most recent version of photopost those links go to search.php and are clearly marked and defined in that file. showgallery.php does not do any searches.

DannyITR January 21st, 2010 09:23 PM

Quote:

Originally Posted by Chuck S (Post 1260093)
On the most recent version of photopost those links go to search.php and are clearly marked and defined in that file. showgallery.php does not do any searches.

I did notice that on the most recent version, the links go to searches but I was also able to get it working using the code I posted by disecting the code from the sorting box on the showgallery page.

- My Photo Gallery

Could it be that the old method still works?

Chuck S January 21st, 2010 09:25 PM

lol thats not really the same as the links on the index page now like you originally have posted ;)

DannyITR January 21st, 2010 09:38 PM

Quote:

Originally Posted by Chuck S (Post 1260098)
lol thats not really the same as the links on the index page now like you originally have posted ;)

Sure it is!

The link I posted just now gives the most recent photo uploads of the last 30 days. I can adjust it to display the last however many days by changing the variable. Sorry to keep posting but I need to know if I'm missing something.

Chuck S January 21st, 2010 10:14 PM

feel free to post any mods or code changes in the mod corner should you wish.


All times are GMT -5. The time now is 12:29 AM.

Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0


1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97