PDA

View Full Version : More PAGED_ARCHIVE Bugs


dpbeatley
04-29-2005, 03:30 AM
Hi,

In ver 1.4.1, there is an odd behaviour using the PAGE ARCHIVED addon when using the tag <THUMBNAILS_PAGES_LINKS>. The addon generates a bad or malformed link to the next (and previous) page: for example,


http://www.oreo-speaks.com/photoblog/index.php?x=browse&category=4&pagenum=1%3E1%3C/a%3E%20%3Ca%20%20href=


To see bug in action go to my http://www.oreo-speaks.com/photoblog and select "archives". Once on the archive page, select category 'brooklyn' and the link for page #2 is malformed and fails. If clicked, the text returned from the above TAG also produces malformed text and link. If you select a category that generates only one page (eg 'nature'), the tag returns malformed results.

I have looked at the code, but I'm tired tonight and I just don't see the problem.

I have just downloaded ver 1.4.1 today so I'm sure I have all the latest builds etc.
Thanks

dpbeatley
04-29-2005, 03:52 AM
Found the error:

Line 313 should be:
$Archive_pages_Links .= "<a href='index.php?x=browse&category=$cat_id& pagenum=$pagecounter'>$pagecounter</a> ";

Line 324 s/b:
$Archive_pages_Links .= "<a href='index.php?x=browse&category=&pagenum =$pagecounter'>$pagecounter</a> ";

Line 335 s/b
$Archive_pages_Links .= "<a href='index.php?x=browse&archivedate=$archived ate&monthname=$monthname&pagenum=$pagecoun ter'>$pagecounter</a> ";

The href tag was missing 'index.php' and unbalanced single quotes.
Fixed on my end and now the tag works and the gods are pleased.

raminia
04-29-2005, 06:36 AM
thank you

smlgphotos
06-11-2005, 02:42 PM
Thanks for posting this bug fix. I went through and changed my paged_archive and directed... only that hasn't fixed my problem (which might be something entirely different!)

When I try to view by category or by "all" under monthly, I get nothing. Only the June archive seems to work. All the rest just say "1".

Any thoughts?
Thanks in advance.

Found the error:

Line 313 should be:
$Archive_pages_Links .= "<a href='index.php?x=browse&category=$cat_id& pagenum=$pagecounter'>$pagecounter</a> ";

Line 324 s/b:
$Archive_pages_Links .= "<a href='index.php?x=browse&category=&pagenum =$pagecounter'>$pagecounter</a> ";

Line 335 s/b
$Archive_pages_Links .= "<a href='index.php?x=browse&archivedate=$archived ate&monthname=$monthname&pagenum=$pagecoun ter'>$pagecounter</a> ";

The href tag was missing 'index.php' and unbalanced single quotes.
Fixed on my end and now the tag works and the gods are pleased.

raminia
06-11-2005, 04:59 PM
Thanks! :)

for dev note:
CVS is updated with this fix.

smlgphotos
06-11-2005, 05:31 PM
CVS?

(sorry. Noob.)

Thanks! :)

for dev note:
CVS is updated with this fix.

raminia
06-11-2005, 06:43 PM
that's for developers note only;)
the next version is continuingly updating on sourceforge.net with some program called CVS by Pixelpost developer team.
CVS version is the version we are working on it for the next release. The next release is really cool;) (I like it very much;) )

smlgphotos
06-11-2005, 08:37 PM
Ah... gotcha! :-)

Does that mean that there's an answer to my bug?

"When I try to view by category or by "all" under monthly, I get nothing. Only the June archive seems to work. All the rest just say "1"."

Sorry if I've just completely missed it!

that's for developers note only;)
the next version is continuingly updating on sourceforge.net with some program called CVS by Pixelpost developer team.
CVS version is the version we are working on it for the next release. The next release is really cool;) (I like it very much;) )

