vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.8 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=235)
-   -   BB Code Enhancements - Custom User Pages - Users make pages using html/bbcode on any template safely (https://vborg.vbsupport.ru/showthread.php?t=210482)

carcomp 07-03-2009 07:38 PM

Quote:

Originally Posted by TheLastSuperman (Post 1815486)
Aye! That's no face palm lol, that's when Data says something over the top OR Ryker just came back from Diana's office w/ a smile on his face :p

Can you clean up your mod post when you see this, it shows the incomplete code and where the hello did that "<?" come from ;)

<b><table style="width: 100%; padding: 0px; border: 1px; border: 1px solid #789DB3; background-image: url(http://www.travelblog.org/Wallpaper/pix/waterfall_desktop_background-1600x1200.jpg)"><td ><p align="center"><b>Here is my test page</b><br>

Code:

<img  src = "http://mediaengine.org/mitcht/gallery/albums/misc/My_Car_010.sized.jpg" /><br>
<a  href="http://mediaengine.org/mitcht/gallery/albums/album02/New_Car_1_003.sized.jpg"><img  src="http://mediaengine.org/mitcht/gallery/albums/album02/New_Car_1_003.sized.jpg" border="0" alt="Click the image to open in full size." class="tcattdimgresizer"  /></a><a  href="http://mediaengine.org/mitcht/gallery/albums/album07/draven_bday_003.sized.jpg"><img  src="http://mediaengine.org/mitcht/gallery/albums/album07/draven_bday_003.sized.jpg" border="0" alt="Click the image to open in full size." class="tcattdimgresizer"  /></a></p><tr ></tr> </td></b></table>
<BR />

And more details for the "members" :D



Newly created field pulls the info from your profile when YOU view, you need to code this differently to show who's info it is in the page, this can be done via postbit templates.


The incomplete code and the ?> is there just to demonstrate what it will strip out from a user's code if they try to write a script on your site with this mod installed. I guess I didn't explain it very well. I also just wanted to demonstrate that if a person was to type in some completely terrible code, it would still parse it and display something worth looking at. I know this isn't 'standard HTML' or whatever, but most people on a vbulletin site just want stuff to look good to themselves ;)

carcomp 07-03-2009 07:42 PM

Quote:

Originally Posted by kalisekj (Post 1838870)
Please can someone elaborate how how to make this show that specific users custom field and not my custom field on their profile pages? This is a GREAT Hack! I will definitely nominate this for mod of the month if I can just have this small problem resolved. This allows me to let the users customize their Profile pages with their own widgets, just like all the major social sites out there like Myspace, Hi5, Tagged, Facebook and many others. Awesome Idea!

If you create a custom field, you just specify which custom field number is created in this line of my code...

$mypage = unhtmlspecialchars(process_message_preview($vbulle tin->userinfo['field65']));

vbulletin happened to make the custom field '65' when I created it, so I just put that number into the above line. It could be anything.

kalisekj 08-31-2009 01:04 PM

I have it working right, except when I go to someone's profile page it show my custom field / HTML not theirs. :( I want to go to peoples profiles and see their custom field /HTML.

rickrichards82 09-04-2009 03:37 AM

great idea!

can't get it to work though. it will only show MY info not the info of the person i am looking at. also, i can only add the info to the MEMBERINFO template. i would like to add it to the memberinfo_block_aboutme template.

CCV_Pinto 09-06-2009 04:36 AM

I think that to show the info of the person (not your own info), you have to change from:

$mypage = unhtmlspecialchars(process_message_preview($vbulle tin->userinfo['field65']));

to

$mypage = unhtmlspecialchars(process_message_preview($userin fo['field65']));

because the $vbulletin->userinfo referer to yourself, and $userinfo will referer to the person of the profile your are visiting

ps:
pay attention that the variable $userinfo wont be always available
I think this variable is defined only in profile pages, so you would have to add a verification like:

if($userinfo)

nothing4me 09-06-2009 09:54 PM

Quote:

Originally Posted by kalisekj (Post 1877157)
I have it working right, except when I go to someone's profile page it show my custom field / HTML not theirs. :( I want to go to peoples profiles and see their custom field /HTML.

Agreed! :(


All times are GMT. The time now is 04:51 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01198 seconds
  • Memory Usage 1,738KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_code_printable
  • (3)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (6)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete