Mysidia Adoptables Support Forum

Mysidia Adoptables Support Forum (http://www.mysidiaadoptables.com/forum/index.php)
-   Questions and Supports (http://www.mysidiaadoptables.com/forum/forumdisplay.php?f=18)
-   -   Add a new function in the myadopts page? (http://www.mysidiaadoptables.com/forum/showthread.php?t=4182)

Infernette 06-21-2013 12:58 PM

Add a new function in the myadopts page?
 
I wanted to edit in another function to the myadopts page (to go with the rename options and whatnot) but I noticed that simply just copying the rename function and changing the name causes an error, so what other pages/parts do I need to edit?

Also, I was wondering, how do we go about updating a part of an adopt (I see that it has "setName" and such in the rename function, but can that jut be changed to a field I want updated or do I have to find some workaround? Sometimes It can just be changed or sometimes it refuses.........)

I'm using this to try to update my public selling/buying mod that I had on my old site. :)

Hall of Famer 06-21-2013 07:35 PM

Umm did you just copy the rename method and change its name? What error message did you get exactly?

Infernette 06-24-2013 09:09 PM

That's pretty much what I did to see if It let me after I first changed a few things. It doesn't give an error message, just a blank page.

Hall of Famer 06-25-2013 01:04 PM

A blank page indicates that you have a syntax error. There is an easy way to debug though, but mind posting the method/function you created yourself here so I can help you out?

Infernette 06-25-2013 01:56 PM

Okay I figured out what was wrong! (good to know that those mean syntax now!) But I was wondering, how do you go about updating a part of an adopt. setName only works for name, and I can't use "setPrice" or just "price" to get it to update the price, so I was wondering how to go about it.

Infernette 06-30-2013 10:56 PM

Still need help with updating data in the adopts :)

Hall of Famer 07-01-2013 01:39 PM

I think you should be looking at the class_ownedadoptables.php file to see what methods are available for an owned adoptable. You probably need to write a database query script to update the price, as there is no shortcut method to accomplish this like setName($name).

Infernette 07-01-2013 08:04 PM

Thanks for pointing me in that direction! Just upgraded then entire selling system on my site, and without that info I never would have been able to :)

Hall of Famer 07-02-2013 12:12 PM

No problem, whats important is that you got it to work.^^


All times are GMT -5. The time now is 01:21 AM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.