Jump to content

jwk811

Members
  • Posts

    714
  • Joined

  • Last visited

    Never

Everything posted by jwk811

  1. yes that was what i was looking for lol thank you
  2. i know theres a way but i just forget. i want to do a switch function. switch ($_GET['page']) { case 0: include 'page'; break; case 1: include 'page1'; break; case 2: include 'page2'; break; default: include 'page'; } ?> just like that but if there is no $_GET page i just want it to do the default. instead of doing if isset GET page do switch else default page. i just want it to be simpler by doing something like switch(isset$_GET etc.
  3. ok at least i know im not crazy lol. i use godaddy. ill ask them about it but i doubt they will be able to do anything. maybe i should just change servers. any suggestions?
  4. i tried what you said. it shows the array. it shows the array with the data SOMETIMES just like it did with the form. this is absouletly crazy. someone please try it out yourself. put data in the text field and submit it. it works. then go back refresh form do it again. tell me if it doesnt work sometimes. and also on page 2. resend data. once resent it usually doesnt show data. http://frozenasfs.com/form/formp1.php i even tried it on two different website servers. and this is all thats on each page exactly. formp1.php <form method="post" action="formp2.php"> <input type="text" name="text" id="text"> <input type="submit"> </form> formp2.php <?php if (isset($_POST)){ var_dump ($_POST); }else{ echo "No POST data!"; }?>
  5. this is so frustrating. i know my coding isnt wrong. the most basic form doesnt even work (always). formp1.php <form method="post" action="formp2.php"> <input type="text" name="text" id="text"> <input type="submit"> </form> formp2.php <?php echo $_POST['text']; ?> heres the thing it works SOMETIMES. i send the form and it shows. i go back and do it again and it doesnt. another time it shows another time it doesnt. all the same text input to. i put the number 1. what could possibly do this? its not my browser i tried 2 different browsers. it makes no sense what so ever someone give me something PLEASE
  6. i made a quick example of the problem im having. at step 5 i dont get the data for some reason. and its weird because when i resend the data it usually works by clicking refresh page. is very frustrating and makes no sense. please help <?php if(!isset($_GET['step'])){ ?> <form method="post" action="form.php?step=2"> <input type="text" name="text" id="text"> <input type="submit"> </form> <?php } else if($_GET['step'] == 2){ ?> <form method="post" action="form.php?step=3"> <input type="hidden" name="text" id="text" value="<?php echo $_POST['text']; ?>"> <input type="text" name="text2" id="text2"> <input type="submit"> </form> <?php } else if($_GET['step'] == 3){ ?> <form method="post" action="form.php?step=4"> <input type="hidden" name="text" id="text" value="<?php echo $_POST['text']; ?>"> <input type="hidden" name="text2" id="text2" value="<?php echo $_POST['text2']; ?>"> <input type="text" name="text3" id="text3"> <input type="submit"> </form> <?php } else if($_GET['step'] == 4){ ?> <form method="post" action="form.php?step=5"> <input type="hidden" name="text" id="text" value="<?php echo $_POST['text']; ?>"> <input type="hidden" name="text2" id="text2" value="<?php echo $_POST['text2']; ?>"> <input type="hidden" name="text3" id="text3" value="<?php echo $_POST['text3']; ?>"> <input type="text" name="text4" id="text4"> <input type="submit"> </form> <?php } else if($_GET['step'] == 5){ echo $_POST['text']; echo $_POST['text2']; echo $_POST['text3']; echo $_POST['text4']; } ?>
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.