search

Home  >  Q&A  >  body text

Running the PHP file becomes a download

I use an integrated php environment (xampp)
What I write is a form submission php. A separate php can be opened (entered in the browser), but once submitted, it becomes a download. Please solve.

<form method="post" action="index2.php">

Username:<input type="text" name="usernmae"/>< br>
Password: <input type="password" name="password"/><br>
Verification code: <input type="text" name="code" size="5 "/>1234<br>
Email:<input type="text" name="email"><br>
Introduction:<textarea rows="6" cols="25" name="content"></textarea><br>
<input type="submit" name="send" value="Submit">

</form>

girlgirl2718 days ago1374

reply all(3)I'll reply

  • ringa_lee

    ringa_lee2017-08-15 13:21:02

    Your PHP environment may not be configured properly and there is no file with .php suffix running, so the browser does not know how to process .php.

    I will send you a txt text directly. Please change to a PHP integrated environment. phpstudy

    reply
    1
  • girl

    girl2017-08-15 11:41:39

    I am using the xmapp integrated environment, which has a port number, and when it is running

    reply
    0
  • ringa_lee

    Then send the index2.php file and take a look.

    ringa_lee · 2017-08-15 13:06:20
  • ringa_lee

    ringa_lee2017-08-15 11:18:23

    You just right-click and open it with the browser - -

    You need to use the port and protocol to run the program

    reply
    0
  • Cancelreply