Anna's Mods :)

Forum
Last Post
Threads / Messages

redheadturkey

Member
Member
Joined
Jan 2, 2010
Messages
136
Points
0
Mysidian Dollar
7,059
This will be a thread where I share my new mods that I want to make avail for all :)

First is a mod to allow an image ( remotely hosted, you enter a url )for your profile ( I have one with an animated gif, so yes that works ^^ )


AVATAR MOD FOR PROFILE:



in account.php :

find:
PHP:
$query = "SELECT * FROM ".$prefix."users WHERE username='$loggedinname'";
$result = mysql_query($query);
$num = mysql_numrows($result);

//Loop out code
$i=0;
while ($i < 1) {

$newmessagenotify=@mysql_result($result,$i,"newmessagenotify"); 
$website=@mysql_result($result,$i,"website");
$aim=@mysql_result($result,$i,"aim");
$yahoo=@mysql_result($result,$i,"yahoo");
$msn=@mysql_result($result,$i,"msn");

right at the end add:

PHP:
$avatar=@mysql_result($result,$i,"avatar");


find:


PHP:
</p>
  <p>MSN Username: 
    <input name='msn' type='text' id='msn' value='".$msn."'>
    <input name='act' type='hidden' id='act' value='changesettings'>
</p>


right after add:

PHP:
<p>Avatar: 
     <input name='avatar' type='text' id='avatar' value='".$avatar."'>


</p>


In accountpost.php find:

PHP:
$website = $_POST["website"];
$website = secure($website);

$aim = $_POST["aim"];
$aim = secure($aim);

$yim = $_POST["yim"];
$yim = secure($yim);

$msn = $_POST["msn"];
$msn = secure($msn);

right at the end add:

PHP:
$avatar= $_POST["avatar"];
$avatar= secure($avatar);


then lower there:

PHP:
$query = "UPDATE ".$prefix."users SET yahoo='".$yim."' WHERE username='".$loggedinname."'";
mysql_query($query);

$query = "UPDATE ".$prefix."users SET msn='".$msn."' WHERE username='".$loggedinname."'";
mysql_query($query);

Add at the end:

PHP:
$query = "UPDATE ".$prefix."users SET avatar='".$avatar."' WHERE username='".$loggedinname."'";
mysql_query($query);


in profile.php find:

PHP:
$usersname=@mysql_result($result,$i,"username");
	$usergroup=@mysql_result($result,$i,"usergroup");
	$website=@mysql_result($result,$i,"website");
	$aim=@mysql_result($result,$i,"aim");
	$yahoo=@mysql_result($result,$i,"yahoo");
	$premium=@mysql_result($result,$i,"premium");
	$membersince=@mysql_result($result,$i,"membersince");
	$uid=@mysql_result($result,$i,"uid");

ADD at the end:

PHP:
    $avatar=@mysql_result($result,$i,"avatar");


Find :

PHP:
    $article_title = $userdisp."'s Profile:";
    $article_content = "<b><u>".$lang_basic_info."".$usersname.":</u></b><br><br>

ADD after that:

PHP:
        <img src='".$avatar."' border=0 width='200' height ='200><br>
           <p></p>


LAST thing!!

in SQL add to adopts_users a new field:

avatar varchar (120) utf8_general_ci NULL



I think that's all --- if not, let me know :) have fun and you can change the size allowed, etc !! I am not sure about how secure this is, so might want to either allow only certain members to do this--- or find a way to make it more secure -- that's something I am not sure how to do -- but you can do a lot with this!
 
Can you do this also in your functions.php ?
(more text for stupid limit x3;
-----------------------------------------------------------)
 
PokePets said:
Can you do this also in your functions.php ?
(more text for stupid limit x3;
-----------------------------------------------------------)


maybe...? not sure :)
 
This one looks really great, thanks for the amazing script Anna. ^^

Also I saw you registered on PokeMansion, and I appreciate that. XD
 
Hall of Famer said:
This one looks really great, thanks for the amazing script Anna. ^^

Also I saw you registered on PokeMansion, and I appreciate that. XD

You're very welcome! :)

And yes I intend to play a lot there, as soon as I get Pantheras and the new Kritter Kingdom going---- they are like thisclose, and I am looking to open them today, just had to add a few more pets for us

I'll post banners you can use to link. and Ill be making forums too that we can use to have our members join each others to support one another :)

Thanks for all the wonderful mods guys, they are all very appreciated!!!
 
redheadturkey said:
Hall of Famer said:
This one looks really great, thanks for the amazing script Anna. ^^

Also I saw you registered on PokeMansion, and I appreciate that. XD

You're very welcome! :)

And yes I intend to play a lot there, as soon as I get Pantheras and the new Kritter Kingdom going---- they are like thisclose, and I am looking to open them today, just had to add a few more pets for us

I'll post banners you can use to link. and Ill be making forums too that we can use to have our members join each others to support one another :)

Thanks for all the wonderful mods guys, they are all very appreciated!!!

Thanks for saying that Anna, I am glad you like it so far. Oh btw you were never on AIM/MSN before? XD
 
thanks!! We really do need more! :)


:D

And Pantheras is OPEN!! See the info on the Show Off section <3
 
So Anna you are still creating new mods for Rusnak Adoptables? Sounds great to me, and again dont you get on AIM/MSN? I'd like to chat sometime. ^^
 
Oh btw, I think you forgot to mention that the script file register.php needs to be modified too. This is usually the cause of error 'Something is very very wrong' upon user registration. XD
 
oh wonderful!! I am so happy you like it!! :)

Thanks HOF I missed that !!!
 
You are very welcome Anna. I've added your avatar mod to my site Pokemansion, it works perfectly fine. I will add it to the dev kit maybe later this afternoon, together with Gigi's extra profile fields. ^^
 
Oh that's great, I'm glad its working okay and will be added !! I'll get to work on developing more here this week too for us! :)
 
Well yeah, I may consider adding a settings in acp for admins to decide default avatar display size(yours is 200x200, I resized it to be 150x150 on Pokemansion). I have added avatar mod to Mys v1.2.0's dev kit, it works well so far. ^^
 

Similar threads

Users who are viewing this thread

  • Forum Contains New Posts
  • Forum Contains No New Posts

Forum statistics

Threads
4,274
Messages
33,115
Members
1,602
Latest member
BerrieMilk
BETA

Latest Threads

Latest Posts

Top