gec5741 Posted June 15, 2006 Share Posted June 15, 2006 Ok. Here's what I want to do. Seems like it should be possible but not sure how to go about it.I run a guild website for my world of warcraft crowd. I'm running phpnuke 7.5. Now I'm using a thing called wowroster. roster website is www.wowroster.net. Now what the roster dose is allow players to upload there game information and all that good stuff. There is a part of the roster called siggen. What that does is creates a signature and avatar when a person uploads there information. You can use the avatar and or sig fairly easy enough with a little bit of know how. Unfortuatley alot of my users don't know how :) And I'd love to see the majority of users using these avatars (mainly becuase im anal and think it makes everything look better). So now we come to my issue that I prestent here...I'd like it so when someone new registers on the site they get assigned the default Avatar (I have that setup now) BUT, As soon as they upload there roster information and there roster avatar is created, there profile will know to use that avatar inplace of the defualt one. The siggen avatars are stored in a single directory on the server. I looked at using a "file exists" method but the problem is that when someone registes they will not have yet uploaded there roster profile, therefore the file (in this case the avatar) will never exist so it will alway's just use the default avatar anyway.If anyone can lend me a hand in making this work I would be greatly thankful. I'm still learning this code stuff :)Thanks for taking the time to read my post!Yours truley Shorty_K_Dahee Quote Link to comment https://forums.phpfreaks.com/topic/12077-kind-of-a-wierd-default-avatar-issue/ Share on other sites More sharing options...
jayR Posted June 15, 2006 Share Posted June 15, 2006 You could just put another field in your database (I'm assuming you're using a database) that is "uploaded" or something like that. Have it default to 0 and change it to 1 once they upload their avatar stuff, then you can point to where their avatar is stored...thats what I would do if I correctly understood your question. Quote Link to comment https://forums.phpfreaks.com/topic/12077-kind-of-a-wierd-default-avatar-issue/#findComment-45993 Share on other sites More sharing options...
gec5741 Posted June 15, 2006 Author Share Posted June 15, 2006 [!--quoteo(post=384276:date=Jun 15 2006, 12:08 PM:name=jayR)--][div class=\'quotetop\']QUOTE(jayR @ Jun 15 2006, 12:08 PM) [snapback]384276[/snapback][/div][div class=\'quotemain\'][!--quotec--]You could just put another field in your database (I'm assuming you're using a database) that is "uploaded" or something like that. Have it default to 0 and change it to 1 once they upload their avatar stuff, then you can point to where their avatar is stored...thats what I would do if I correctly understood your question.[/quote]Thank you for your response. I'm not sure axactly how to go about all this. i'm still pretty new. But yes I do have a sql database that runs all this. here is some code that a freind of mine wrote to maybe do what im trying to do. However it is not complete. I don't know exactly how to make it work with the database. See if this makes any sence to you?/ // This mod will check a Nuke CMS for a blank.gif as the user's current avatar. If found, replaces it with their saved SigGen avatar. // // Read user's current avatar from Database $ava_str = "SELECT `user_avatar` FROM `nuke_users` WHERE username = '$member_name' LIMIT 1;"; $ava_sql = $wowdb->query($ava_str); if( $ava_sql ) { print '<span style="color: #FDFF1F;">Guest Avatar replaced for ['.$member_name."]</span><br />\n"; print $ava_sql; }Thanks again for any help you can provide. I'm still learning. Quote Link to comment https://forums.phpfreaks.com/topic/12077-kind-of-a-wierd-default-avatar-issue/#findComment-46092 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.