#1
  1. No Profile Picture
    -------------------
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jun 2000
    Posts
    200
    Rep Power
    15
    Does anyone know if PHP can be used to simulate a form POST?

    I'ld like to forward the user to a url using the header function. Right now, I can only figure out how to have this work, simulating the GET method:

    Header("Location: /page.php?user=Steve&zip=02118");

    Is there anyway to pass this info as a POST (where the string is invisible in the URL)??

    Thanks,
    Dave


  2. #2
  3. .Net Developer
    Devshed Novice (500 - 999 posts)

    Join Date
    Feb 2000
    Location
    London
    Posts
    987
    Rep Power
    15
    No ,

    You can't do that.

    If you want to pass the informations with URL,then you will have to pass those values to some variables like above.




    ------------------
    SR -
    shiju.dreamcenter.net

    "The fear of the LORD is the beginning of knowledge..."

    [This message has been edited by Shiju Rajan (edited June 11, 2000).]
  4. #3
  5. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    May 2000
    Posts
    27
    Rep Power
    0
    YES
    there is a way

    <INPUT TYPE='HIDDEN' NAME='your_var_name' VALUE='the_value'>
    <meta http-equiv="refresh" content="0; url=your.url">
  6. #4
  7. .Net Developer
    Devshed Novice (500 - 999 posts)

    Join Date
    Feb 2000
    Location
    London
    Posts
    987
    Rep Power
    15

    <INPUT TYPE='HIDDEN' NAME='your_var_name' VALUE='the_value'>
    <meta http-equiv="refresh" content="0; url=your.url">


    wouterr,
    In this case you will have to submit this information(ie, form submission).Other wise it won't be carrying informations to php program.


    ------------------
    SR -
    shiju.dreamcenter.net

    "The fear of the LORD is the beginning of knowledge..."

    [This message has been edited by Shiju Rajan (edited June 12, 2000).]
  8. #5
  9. No Profile Picture
    -------------------
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jun 2000
    Posts
    200
    Rep Power
    15
    <INPUT TYPE='HIDDEN' NAME='your_var_name' VALUE='the_value'>
    <meta http-equiv="refresh" content="0; url=your.url">

    This wouldn't work...What I'm looking for is a way that a form can get posted to a php page, have that php page perform some functions (adding info to a database) and forward the user's information (via POST) to another page (at another domain)

    Thanks,
    Dave

Similar Threads

  1. Passing values via POST method
    By jenda in forum PHP Development
    Replies: 6
    Last Post: February 20th, 2004, 05:52 PM
  2. Method Post not allowed
    By jwalsh in forum Windows Help
    Replies: 0
    Last Post: January 31st, 2004, 11:59 AM
  3. PHP : send XML message use Post method ?
    By sampah95 in forum PHP Development
    Replies: 0
    Last Post: January 27th, 2004, 11:10 AM
  4. POST method not working in PHP.
    By coremah in forum PHP Development
    Replies: 4
    Last Post: January 26th, 2004, 04:32 PM
  5. HTTP Error 400: Bad Request, with basic form
    By crackwombat in forum PHP Development
    Replies: 1
    Last Post: January 23rd, 2004, 07:40 PM

IMN logo majestic logo threadwatch logo seochat tools logo