For what it is worth, it does not seem that there is a universal vBcode or replacement variable for a user's avatar as of this writing. I did however write a complete hack that allows this to work with either custom or pre-defined avatars and it works flawlessly.
Unfortunately vBulletin.org is not allowing vb3 hacks at this time, so we're pretty much screwed as far as me sharing it with anyone.
I did post a question on vBulletin.com to see if the devs have hidden a globally accessible vBcode or replacement variable that we can call instead, but no replies yet.
Both problems can be solved with some added code to the phpinclude_start template, and calling the correct image path via a variable.
The only problem I can see with doing this is that anything added to the 'phpinclude_start' template becomes overhead for all vBulletin pages from that point forward.
A welcome panel really only needs to have it's relevant code called when the 'index.php' page is generated -- which is why I opted to do what you're talking about but made it an actual hack of the index.php code.
My hack consists of a modification of ogden2k's template, three new templates to represent the avatar, custom avatar and no avatar possible states and some code added right before the end of index.php.
Works great! But, again... no way to share it since VB.org has taken the stance that they have on prohibiting VB3 hacks until a final version is released.
Eh... would rather not deviate from the "accepted" channels. VB.org has safeguards in place to keep non-licensed users from getting hold of hacks and such.
I have this fixed as a working TEMPLATE ONLY modification. It's significantly different than the one Odgen2k posted so I made a new thread, but I do give credit to him and Brad.loo in the post and in the text file.
Yes there is a problem with overhead, but we are not talking about running queries here.
There are tricks to working with the phpinclude without adding much overhead on the server. Define what page the code should run on with a if statement, and dont use custom templates.
Check out filburt1's artical on the phpinclude template, its in the vB 2 mod forums
There are tricks to working with the phpinclude without adding much overhead on the server. Define what page the code should run on with a if statement, and dont use custom templates.
Will check into that. Not sure how I could work around the custom templates, however, since that is what provides part of the flexibility in my modification release. Same general idea that Jelsoft used when they constructed the vB3 user control panel screens dealing with avatars.
I'm too much of a PHP newbie at this point. It's all starting to give me a headache.