![]() |
Blank Profile Feild
I have a custom profile feild, (field6) that I use as an avatar feild. But if a user leaves it blank, I want it to revert to /images/clear.gif
Can anyone give me a hand? Or if its possible, just have $post[field6] return /images/clear.gif if null instead of checking at the control panel. |
easy
in fuctions.php find: PHP Code:
PHP Code:
just call $Avatar in the postbit |
Thanks very much ^_^
|
help anime!! I have this in my index.php for my welcome panel
Code:
if ($bbuserinfo[userid]!=0) { This is the code Im using now for the avatar thingie. Code:
if ($post[field6]) { |
try using bbuserinfo[$field6] or bbuserinfo[$aAvatar] in the template, i think thats right.
|
/me scratches her head, then takes another look at it
|
ooohhh, yay. Works. Thankies ^_^
|
You could also just as easily...
ALTER TABLE userfield DROP field6 ALTER TABLE userfield ADD field6 varchar(250) NOT NULL DEFAULT 'https://vborg.vbsupport.ru/images/clear.gif' or instead of the 'https://vborg.vbsupport.ru/images/clear.gif' as the defualt just add your own url to a certain img ;) g-force2k2 |
Quote:
that is true but i avoid editing the database whenever possible :) |
i like to play with the database quite alot... mysql and php are powerful combined for a reason ;) then again if you drop a query on accident then your in trouble :p
g-force2k2 |
All times are GMT. The time now is 07:00 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|