Help with a CMPS module - latest Photopost comments

vbuser49

New Member
I've been looking for a module that will take random photos from my photopost pro gallery and show them on the site home page which is a CMPS page. All I've been able to find is this one: Latest PhotoPost Comments Module - vBadvanced Forums

attachment.php


I followed these installation instructions:

1. Open pp_latestcomments.php and make the changes as annotated. Save and upload to your vBadvanced modules folder.


2. Add 2 new templates:

adv_portal_pp_latestcomments
adv_portal_pp_latestcomments_bits

Attached are two .txt files with the above names with the code for the templates. Before copying, open 'adv_portal_pp_latestcomments_bits' and
replace the two instances of YOURGALLERYURL with your gallery root folder url (ie: http://www.mysite.com/gallery) and the one instance of YOURVBULLETINURL with your vBulletin root folder url (ie: http://www.mysite.com/forums).


3. Navigate to vBulletin admincp / vBa CMPS / Add Module / PHP File:

Module Title: Latest Gallery Comments
Active: Yes
File to Include: pp_latestcomments.php
Module Parent: None
Identifier: pplatestcomments
Templates Used:
adv_portal_pp_latestcomments
adv_portal_pp_latestcomments_bits
Initialize BB Code Parser: No
Initialize Forum Permissions: No
Initialize Moderator Cache/Permissions: No
Initialize Ignored Users: No
Clean File Output: No
Title Row Colspan: 2

Save

Place module where desired.

4. Done!
I got the following error when going to my home page:
Database error in vBulletin 3.8.0:

Invalid SQL:

SELECT c.username, c.cat, c.comment, c.photo, c.userid, c.rating, p.bigimage,

p.height, p.width, p.title
FROM mst_comments c
LEFT JOIN mst_photos p ON p.id = c.photo
WHERE c.comment != ''
AND c.approved = '1'
ORDER BY c.date DESC
LIMIT 5;

MySQL Error : Table '***_*****.mst_pp_comments' doesn't exist
Error Number : 1146
Request Date : Sunday, April 12th 2009 @ 01:35:41 PM
Error Date : Sunday, April 12th 2009 @ 01:35:41 PM
Script : http://www.*****.com/index.php
Referrer : http://*****.com/forum/
IP Address : ***.**.***.***
Username : *****
Classname : vB_Database
MySQL Version : *.*.**-*****
The logical thing looking at the error is that the database prefix mst_ was added automatically. I changed the gallery database prefix value in pp_latestcomments.php and the error would change accordingly still always adding mst_ before. I suspect that if I can get rid of this mst_ value the module might work. Does anyone know how to get rid of it?

BTW if there's a better module to do what I want please let me know. Thanks.
 
Back
Top