What is the purpose of the formaction attribute in HTML5 and how does it relate to PHP form submissions?

The formaction attribute in HTML5 allows you to specify the URL of the file that will process the form data when the form is submitted. This attribute is particularly useful when you want to submit a form to a different file than the one specified in the form's action attribute. In PHP form submissions, the formaction attribute can be used to direct the form data to a specific PHP file for processing.

```php
<form action="process_form.php" method="post">
  <input type="text" name="username">
  <input type="submit" formaction="submit_form.php" value="Submit">
</form>
```

In this example, when the form is submitted, the data will be sent to "submit_form.php" instead of the default "process_form.php". This allows for more flexibility in handling form submissions with PHP.