creating php form

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • lolodede
    New Member
    • Apr 2009
    • 63

    #16
    its undefined custID when i submit the third page

    Comment

    • Ciary
      Recognized Expert New Member
      • Apr 2009
      • 247

      #17
      ah ok then you have to edit this line i think:
      Code:
      <input type="hidden" value="<?php echo $custID; ?>"/>
      to this
      Code:
      <input type="hidden" id="cusID" name="cusID" value="<?php echo $cusID; ?>"/>
      after this you can get its value using $_GET['cusID']

      Comment

      • lolodede
        New Member
        • Apr 2009
        • 63

        #18
        sorry but im really confused more its should be working but not it doest i try wat did u said and it doesnt work same error again and again

        Comment

        • Ciary
          Recognized Expert New Member
          • Apr 2009
          • 247

          #19
          on what line do you get the error and in which file (second or third)?

          Comment

          • lolodede
            New Member
            • Apr 2009
            • 63

            #20
            the third page when i submit it and if i put ur line into my code there are more errors like undefined cusID before submit and after submit it to task10.php on that page appear undefined error of custID line 12 which is line get

            Comment

            • Ciary
              Recognized Expert New Member
              • Apr 2009
              • 247

              #21
              ok i think i know where the problem is. try changing every cusID you can find to custID. do this in all three files

              Comment

              • lolodede
                New Member
                • Apr 2009
                • 63

                #22
                i did this and receive this message Undefined index: custID in task10.php on line 12

                Comment

                • Ciary
                  Recognized Expert New Member
                  • Apr 2009
                  • 247

                  #23
                  can you post the code of task10.php? since you changed a few things i dont know what line 12 is anymore :)

                  EDIT: just to verify, try putting the next code as first line:
                  Code:
                  <?php if($_SERVER["REQUEST_METHOD"] == "GET"){?>
                  and this code at the end of the file:
                  Code:
                  <?php }else{echo "ERROR!!";}?>
                  what do you see now?

                  Comment

                  • luckysanj
                    New Member
                    • May 2009
                    • 68

                    #24
                    How accordingly sir....how..... i have clear that i have three database tables like tbl_a, tbl_b, tbl_c & which have corresponding fields a_id,a_name,b_i d,b_name,c_id,c _name. In php page there 3 text box for different table input inside on HTML form. I need to input these three tex box value to different table on database tbl_a,tbl_b,tbl _c. so plz give me idea.don't give me confusen answer..if u don't understand my problem then tell me clearly in which part r u not able to understand. plz
                    Ur help will be appreciated...

                    Comment

                    • Ciary
                      Recognized Expert New Member
                      • Apr 2009
                      • 247

                      #25
                      to luckysanj: you've already asked this on a different thread. the answer is given there. all you need to do is post your form and write one SQL query for each table in which you want to insert/update a record.

                      also this thread is ment to answer lolodede's question. so only questions or answers linked to his/her question may be posted here.

                      please read the posting guidelines

                      Comment

                      • luckysanj
                        New Member
                        • May 2009
                        • 68

                        #26
                        Ok sorry for my mistake to post on other thread.

                        Comment

                        Working...