PDA

View Full Version : In Postbit legacy need toshow extra field


Saintless
01-27-2009, 08:41 PM
Hi,
I need to add extra field in post bit.Let me describe, i have a customized field name 'user_status' in vb_socialgroupmember. i need to show that field value in post bit . so i need userid whose post is showing, as a sql parameter and may be this code need to write in loop from where other userinfo is retrieving for post bit.

i didn't find code, where i have to write sql for retrieving that field data.Please help.

Thanks in advance

Dismounted
01-28-2009, 04:26 AM
Look in showthread.php - you can hook into the query that fetches user info, and add a join.

vbplusme
01-28-2009, 12:03 PM
Thanks, walking through your problem helped me find the solution to mine. I was using,

<if condition="$post[userid] == 'Administrator'">

didn't work. BUT

<if condition="$post[userid] == 1">

DID!

Thanks again

Saintless
01-28-2009, 02:56 PM
Look in showthread.php - you can hook into the query that fetches user info, and add a join.

Thanks for reply.But could you plz specify which portion of code is retrieving user info for postbit legacy in 'showthread.php'.Is there any other modification for sending variable to template for available there?

Lynne
01-28-2009, 03:13 PM
Did you look at the showthread.php page? There is a nice big query around line 1000 (or so, my file is edited) where the posts and all the information about the posts (including the user info) is gathered. There is a hook right above there.

Saintless
01-28-2009, 05:37 PM
Thankx . hope it will work