miniBB ® 

miniBB

®
Support Forums
  
 | Start | Register | Search | Statistics | File Bank | Manual |
Master Class miniBB Support Forums / Master Class /  
 

Adding ICQ or other profile field's value in the message area (in main_posts_cell.html )

 
Author MrPanza
Guest
#1 | Posted: 1 Mar 2006 21:30 
Hi, i want to put the ICQ number below the nickname in the messege author information that apears when yo see the messeges.
The template main_posts.html use the variable $l_author, but i can´t find it anywhere else...
how can i do that?

Thanks!

Author _Marco
Partaker
#2 | Posted: 2 Mar 2006 00:01 
Does this work?

1. Add in setup_options.php:
$userInfoInPosts=array($dbUserSheme['user_icq'][1]);

2. Add in main_posts_cell.html:
{$userInfo_user_icq[$poster_id]}

_Marco

Author MrPanza
Guest
#3 | Posted: 2 Mar 2006 03:12 
Thanks Marco!!!
It`s working!!!

Author ezkim0x
Partaker
#4 | Posted: 2 Jun 2006 18:46 
I know all I have to do is add 'user_icq' to userInfoInPosts array in setup_options.php .. and then for it to display I would add {$userInfo_user_icq[$poster_id]} .. but I want to do display something else then just the name.. but since the template is a .html file I'm not sure how.

something like this in php..

<?php if ({$userInfo_user_icq[$poster_id]} != "") { echo "test"; } ?>

so if they didn't enter anything for that field it wouldn't display "test" .. but if the field isn't null it would display it.

(i'm not positive if that's the right php code or not, but you get the idea.)

how would I do something like this?

Author realitybytes
Partaker
#5 | Posted: 2 Jun 2006 21:56 
If it is null then you have nothing to worry about you just need to create the parse.

function parseUserInfo_user_icq($icq){

return '<span class=txtSm>'.$icq.'</span>';

}

then add the following to the template where you want it to be displayed

{$icq}

Author ezkim0x
Partaker
#6 | Posted: 2 Jun 2006 23:57 
I put that function in bb_functions.php ?

Author realitybytes
Partaker
#7 | Posted: 3 Jun 2006 01:55 
bb_specials.php

Author ezkim0x
Partaker
#8 | Posted: 3 Jun 2006 02:11 
added it there, but it's still not displaying on main_posts_cell.html

I tried both: {$icq} & {$icq[$poster_id]}

Author realitybytes
Partaker
#9 | Posted: 4 Jun 2006 03:04 
Hi hopefully this should clear it up

https://www.minibb.com/forums/5_2263_0.html

Author ezkim0x
Partaker
#10 | Posted: 4 Jun 2006 15:52 
awesome thanks.. got it working now.

Author Anonymous
Guest
#11 | Posted: 5 Oct 2006 10:27 
Question:

I see about three references to including registration date, number of posts, etc in this forum, however, I have tried everything possible, and seem to be running to displaying them.

I am trying to include the avatar and number of posts. I am getting either number of posts, OR I get the avatar, but not at the same time.

Here is what I have in the setup options.

$userInfoInPosts=array('user_custom1',$dbUserSheme['username'][1]);
$userInfoInPosts=array('num_posts',$dbUserSheme['username'][1]);

This displays the posts, but removes the Avatar. If I add the // to the num_posts line, then I get the avatar back.

Here is what i am using in the main_post_cell.html:

Avatar: {$userInfo_user_custom1[$poster_id]}
Posts: {$userInfo_num_posts[$poster_id]}

Also, I have two other questions:

1. What is the [1] (....$dbUserSheme['username'][1]); ) suppose to be?
2. If I decide to use regdate, how would I use for the setup_options and the template?

Thanks!

Author Paul
Lead Developer 
#12 | Posted: 6 Oct 2006 02:38 
You need to define

$userInfoInPosts=array('user_custom1',$dbUserSheme['username'][1], array('num_posts',$dbUserSheme['username'][1]);

You're adding the stuff for main_post_cell.html correctly.

$dbUserSheme['username'][1]
equals to users table's "username" field name. This setting is defined above in the same file.

For the regdate, you need to add to $userInfoInPosts a value 'user_regdate'. Then paste in main_posts_cell.html a variable {$userInfo_user_regdate[$poster_id]}

Master Class miniBB Support Forums / Master Class /
 Adding ICQ or other profile field's value in the message area (in main_posts_cell.html )
 Share Topic's Link

Your Reply Click this icon to move up to the quoted message


  ?
Post as a Guest, leaving the Password field blank. You could also enter a Guest name, if it's not taken by a member yet. Sign-in and post at once, or just sign-in, bypassing the message's text.


Before posting, make sure your message is compliant with forum rules; otherwise it could be locked or removed with no explanation.

 

 
miniBB Support Forums Powered by Forum Software miniBB ® Home  Features  Requirements  Demo  Download  Showcase  Gallery of Arts
Compiler  Premium Extensions  Premium Support  License  Contact Us
Check out the Captcha add-on: protect your miniBB-forums from the automated spam and flood.


  ⇑