Question: I am trying follow this tutorial: <https://html.form.guide/email-form/php-form-to-email/> to deploy a simple php script to google App Engine. I want to load the form from localhost and post to the app engine link. When I do, the `$_POST` is empty. Is this an issue when posting from another server/localhost to an app-engine hosted service?

Code:

app.yaml:

```
runtime: php55
api_version: 1
threadsafe: true

handlers:
- url: .*
script: formemailer.php

```

php script:

```
<?php
if(!isset($_POST['submit']))
{
    echo "error; you need to submit the form!";
}
?>

```

Form:

```
<form method="post" action="https://<url>.appspot.com/formemailer.php">
    <p>
        <label for='name'>Enter Name: </label><br>
        <input type="text" name="name">
    </p>
    <input type="submit" name="submit" value="submit" />
</form>

```

Answer: 
> 
> Is this an issue when posting from another server/localhost to an app-engine hosted service?
> 
> 
> 

No, the server receives the POST request as it is send.

And yes, as you have an issue doing so.

---

It should work, but what to do now?

Verify with the networking tools in your browser what is actually send to the server. This might already give you some more insights.

The networking tools are nowadays with your browser, please see:

* Chrome (or Chromium, Vivaldi etc.): [Inspect network activity](https://developer.chrome.com/docs/devtools/network/)
* Firefox: [Network Monitor](https://developer.mozilla.org/en-US/docs/Tools/Network_Monitor)

or the documentation of your browser.

---

For a PHP 5 application running on *Google App Engine* you can find a dedicated tutorial handling form input at:

* [Handling User Input in Forms](https://cloud.google.com/appengine/docs/standard/php/getting-started/handling-user-input-in-forms)

However *strongly* recommended is (not only on App Engine but in general) to use the PHP 7 runtime. This *should* be independent to your problem, however better start with PHP 7 from the beginning (if you allow me this comment).

The general information (also for PHP 5 and 7) is available here:

* [How Requests are Handled](https://cloud.google.com/appengine/docs/standard/php/how-requests-are-handled)

If you would like to learn about how PHP in general handles this, independent to any platform, you can find it outlined in the PHP manual here:

* [Dealing with Forms](https://www.php.net/manual/en/tutorial.forms.php)
* [Variables From External Sources](https://www.php.net/manual/en/language.variables.external.php)

For the general handling in browsers for what you ask for - the form on one host (or even a HTML file locally) posting to another host, please see this related Q/A:

* [Cross Domain Form POSTing](https://stackoverflow.com/q/11423682/367456)
appspot.com has been the host to a lot of fishing attacks. It is likely blocked as a safety issue.