Skruffy Posted March 31, 2009 Report Share Posted March 31, 2009 I'm looking to enable HTML in the profile but I can't figure out how to do it. It's important that I have this for my site, so I'm hoping someone can help me. I have the profiles set to the classic style, with out all the user comments and stuff if that makes a difference. Thanks in advance! Link to comment Share on other sites More sharing options...
Management Michael Posted March 31, 2009 Management Report Share Posted March 31, 2009 I'm looking to enable HTML in the profile but I can't figure out how to do it. It's important that I have this for my site, so I'm hoping someone can help me. I have the profiles set to the classic style, with out all the user comments and stuff if that makes a difference. Thanks in advance! Where abouts did you want to enable html? If you have comments removed and using the classic style (IPB2.1), I don't see anywhere else to add it. Link to comment Share on other sites More sharing options...
Skruffy Posted March 31, 2009 Author Report Share Posted March 31, 2009 Well I have custom fields in the profiles(click me!) and I want the members to be able to post a link in a certain one and be able to use the bold and italics tags and such. Link to comment Share on other sites More sharing options...
Management Michael Posted March 31, 2009 Management Report Share Posted March 31, 2009 Well I have custom fields in the profiles(click me!) and I want the members to be able to post a link in a certain one and be able to use the bold and italics tags and such. Ok try this then. Open sources/action_public/profile.php (these are edits for the classic profile page) Find: foreach( $fields->out_fields as $id => $data ) Add Above: if( !is_object( $this->parser ) ) { require_once ROOT_PATH."sources/handlers/han_parse_bbcode.php"; $this->parser = new parse_bbcode(); $this->parser->ipsclass =& $this; $this->parser->parse_bbcode = 1; $this->parser->parse_html = 1; $this->parser->parse_smilies = 1; } Find: $custom_out .= $this->ipsclass->compiled_templates['skin_profile']->custom_field( $fields->field_names[ $id ], $data ); Replace With: $custom_out .= $this->ipsclass->compiled_templates['skin_profile']->custom_field( $fields->field_names[ $id ], $this->parser->pre_display_parse( $this->parser->pre_db_parse($data)) ); Save sources/action_public/profile.php This will work for bbcode and although wouldn't recommend enabling html anywhere users can input it, you should be able to by opening sources/classes/class_custom_fields.php Find: var $kill_html = 1; Replace With: var $kill_html = 0; Link to comment Share on other sites More sharing options...
Skruffy Posted March 31, 2009 Author Report Share Posted March 31, 2009 Thanks! If I may ask, why would you not recommend enabling HTML anywhere the users can put it? Link to comment Share on other sites More sharing options...
Management Michael Posted March 31, 2009 Management Report Share Posted March 31, 2009 Thanks! If I may ask, why would you not recommend enabling HTML anywhere the users can put it? Although IPB is well protected against malicious code, your can't guarantee anything. If possible I would suggest limiting people to bbcode. IPB should protect you against the obvious malicious code, but you should always the software updated if you are going to enable html. Link to comment Share on other sites More sharing options...
Skruffy Posted March 31, 2009 Author Report Share Posted March 31, 2009 Gotcha. I was just wondering. And the edit works perfectly. Thanks so much. =D Link to comment Share on other sites More sharing options...
Management Michael Posted March 31, 2009 Management Report Share Posted March 31, 2009 The original issue this topic was opened for has been resolved :) Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.