PDA

View Full Version : Postbit Questions


AWithers04
05-26-2011, 11:34 PM
I made some custom profile fields and have them displayed in the postbit but was wondering if there is a way to make the title of the postbit title fields bold and also how I can make the multiple line fields go below each other instead of side by side. see below

How it is now

Example Title: word1 word2 word3 word 4

How I want it

Example Title:
Word1
Word2
Word3

Lynne
05-27-2011, 01:30 AM
I'm sure there is, but without seeing the code you wrote, and what template or hook you used, along with a link to see the results, we can't really suggest anything.

AWithers04
05-27-2011, 02:41 AM
I created a new profile field, then created a plugin with the below code on the postbit_display_complete hook

if ($post['field10'])
{
$template_hook['postbit_userinfo_right_after_posts'] .= '<dt>Fav Artists</dt><br /><dd>' .$post[field10]. '</dd>';
}

Photo of results is attached. They are in a multi line text box one under another but they always display in a row

Lynne
05-27-2011, 03:08 PM
Then if you want "Fav Artists" to be bold, but <b> tags around it:
if ($post['field10']) {
$template_hook['postbit_userinfo_right_after_posts'] .= '<dt><b>Fav Artists</b></dt><br /><dd>' .$post[field10]. '</dd>';
}

AWithers04
05-27-2011, 03:36 PM
Thanks that worked for the customs title. What about the default title put there by vbulletin such as join date, posts, etc?

Also any idea on the multi line issue?

Lynne
05-27-2011, 03:48 PM
You'll have to edit the template to add bold to those. Or, instead of that, just write some custom CSS to do it.

As for multiline items, I'd need to see the actual page source to make a suggestion. You'd either use CSS or you'll have to create another plugin to change it. Or just do a str_replace on it. It depends on the page source though.