Mysidia Adoptables Support Forum

Mysidia Adoptables Support Forum (http://www.mysidiaadoptables.com/forum/index.php)
-   Mys v1.1.x Mods (http://www.mysidiaadoptables.com/forum/forumdisplay.php?f=20)
-   -   Giving pets a Gender (http://www.mysidiaadoptables.com/forum/showthread.php?t=1148)

Arianna 12-25-2009 03:06 AM

RE: Giving pets a Gender
 
Look - I don't know what your table looks like and I don't know the complete code. Can I see a screenshot of your table, please?

bokkun 12-26-2009 12:15 PM

RE: Giving pets a Gender
 
Quote:

Originally Posted by SieghartZeke
Quote:

Originally Posted by tommyk1210
instead of your random number to select gender code, try this:

PHP Code:

<form id="form1" name="form1" method="post" action="">
  <
p>
    <
label>
    
Male:</label>
    <
label>
      <
input type="radio" name="Genderselect" value="male" id="Genderselect_0" />
    </
label>
    <
br />
    <
label>
    
Female:</label>
    <
label>
      <
input type="radio" name="Genderselect" value="female" id="Genderselect_1" />
    </
label>
    <
br />
  </
p>
</
form>

$gender $_GET[genderselect]; 


When i have puted this code in my page,i have get a error!
Why?

Sorry to meddle, but I know the problem
in that script you have things like this:
form id="form1"
"" shouldn't be used in this situation, replace all " with ' in that code
and $gender = $_GET[genderselect]; should be in doadopt.php

instead of that code try doing it this way:
go to adopt.php
look for the (original)
<form name='form1' method='get' action='doadopt.php'>
part and replace all between that and </form> with
PHP Code:

  <p>Adoptable Name
    <
input name='name' type='text' id='name'>
    <
input name='id' type='hidden' id='id' value='".$id."'>
    <
input name='promocode' type='hidden' id='promocode' value='".$promocode."'>
  </
p>
  <
p>
    <
label>
    
Male:</label>
    <
label>
      <
input type='radio' name='genderselect' value='male' id='genderselect' />
    </
label>
    <
label>
    
Female:</label>
    <
label>
      <
input type='radio' name='genderselect' value='female' id='genderselect' />
    </
label>
    <
br />
  </
p>
  <
p>
    <
input type='submit' name='Submit' value='Adopt Me'>
</
p

then go to doadopt.php
find where you had the random gender choose thing and replace it with
PHP Code:

//The gender mod
$gender $_GET[genderselect]; 

hope I helped you

SieghartZeke 12-27-2009 01:44 PM

RE: Giving pets a Gender
 
Uhm thank you but when i have finde dthat you can get different character from the breeding,i don't want use...

Roconza 01-20-2010 01:27 PM

RE: Giving pets a Gender
 
For some reason I keep getting a invalid id after adopting

SieghartZeke 01-20-2010 03:21 PM

RE: Giving pets a Gender
 
Same for me....

Roconza 01-22-2010 02:44 AM

RE: Giving pets a Gender
 
Ok, I see what I did wrong here, I inserted the gender field in the wrong on place in the database. I think I'll go for the random gender since you can change there name but I do wish I could get the abandon script.

If any one has a copy of it I'd be ever so grateful.

exdiogene 01-22-2010 10:53 AM

RE: Giving pets a Gender
 
Quote:

Originally Posted by Roconza
For some reason I keep getting a invalid id after adopting

What is the exact error message?

Roconza 01-22-2010 11:45 AM

RE: Giving pets a Gender
 
I already fixed it, it turned out to be a problem with the database. It was storing the gender in trading and not gender so I deleted it and added it back with the code above as the last table.

It's working beautifully and I decided I liked the random gender to make breeding challenging but I'm still missing a abandon script.


--------------------

Seapyramid 01-23-2010 12:11 AM

RE: Giving pets a Gender
 
Look at the kill & the rename & think about it.. from there it is easy to do an abandon :)

Roconza 01-23-2010 09:09 AM

RE: Giving pets a Gender
 
I have the table and the abandoned pets go to the database I just have to work out how to make them appear on a page and be claimable. I figure it would be like the adopt.php only with added code and and stuff changed to point to the database were the abandoned pets are stored. For some reason there also dumping in to the table with no image is that normal?


All times are GMT -5. The time now is 07:57 PM.

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