![]() |
Allow different spelling of names
If someone has the name Holly for an adopt, how can I make it so that another person can use HoLLy, or some other variation of the same name?
|
Not that I can answer this...but are users currently unable to give their pet the same name of another existing pet..?
|
If you have it set up that way which I do. And I think that it's default.
|
You can use strcmp() function to validate the name of an adoptable with another. This one is case sensitive, so Adopt and adopt are not the same.
|
Where do I place that at?
|
Place it where it validates adoptables name.
|
I tried this but I don't think it's correct as it didn't work.
Code:
else{ |
Of course its not correct lol. You dont know how to use the strcmp() function dont ya? It accepts two arguments, not one. The arguments have to be strings, not objects. Try this:
PHP Code:
|
Rawr, I'm not putting it in the right place :(
Code:
$name = $adopts->query("SELECT name FROM ".constant('PREFIX')."owned_adoptables WHERE name='{$more}'")->fetchColumn(); |
umm are you sure the query is executed correctly? I mean, do the variables $id and $more exist? If so, what values do they hold? Use var_dump($id) and var_dump($more) to validate their values. If one of them turns out to be blank or null, you know the problem.
|
All times are GMT -5. The time now is 07:19 AM. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.