Back to vBulletin 3.5 Add-ons

Parse BBCode in Custom Profile Fields
Mod Version: 1.1, by ImportPassion

This modification is in the archives.
vB Version: 3.5.2 Rating: (1 vote - 5.00 average) Installs: 38
Released: 21 Dec 2005 Last Update: 27 Dec 2005 Downloads: 213
Not Supported Uses Plugins  

Why? Cause I think this should be the norm and others in this thread seem to want it. index.php?t=101248

Be nice to also have WYSIWYG on the textareas, but that's another hack.

There are 2 versions of this.
The first one, product-parse_bbcode_in_profile_1.1.xml, is for anyone that does not have the MySpace style profile template hack installed. You can find that hack here index.php?t=101248

The second, product-myspace_style_profile_version.xml, is for users that are using that template hack.

INSTALLATION:
Install the Product and that's it. Will install 1 new plugin. I tested as best I can, but see what happens. Can't provide 100% support, but I will see what I can do.

For non-MySpace profile template users, some options:
--------------------------------------------------------------------------
Optionally remove some code.

Spoiler (click to open)


i u want to, u can remove this section from the plugin as it seems it is not necessary. But won't hurt or slow down if you keep it in there.

PHP Code:
if (!is_object($bbcode_parser))
    {
        require_once(
DIR '/includes/class_bbcode.php');
        
$bbcode_parser =& new vB_BbCodeParser($vbulletinfetch_tag_list());
    } 

Close

--------------------------------------------------------------------------
If you only want certain fields, put this code for EACH fieldx u want parsed in member_customfields hook location.

Spoiler (click to open)


Quote by TonysDesigns
But what if I only want it to work for ONE field?
try this

PHP Code:
    if($profilefieldname == "field1")
    {
     
$profilefield['value'] = $bbcode_parser->parse($userinfo["$profilefieldname"],0true);
    } 
in the same hook location

Close


--------------------------------------------------------------------------

If you did this code change for 1.01, u can now remove it as it is not needed for 1.1.
v.1.01 Code Change

in admincp/profilefield.php find

PHP Code:
// #################### PRE-CACHE TEMPLATES AND DATA ###################### 
add above that

PHP Code:
define('THIS_SCRIPT''profile_admin'); 
end 1.01 code change

####################################################
Non-MySpace template hack
v.1.00 - Original Release
v.1.01 - Update to fix some weird issue in admincp when going to profile field manager.
v.1.1 - re-written - totally works.

MySpace Template hack version:
1.0 - Original release.

Download

This modification is archived and cannot be downloaded.

Similar Mods

Parse HTML in Custom Profile Fields via admin/user.php Fix vBulletin 2.x Beta Releases

vblts.ru supports vBulletin®, 2022-2024