Edit No Name ??[Answered]

Forum
Last Post
Threads / Messages

gjac1

Member
Member
Joined
Feb 18, 2009
Messages
101
Points
0
Mysidian Dollar
5,256
If a member chooses not to name there adoptable when adopting it, the script will just name it what name to creator gave it.

Is there any way to change it so that if a member adopts something but doesnt name it, it give it a defualt name of something like "Egg" ??

Thanks
 
RE: Edit No Name ??

In my install, it automatically gives it the name of the pet species, if there isn't a name inputted. I guess you could add, on the doadopt, something, but I'm too busy now. xD Good luck.
 
RE: Edit No Name ??

Thanks for the reply Arianna :)

In my install it also give it the name of the species, but thats what i want to change, if no name is inputted i want it to be called something like "Egg" instead of the species.

Thanks again
 
RE: Edit No Name ??

On your doadopt.php it should contain a section of code that says if the name is ' ' (blank) the name = type of adoptable, like this:

PHP:
// First we see if we have a custom name.
// If not, we use the default name

if($name == ""){
$name = $type;
}

I think you could just change $type; to "egg"; and it would work?
 
RE: Edit No Name ??

alright in your doadopt.php file around line 129 is this:
PHP:
if($name == ""){
$name = $type;
}


You should change $type to whatever you want
Example:
PHP:
if($name == ""){
$name = "Egg";
}
You need the "" in order for it to work :D cheers let me know if this helps!

Haylzee said:
On your doadopt.php it should contain a section of code that says if the name is ' ' (blank) the name = type of adoptable, like this:

PHP:
// First we see if we have a custom name.
// If not, we use the default name

if($name == ""){
$name = $type;
}

I think you could just change $type; to "egg"; and it would work?

Yay for posting at the same time basicly :) lol
 
RE: Edit No Name ??

I am sure i tried this and it didnt work...but it worked perfectly, thank you both :)

I think i might have missed out the "" around the word egg :s
 

Similar threads

Users who are viewing this thread

  • Forum Contains New Posts
  • Forum Contains No New Posts

Forum statistics

Threads
4,280
Messages
33,132
Members
1,603
Latest member
Monako
BETA

Latest Threads

Top