Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
 vB style profile link
ZiNgA BuRgA Offline
Fag
*******
Posts: 3,357
Joined: Jan 2008
Post: #2
RE: vB style profile link
Hi Kikkerking,
This can be mostly done with template edits.

I'm not going to bother with the fancy popup effect, but here's how to use MyBB's popup menu to achieve a similar effect.  Modify the following templates like follows:

postbit
Find:

HTML Code
{$post['user_details']}

Add under:

HTML Code
1
2
3
4
5
6
7
8
9
<div id="profilelink_{$post['uid']}_popup" class="popup_menu" style="display: none;">
<div class="popup_item_container">
<a href="{$mybb->settings['bburl']}/member.php?action=profile&amp;uid={$post['uid']}" class="popup_item">View this user's public profile</a>
</div>
{$post['button_email']}{$post['button_pm']}{$post['button_www']}{$post['button_find']}
</div>
<script language="javascript" type="text/javascript">
new PopupMenu("profilelink_{$post['uid']}");
</script>

Also find:

HTML Code
<span class="smalltext">{$post['button_email']}{$post['button_pm']}{$post['button_www']}{$post['button_find']}</span>

Replace with:

HTML Code
&nbsp;


postbit_pm
Replace entire template with:

HTML Code
<div class="popup_item_container">
<a href="{$mybb->settings['bburl']}/private.php?action=send&amp;uid={$post['uid']}" class="popup_item">{$lang->postbit_pm}</a>
</div>


postbit_www
Replace entire template with:

HTML Code
<div class="popup_item_container">
<a href="{$post['website']}" class="popup_item">{$lang->postbit_website}</a>
</div>


postbit_find
Replace entire template with:

HTML Code
<div class="popup_item_container">
<a href="{$mybb->settings['bburl']}/search.php?action=finduser&amp;uid={$post['uid']}" class="popup_item">{$lang->postbit_find}</a>
</div>


postbit_email
Replace template with:

HTML Code
<div class="popup_item_container">
<a href="{$mybb->settings['bburl']}/member.php?action=emailuser&amp;uid={$post['uid']}" class="popup_item">{$lang->postbit_email}</a>
</div>


Also, open up /inc/functions_post.php,
Find:

PHP Code:
$post['profilelink'] = "<a href=\"".str_replace("{uid}", $post['uid'], PROFILE_URL)."\">".format_name($post['username'], $post['usergroup'], $post['displaygroup'])."</a>";

Replace with:

PHP Code:
		$post['profilelink'] = "<a href=\"".str_replace("{uid}", $post['uid'], PROFILE_URL)."\" id=\"profilelink_{$post['uid']}\">".format_name($post['username'], $post['usergroup'], $post['displaygroup'])."</a>";



That's pretty much it.
If you have MyPlaza installed, and want a fade effect, in the above code for postbit, replace:

Javascript Code
new PopupMenu

with

Javascript Code
new MyPlazaPopupMenu



Note that, since this removes the buttons from the bottom of the post, it has the side effect that if a user has Javascript disabled, they can't directly access the links from the post.  Meh, vBulletin does that anyway, so it shouldn't be an issue Tongue
Hope that helps.


My Blog
(This post was last modified: 01-31-2008 06:48 PM by ZiNgA BuRgA.)
01-31-2008 06:46 PM
Find all posts by this user

« Next Oldest | Next Newest »

Messages In This Thread
vB style profile link - Kikkerking - 01-30-2008, 11:48 PM
RE: vB style profile link - ZiNgA BuRgA - 01-31-2008 06:46 PM
RE: vB style profile link - Kikkerking - 01-31-2008, 11:46 PM
RE: vB style profile link - ZiNgA BuRgA - 02-01-2008, 06:22 PM
RE: vB style profile link - AjEe - 03-26-2008, 03:49 PM
RE: vB style profile link - ZiNgA BuRgA - 03-27-2008, 10:13 AM
RE: RE: vB style profile link - incadude - 06-09-2008, 11:37 AM
RE: vB style profile link - ZiNgA BuRgA - 06-09-2008, 03:42 PM
RE: vB style profile link - Guest - 06-19-2008, 02:27 AM
RE: vB style profile link - Guest - 06-27-2008, 09:27 AM
RE: vB style profile link - ZiNgA BuRgA - 06-27-2008, 09:37 AM
RE: vB style profile link - Guest - 06-27-2008, 10:03 AM
RE: vB style profile link - Guest - 06-28-2008, 03:52 AM
RE: RE: vB style profile link - dared - 07-01-2008, 05:19 PM

 Standard Tools
Forum Jump: