forms

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Shmuel

    forms

    How could I get the form fields filled from a database?

    One idea I have is to do a redirect, but it doesn't quite
    work because it ends to an infinite loop cause the page
    is redirecting to itself:

    header("Locatio n: " . $_SERVER['PHP_SELF'] .
    "?field1=someth ing&field2=some thing else");


    That would bee neet. I just would create a string from the contents
    I receive from the db and just redirect, but as I said, it doesn't
    work easily. You have to use the apache rewrite, but I didn't quite
    get it.

    Another solution is to check if the request is not empty for the
    particular field.

    Any other solutions?

    Shmuel.



  • Bob Smith

    #2
    Re: forms


    "Shmuel" <sdg@nic.fi> wrote in message
    news:4HWyc.2470 $851.1194@reade r1.news.jippii. net...[color=blue]
    > How could I get the form fields filled from a database?
    >
    > One idea I have is to do a redirect, but it doesn't quite
    > work because it ends to an infinite loop cause the page
    > is redirecting to itself:
    >
    > header("Locatio n: " . $_SERVER['PHP_SELF'] .
    > "?field1=someth ing&field2=some thing else");[/color]
    so write a php script that queries the database and returns/outputs a form
    on stdout, given the parameters.
    use $_GET['whatever--..'];
    etc...
    /G
    --

    [color=blue]
    >
    >
    > That would bee neet. I just would create a string from the contents
    > I receive from the db and just redirect, but as I said, it doesn't
    > work easily. You have to use the apache rewrite, but I didn't quite
    > get it.
    >
    > Another solution is to check if the request is not empty for the
    > particular field.
    >
    > Any other solutions?
    >
    > Shmuel.
    >
    >
    >[/color]


    Comment

    Working...