Search results fail after first entry in phpMyFAQ 1.4.7

Please report bugs here!

Moderator: Thorsten

Post Reply
bakabaka
Posts: 15
Joined: Thu Mar 10, 2005 12:45 am
Location: USA
Contact:

Search results fail after first entry in phpMyFAQ 1.4.7

Post by bakabaka »

Hello,

I think I found a bug in version 1.4.7 when I upgraded from 1.4.6. Search results beyond the first hit are showing up as 3 dots rather than a link to the matching article. The article ID is not being included in the URL of the broken links. Somehow the row->id is not being set for these elements.

Anyway, thank you for a great FAQ system! It's probably the most feature-rich FAQ system I've seen that is this easy to use. I hope this bug report is of use to you.
Thorsten
Posts: 15725
Joined: Tue Sep 25, 2001 11:14 am
Location: #phpmyfaq
Contact:

Post by Thorsten »

Hi,

thanks for using phpMyFAQ.

I'll check your bug report.

bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
ebs
Posts: 12
Joined: Thu Mar 10, 2005 10:19 am

Post by ebs »

Kann das Phänomen in der 1.4.7 bestätigen. In welcher Datei leigt denn die Suchausgabe?
Thorsten
Posts: 15725
Joined: Tue Sep 25, 2001 11:14 am
Location: #phpmyfaq
Contact:

Post by Thorsten »

Hi,

das ist die searchEngine() in der inc/functions.php

bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
Thorsten
Posts: 15725
Joined: Tue Sep 25, 2001 11:14 am
Location: #phpmyfaq
Contact:

Post by Thorsten »

Hi,

I fixed it and uploaded a new package. Just change the file inc/functions.php.

bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
bakabaka
Posts: 15
Joined: Thu Mar 10, 2005 12:45 am
Location: USA
Contact:

Post by bakabaka »

Thorsten wrote:Hi,

I fixed it and uploaded a new package. Just change the file inc/functions.php.

bye
Thorsten
Hi Thorsten,

Thank you for looking into this! It did not seem to fix the problem here though. When I looked in the file, I noticed that there was an entry commented out at line 838 that looked like this:

//$result = $db->query($query." LIMIT ".$x.",".$PMF_CONF["numRecordsPage"]);

Below at line 839, there was a line that looked like this:

$result = $db->query($query." LIMIT 0,1");

The search seems to work properly when I comment out the second entry and uncomment the first entry. Does this line present a security issue? If not, I'll continue to use it like this.

Thanks again!
Thorsten
Posts: 15725
Joined: Tue Sep 25, 2001 11:14 am
Location: #phpmyfaq
Contact:

Post by Thorsten »

Hi,

you're double right. I still forget the line of code you've mentioned. I'll release a updated package this evening.

Your solution is correct and no security hole.

bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
Post Reply