Go Back   vb.org Archive > vBulletin 3 Discussion > vB3 General Discussions

Reply
 
Thread Tools Display Modes
  #11  
Old 12-06-2006, 09:43 AM
evenmonkeys's Avatar
evenmonkeys evenmonkeys is offline
 
Join Date: Aug 2004
Location: Iowa
Posts: 896
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Bah. I tried to make a product out of it, but I just couldn't get it to work right.

Install the attached plugin first. Then make this template edit. You may edit it as you like...

In USERCP, add this at the very top:
HTML Code:
<!-- ############## AVATAR / SIGNATURE ##############  -->

<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
  <tr>
    <td class="tcat">
$bbuserinfo[username]</span>
    </td>
  </tr>
  <tr>
    <td class="thead">
Avatar
    </td>
  </tr>
  <tr>
    <td class="alt2">
<img src="$bbuserinfo[avatarurl]" border="0" style="border:1px solid $stylevar[tborder_bgcolor]; border-top:none" />
    </td>
  </tr>
  <tr>
    <td class="thead">
Signature
    </td>
  </tr>
  <tr>
    <td class="alt2">
$bbuserinfo[signature]
    </td>
  </tr>
</table>
<br />
<!-- ############## END AVATAR / SIGNATURE ##############  -->
I'm off to bed though. I need to get some sleep for work tomorrow. =D If that doesn't work for ya, I can help ya first thing tomorrow afternoon. Hopefully you can wing it from there.
Attached Files
File Type: xml plugin-avatar_signature.xml (982 Bytes, 2 views)
Reply With Quote
  #12  
Old 12-06-2006, 09:53 AM
nerofix nerofix is offline
 
Join Date: Mar 2006
Location: Saarland
Posts: 219
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

i'm getting a database error while i am importing the plugin:

Invalid SQL:

### INSERT QUERY GENERATED BY fetch_query_sql() ###
INSERT INTO vb_plugin
(`active`, `executionorder`, `product`, `title`, `hookname`, `phpcode`)
VALUES
('1', '5', 'vbulletin', 'Avatar & Signature', 'usercp_start', '// AVATAR\r\n$avatarurl = fetch_avatar_url($vbulletin->userinfo[\'userid\']);\r\n\r\nif ($avatarurl == \'\' OR !$vbulletin->options[\'avatarenabled\'])\r\n{\r\n $show[\'avatar\'] = false;\r\n}\r\nelse\r\n{\r\n $show[\'avatar\'] = true;\r\n $vbulletin->userinfo[\'avatarsize\'] = $avatarurl[1];\r\n $vbulletin->userinfo[\'avatarurl\'] = $avatarurl[0];\r\n}\r\n\r\n// ****************************************\r\n// SIGNATURE\r\nif ($vbulletin->userinfo[\'signature\'])\r\n{\r\n require_once(DIR . \'/includes/class_bbcode.php\');\r\n $bbcode_parser =& new vB_BbCodeParser($vbulletin, fetch_tag_list());\r\n $vbulletin->userinfo[\'signature\'] = $bbcode_parser->parse($vbulletin->userinfo[\'signature\'], 0, true);\r\n\r\n $show[\'signature\'] = true;\r\n}\r\nelse\r\n{\r\n $show[\'signature\'] = false;\r\n}');

MySQL-Error : Unknown column 'executionorder' in 'field list'
Reply With Quote
  #13  
Old 12-06-2006, 09:55 AM
evenmonkeys's Avatar
evenmonkeys evenmonkeys is offline
 
Join Date: Aug 2004
Location: Iowa
Posts: 896
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Try this new attached plugin. If the attached plugin does not work, try creating a plugin.

Plugins & Products > Add New Plugin

Product: vBulletin
Hook Location: usercp_start
Title: Avatar & Signature
Execution Order: 5
PHP Code:
Code:
// AVATAR
$avatarurl = fetch_avatar_url($vbulletin->userinfo['userid']);

if ($avatarurl == '' OR !$vbulletin->options['avatarenabled'])
{
	$show['avatar'] = false;
}
else
{
	$show['avatar'] = true;
	$vbulletin->userinfo['avatarsize'] = $avatarurl[1];
	$vbulletin->userinfo['avatarurl'] = $avatarurl[0];
}

// ****************************************
// SIGNATURE
if ($vbulletin->userinfo['signature'])
{
	require_once(DIR . '/includes/class_bbcode.php');
	$bbcode_parser =& new vB_BbCodeParser($vbulletin, fetch_tag_list());
	$vbulletin->userinfo['signature'] = $bbcode_parser->parse($vbulletin->userinfo['signature'], 0, true);

	$show['signature'] = true;
}
else
{
	$show['signature'] = false;
}
Active: Yes



Alas, I am off to bed now though. If you still have problems, hopefully someone else can help you out until I get on tomorrow. I really hope that one works for ya. =D Goodnight and best of luck!
Attached Files
File Type: xml plugin-avatar_signature.xml (970 Bytes, 4 views)
Reply With Quote
  #14  
Old 12-06-2006, 10:05 AM
nerofix nerofix is offline
 
Join Date: Mar 2006
Location: Saarland
Posts: 219
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

hey your second plugin works great .. thanks for your advanced help!!!
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 04:57 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.03606 seconds
  • Memory Usage 2,220KB
  • Queries Executed 14 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (1)bbcode_code
  • (1)bbcode_html
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (4)post_thanks_box
  • (4)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (4)post_thanks_postbit_info
  • (4)postbit
  • (2)postbit_attachment
  • (4)postbit_onlinestatus
  • (4)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_attachment
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete