Arrow Home arrow Forums
larger font smaller font default font Fixed screen resolution Auto adjust screen size

Joomlapolis Forums  


Mosets Reviews Plugin
Date: 2006/02/02 21:22 By: Dehaw Status: CB Doc subscriber  
Karma: 1  
Fresh Joomlapolitan

Posts: 12
graphgraph
I found a bug with the sql statement within the reviews plugin today, it currently reads:

Code:

 $database->setQuery"SELECT r.*, l.* FROM #__mt_reviews AS r, #__mt_links AS l "             .    "WHERE r.link_id = l.link_id AND l.link_published='1' AND l.link_approved='1' AND r.rev_approved='1'  AND r.user_id='".$user->id."'"             .    "ORDER BY r.rev_date DESC"«»);



It should read:

Code:

 $database->setQuery"SELECT r.*, l.* FROM #__mt_reviews AS r, #__mt_links AS l "             .    "WHERE r.link_id = l.link_id AND l.link_published='1' AND l.link_approved='1' AND r.rev_approved='1'  AND l.user_id='".$user->id."'"             .    "ORDER BY r.rev_date DESC"«»);



I changed:

Code:

 r.user_id='".$user->id."



With:

Code:

 l.user_id='".$user->id."



and now it shows the correct reviews that relates to that users links.

I hope this helps someone.
Click here to see the profile of this user The administrator has disabled public write access.

Re:Mosets Reviews Plugin
Date: 2006/02/03 02:12 By: gotMoxie Status: CB Doc subscriber  
Karma: 5  
Fresh Joomlapolitan

Posts: 13
graphgraph
By changing that 'r.user_id' to 'l.user_id' you are now pulling the Links that the profiled user Owns with hrefs to the reviews of their Link.

The plug-in was written to pull the Reviews that the profiled user has written (about other people's Links).

Does that make sense?

I'm not sure I see the use in the revision that you made as the My Links plug-in already pulls the profiled user's Links.

I guess with the change you made the plug-in could be called "Reviews of My Links".

If that is what you are after, I'm glad it works for you. But the original code works the way I had envisioned the plug-in.

Sam Lewis
Moxie Media, LLC
Sam Lewis
Moxie Media, LLC

CB3PD
Click here to see the profile of this user The administrator has disabled public write access.

Documentation

Documentation Subscription Service
(updated for CB 1.2 RC2)

What?

Why?

Where?

Just click here for answers!

Click here for a yearly subscription: subscribe now

Download Latest Release

The latest stable Community Builder Release is version 1.1 for Joomla 1.0 and Mambo.
You need to be a registered member of Joomlapolis to download.

The latest release candidate of Community Builder is version 1.2 RC3, native for Joomla 1.0, 1.5 and Mambo.
It is available as "thank you" to all CB documentation subscribers at this time.

CB Login