smlgphotos
06-14-2005, 04:01 PM
raminia: I re-installed the original template (I thought it might have been the template causing the trouble.. doesn't seem to be) and the original paged_archive files.. but there is still something screwy with my archive view. I'd appreciate your insight if you can think of what might be wrong.

raminia
06-14-2005, 06:02 PM
try using this latest version
www.raminia.com/temp/paged_archive.zip

smlgphotos
06-14-2005, 09:24 PM
Thanks for posting this.

I uploaded it and overwrote the existing file and it doesn't seem to have made a difference.

try using this latest version
www.raminia.com/temp/paged_archive.zip

raminia
06-15-2005, 04:06 AM
use proper tags: use these tags and see what happends.

<CATEGORY_LINKS_AS_LIST> // Category links as a text list for default PP's archive page
<CATEGORY_LINKS_AS_LIST_PAGED> // Category links as a text list for page-by-page archive
<BROWSE_MONTHLY_ARCHIVE_PAGED> // Monthly drop box for default PP's archive page
<BROWSE_MONTHLY_ARCHIVE_AS_LINK_PAGED> // Monthly links as a text list for page-by-page archive
<BROWSE_CATEGORIES_PAGED> // Category drop box for page-by-page archive
<THUMBNAILS_WHOLE_PAGED> // Thumbnails in this page
<THUMBNAILS_PAGES_LINKS> // Link to the pages of thumbnail in the selected category
<ARCHIVE_PAGES_NUM> // Page number you are viewing
<CATEGORY_OR_DATE_NAME_PAGED_ARCHIVE> // Name of the category or Month you select
<LINK_TO_PAGED_ARCHIVE> // Link to Paged-by-page archive page as <a href="index.php?x=browse&pagenum=1">Archive</a>',$tpl);

smlgphotos
06-16-2005, 01:14 AM
Here is the code on the page:

<tr id="central">
<td colspan="2"><table width="750" border="0" align="center" cellpadding="4" cellspacing="5">
<tr>
<td width="150" valign="top"> <p class="logo">Archives ><CATEGORY_OR_DATE_NAME_PAGED_ARCHIVE></p>
<p><CATEGORY_LINKS_AS_LIST_PAGED></p>
<p class="logo">By month</p>
<p><BROWSE_MONTHLY_ARCHIVE_AS_LINK_PAGED></p></td>
<td width="600" valign="top"> <p><THUMBNAILS_PAGES_LINKS></p>
<p><THUMBNAILS_WHOLE_PAGED></p></td>
</tr>
</table></td>
</tr>

The thing is.. is that it doesn't matter what template I use.. the archives don't display correctly. That leads me to think that it is something in the paged_archive.php file. But.. you provided me with a brand new paged_archive.php file that presumably works fine. So.. if it isn't the template.. and it isn't the paged_archive file.. what else could it be? Something in index.php?

raminia
06-16-2005, 07:50 PM
there was similar problem in the forum. I searched a bit but I didn't find it. the rpoblem there was solved. search the forum. I'm to tired tonight.

smlgphotos
06-16-2005, 11:11 PM
there was similar problem in the forum. I searched a bit but I didn't find it. the rpoblem there was solved. search the forum. I'm to tired tonight.

I've searched the forums for every topic that had the word "archive" in it and couldn't find anything. Oh well. :(

Joe[y]
06-17-2005, 09:53 AM
i remember this bug, i fixed my version of paged_archive.php a while back but I hope the change has remained intact.


i'll pm you my code.


EDIT: my changes were lost it would seem. try looking at this line:

$Archive_pages_Links .= "<a href=index.php?x=browse&archivedate=$archiveda te&monthname=$monthname&pagenum=$pagecount er>$pagecounter</a> ";

I dont have time to test it but perhaps changing it to:

$Archive_pages_Links .= "<a href='index.php?x=browse&archivedate=$archived ate&monthname=$monthname&pagenum=$pagecoun ter'>$pagecounter</a> ";

EDIT AGAIN: I'm so tired. just got up. realised I just found a fix for the wrong bug, and one fixed already. sorry. jeeeezuz.

Malak
06-17-2005, 03:17 PM
I have the same problem.
The categories ain't working properly.
I have found a solution here : http://pixelpost.org/forum/viewtopic.php?t=821&postdays=0&postorder=asc&start =30

and this code to replace :

// no archive date
$query = "select t1.id,t1.headline,t1.image from {$pixelpost_db_prefix}pixelpost as t1
inner join {$pixelpost_db_prefix}catassoc as t2
on t1.id = t2.image_id
where (t1.datetime<='$cdate')
$where
group by t1.id
order by t1.datetime desc" .$limit;

But it doesn't work with me :(
Perhaps MYSQL version is not the same...
Somebody can help me ?
Thank you...

raminia
06-17-2005, 07:56 PM
YES! exactly!!
There was an issue of inner joint statement in SQL. try searching "inner joint". and Rob was the person who provided the answer.

sorry that I can't help you more now.

smlgphotos
06-18-2005, 02:02 AM
YES! exactly!!
There was an issue of inner joint statement in SQL. try searching "inner joint". and Rob was the person who provided the answer.

sorry that I can't help you more now.


Wow... it works now! Perfectly! A combination of your post and the preceeding one.

You guys rule!

smlgphotos
06-18-2005, 02:16 AM
YES! exactly!!
There was an issue of inner joint statement in SQL. try searching "inner joint". and Rob was the person who provided the answer.

sorry that I can't help you more now.

Ack! ALMOST PERFECT ... just one error now.

Archive view.. Monthly... View All.

(sorry!)

Malak
06-20-2005, 10:32 AM
YESSS ! It works too, with Opera and Internet Explorer, great ! :D
Except with Firefox... :?