<p class="m_text" align="middle"> <?php switch ($choice) { case 'feed': $amount = $_POST['range']; if ($amount <= $thisPok->getFoodNum()) { $thisPok->setFood($amount); } print "<br />You have successfully fed the pokemon XD<br /><br />"; print "<div class=\"btn_form\" align=\"middle\"><form>"; print "<input type=\"button\" align=\"middle\" value=\"Yeah!!\" onclick=\"window.open('', '_self', ''); window.close();\" />"; print "</form></div>"; break; case 'marry': $MarriageID = $_POST['marry']; $thisPok->marry($MarriageID); print "<br />You have successfully send out the engagement XD<br /><br />"; print "<div class=\"btn_form\" align=\"middle\"><form>"; print "<input type=\"button\" align=\"middle\" value=\"Yeah!!\" onclick=\"window.open('', '_self', ''); window.close();\" />"; print "</form></div>"; break; case 'work': if (!isset($_SESSION['WorkStart'])) { $WorkID = $_POST['work']; $thisPok->setWork($WorkID); $timeSpentWork = 0; } else { $timeSpentWork = time() - $_SESSION['WorkStart']; } print "<br />You have successfully send the pokemon to work XD<br />"; print "Do not close the window while your pokemon is working. <br /> Working progress:";