Mysidia Adoptables Support Forum  

Home Community Mys-Script Creative Off-Topic
Go Back   Mysidia Adoptables Support Forum > Mysidia Adoptables > Addons and Modifications > Mys v1.3.x Mods

Notices

Reply
 
Thread Tools Display Modes
  #1  
Old 07-01-2016, 08:33 AM
Abronsyth's Avatar
Abronsyth Abronsyth is offline
A Headache Embodied
 
Join Date: Aug 2011
Location: NY
Posts: 1,011
Gender: Male
Credits: 111,668
Abronsyth is on a distinguished road
Default Easy Change User Cash

This is an extremely simple mod that will enable you to change a user's cash amount in the Admin Control Panel. There are just two pieces of code that will need to be implemented.

admincp/user.php
In this file you'll want to go down to around line 52 or so, where you'll see this;
PHP Code:
$mysidia->db->update("users", array("email" => $mysidia->input->post("email")), "uid='{$mysidia->input->get("uid")}'"); 
Right below that, just add this in:
PHP Code:
$mysidia->db->update("users", array("money" => $mysidia->input->post("money")), "uid='{$mysidia->input->get("uid")}'"); 
admincp/view/userview.php
In this file you'll want to go down to find public function edit, and then find where this chunk of code is (lines 53-54 for me):
PHP Code:
->buildCheckBox(" Email the user the new password (Only takes effect if setting a new password) ""emailpwchange""yes")
                     ->
buildComment("Change Email Address: "FALSE)->buildTextField("email"$user->getemail()) 
Right below that add in this;
PHP Code:
->buildComment("Currency: "FALSE)->buildTextField("money"$user->money
So now when you go into your ACP to edit a user you can now edit their cash amount, and it will show you how much they currently have!
__________________
My Mods Site (1.3.4, 2020 Mods)
Reply With Quote
  #2  
Old 09-02-2016, 08:03 AM
parayna's Avatar
parayna parayna is offline
Member
 
Join Date: May 2013
Location: Devon, UK
Posts: 342
Gender: Female
Credits: 16,087
parayna is on a distinguished road
Default

Oh, wow, this is incredibly useful o.O Thanks! I shall totally use this when I get around to adding in features XD
Reply With Quote
  #3  
Old 07-16-2020, 01:01 AM
Micolai's Avatar
Micolai Micolai is offline
Loving Mysidia!
 
Join Date: May 2020
Location: Tennessee
Posts: 130
Gender: Female
Credits: 26,498
Micolai is on a distinguished road
Default

Thanks so much!
__________________
"You try you fail, you try you fail, but the only true failure is if you stop trying. So try again." - Haunted Mansion
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -5. The time now is 08:52 AM.

Currently Active Users: 447 (0 members and 447 guests)
Threads: 4,080, Posts: 32,024, Members: 2,016
Welcome to our newest members, jolob.
BETA





What's New?

What's Hot?

What's Popular?


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
vBCommerce I v2.0.0 Gold ©2010, PixelFX Studios
vBCredits I v2.0.0 Gold ©2010, PixelFX Studios
Emoticons by darkmoon3636