guitarcrazy44
12-25-2011, 08:06 AM
First off, this in NO WAY has anything to do with displaying anything in the postbit. I am wondering how to get a images to display in a custom field in a user PROFILE.
example:
The custom "field7" asks what is your favorite instrument?
option1:guitar
option2:trumpet
option3:drums
when the user selects, for instance, "drums" then a picture of drums is displayed in his user profile NOT POSTBIT.
--------------- Added 1324857983 at 1324857983 ---------------
I found a post on how to parse links into user profile fields my creating a plugin for the member_customfields hook. I am wanting to do this but instead of it changing to a hyperlink in the profile field I want it to change to an image that I have on my server. How do I change this code to do this?
if ($profilefield['value'] != '' AND $profilefield[profilefieldid] == 6)
{
$links = explode ("\n", $profilefield['value']);
$output = array();
foreach ($links as $link)
{
$link = trim($link);
if (!empty($link))
{
$output[] = '<a href="' . $link . '">' . $link . '</a>';
}
}
$profilefield['value'] = implode('<br />', $output);
}
here is the original post:
https://vborg.vbsupport.ru/showthread.php?t=161271&highlight=parse+field
example:
The custom "field7" asks what is your favorite instrument?
option1:guitar
option2:trumpet
option3:drums
when the user selects, for instance, "drums" then a picture of drums is displayed in his user profile NOT POSTBIT.
--------------- Added 1324857983 at 1324857983 ---------------
I found a post on how to parse links into user profile fields my creating a plugin for the member_customfields hook. I am wanting to do this but instead of it changing to a hyperlink in the profile field I want it to change to an image that I have on my server. How do I change this code to do this?
if ($profilefield['value'] != '' AND $profilefield[profilefieldid] == 6)
{
$links = explode ("\n", $profilefield['value']);
$output = array();
foreach ($links as $link)
{
$link = trim($link);
if (!empty($link))
{
$output[] = '<a href="' . $link . '">' . $link . '</a>';
}
}
$profilefield['value'] = implode('<br />', $output);
}
here is the original post:
https://vborg.vbsupport.ru/showthread.php?t=161271&highlight=parse+field