PDA

View Full Version : Custom Profile Field in Postbit


JustAskJulie
04-17-2013, 07:29 PM
I know there are at on of questions about how to do this and I know the basics. Here's where I'm at. I have a custom profile field that is included in my postbit. However,

1. I can't find it in my templates to edit it. I've searched with no luck. I know it should be in the postbit template but it's not. Any ideas where it may have hidden itself? The custom field in question is "SLS Handle: _____" as you can see in my screen grab.

2. I want to edit it so that where it shows the custom field "SLS Handle: ______" that the field "_______" is linked. The link itself would have to include the field data.

Hopefully, that all made enough sense for someone to help me out.

Lynne
04-17-2013, 08:14 PM
Perhaps you have a plugin that is adding it? The only way to add custom profile fields to the postbit is by template edit or plugin.

JustAskJulie
04-17-2013, 08:27 PM
Perhaps you have a plugin that is adding it? The only way to add custom profile fields to the postbit is by template edit or plugin.

Ah, Thank You. You are correct. I found the plugin. Any thoughts on how I can edit to link the field?

Here is the code for how it stands:
if ($post['field8'])
{
$template_hook['postbit_userinfo_right_after_posts'] .= '<dt> SLS Handle</dt> <dd>' .$post[field8]. '</dd>';
}

I need to wrap a link around $post[field8] that uses the info from field8 in the URL, so it would be something like http://www.url.com/[field8]
but I'm not sure what exactly it should be.

Lynne
04-17-2013, 10:51 PM
Then how about something like:

$template_hook['postbit_userinfo_right_after_posts'] .= '<dt> SLS Handle</dt> <dd><a href="http://www.url.com/' .$post[field8]. '">http://www.url.com/' .$post[field8]. '</a></dd>';

(I think that is correct, but I haven't tested it.)

JustAskJulie
04-18-2013, 12:42 AM
Thank You! That did the trick!