I can't get this working on my vbadvanced page. I've added the necessary info to php_includestart but the path is wrong for vbadvanced...the link for vbadvanced is
http://www.tek-wiz.com/image.php?u=1...ine=1120950416
It needs to be forums/images.php?u........etc etc for vbadvanced
I have full paths in my settings for vbadvanced so I can't understand what's not working exactly...I have the $welcome_avatar variable as part of the welcome hack and it works when the navbar is showing the forums but it seems $avatarurl is not getting populated with the info. Any ideas?
Nevermind, I fixed it by grabbing this code from the show avatar in any template hack:
<a href="profile.php?do=editavatar"><img src="http://www.fullurltosite.com/forums/image.php?u=$bbuserinfo[userid]&dateline=$avatar[dateline]" title="$bbuserinfo[username]'s Avatar" alt="Avatar" border="0" /></a>
Instead of $welcome_avatar as it would only work on the forums page. THANK YOU!
EDIT: Ok I spoke too soon, the avatars work for me and guest. But if you are registered it only shows an avatar on the forum page...it seems the dateline info isn't getting to vbadvanced. Any help is greatly appreciated with this, this is my suspect navbar template because it seems to be conditional:
Code:
<!-- breadcrumb, login, pm info -->
<if condition="THIS_SCRIPT == 'index' OR THIS_SCRIPT == 'adv_index'">
<table class="tborder" cellpadding="6" cellspacing="1" border="0" width="100%" align="center">
<tr>
<!-- Main Welcome Panel Block [] Begin -->
<td class="alt1" valign="middle" align="center">
<if condition="$bbuserinfo[userid]!=0">
<!-- Avatar Cell [] Begin -->
<if condition="THIS_SCRIPT == 'adv_index'">
<a href="profile.php?do=editavatar"><img src="http://www.tek-wiz.com/forums/image.php?u=$bbuserinfo[userid]&dateline=$avatar[dateline]" title="$bbuserinfo[username]'s Avatar" alt="Avatar" border="0"</a>
<else />
{$welcome_avatar}
</if>
<!-- Avatar Cell [] End -->
</td>
<td class="alt2" nowrap="nowrap" style="padding:0px">
<!-- Your Stats [] Begin -->
<div class="smallfont"><b>Your Info:</b><br />User: <a href="member.php?{$session['sessionurl']}u={$bbuserinfo['userid']}" title="Go To Your Profile">{$bbuserinfo['username']}</a><br />
<a href="search.php?{$session['sessionurl']}do=getnew">New Posts</a>: {$welcome_new_posts['new_posts']}<br />New Threads: {$welcome_new_topics['new_topics']}<br />
<if condition="$show[pmstats]"><phrase 1="$vbphrase[unread_x_nav_compiled]" 2="$vbphrase[total_x_nav_compiled]" 3="$session[sessionurl]">$vbphrase[private_messages_nav]</phrase></if></div>
<!-- Your Stats [] End -->
<else />
<!-- Guest [] Begin -->
<!-- Avatar -->
<td class="alt1" valign="middle" align="center">
<a href="register.php?ID=&"><img src="http://www.tek-wiz.com/forums/images/avatars/guestavatar.gif" border="0"></a>
</td>
<!-- / Avatar -->
<td class="alt2" nowrap="nowrap" style="padding:0px">
<!-- login form -->
<form action="login.php" method="post" onsubmit="md5hash(vb_login_password,vb_login_md5password)">
<script type="text/javascript" src="clientscript/vbulletin_md5.js"></script>
<table cellpadding="0" cellspacing="3" border="0">
<tr>
<td class="smallfont">User Name</td>
<td><input type="text" class="button" name="vb_login_username" id="navbar_username" size="10" accesskey="u" tabindex="1" value="User Name" onfocus="if (this.value == 'User Name') this.value = '';" /></td>
</tr>
<tr>
<td class="smallfont">Password</td>
<td><input type="password" class="button" name="vb_login_password" size="10" accesskey="p" tabindex="2" /></td>
</tr>
<tr>
<td class="smallfont" colspan="2" nowrap="nowrap">
<label for="cb_cookieuser_navbar"><input type="checkbox" name="cookieuser" value="1" tabindex="3" id="cb_cookieuser_navbar" accesskey="c" checked="checked" />Remember Me?</label>
<input type="submit" class="button" value="Log in" tabindex="4" title="Enter your username and password in the boxes provided to login, or click the 'register' button to create a profile for yourself." accesskey="s" />
</td>
</tr>
</table>
<input type="hidden" name="ID" value="" />
<input type="hidden" name="s" value="" />
<input type="hidden" name="do" value="login" />
<input type="hidden" name="forceredirect" value="1" />
<input type="hidden" name="vb_login_md5password" />
</form>
<!-- / login form -->
</td>
<!-- Guest [] End --></if>
</td>
<td class="alt1" valign="top" nowrap="nowrap">
<!-- Forum Stats [] Begin -->
<td class="alt2" nowrap="nowrap" style="padding:3px">
<div class='smallfont'><b>Forum Stats:</b><br />Threads: $welcome_topics<br />Posts: $welcome_posts<br />Members: $welcome_members<br />
<if condition="THIS_SCRIPT == 'adv_index'">
Welcome to our newest member,
<a href="member.php?$session[sessionurl]u=$newuserid">$newusername</a>
<else />
<phrase 1="member.php?$session[sessionurl]u=$newuserid" 2="$newusername">$vbphrase[welcome_to_our_newest_member_x]</phrase>
</if></div>
<!-- Forum Stats [] End -->
</td>
<!-- Main Welcome Panel Block [] End -->
</tr>
</table>
<else />
Like I say the funny thing is that the first conditional seems to work but for me as admin only, any other registered users don't even see a red x empty pic block, it just doesn't even populate the table....I'm stumped..my permissions are ok as far as I can tell.
So guest avatars IE no avatar and not logged in = OK
Admin avatar = ok
Logged in but no avatar selected = OK on forum only
Logged in avatar selected = OK on forum only. :ermm:
FIXED: I had the code that's supposed to be in php includes start in global.php from the welcome panel hack, removing it from global.php let it work all nicey nicey!! THANKS AGAIN!!!