Suddenly all my images and stylesheet running on PHP55 Standard Environment Google App Engine
are broken. They show similar issues to this:
PHP Parse error: syntax error, unexpected 'Y9gG??' (T_STRING) in /base/data/home/apps/f~streamplate-landingpage-228223/early-access:20190201t232344.41581292385049
Here's my app.yaml file:
runtime: php55
service: early-access
api_version: 1
threadsafe: true
handlers:
- url: /(.+\.php)$
script: www/\1
- url: /
script: www/index.html
This was working fine and then suddenly - after changing some PHP code that I've now reverted back to previous/working state - the images and CSS don't load!
This is my PHP code:
<?php
if(isset($_POST['email'])){
$dsn = getenv('MYSQL_DSN');
$user = getenv('MYSQL_USER');
$password = getenv('MYSQL_PASSWORD');
$pdo = new PDO($dsn, $user, $password);
$email = $_POST['email'];
$sql = "INSERT INTO emails (`email`) VALUES ('$email')";
$stmt = $pdo->query($sql);
header('Location: index.html');
exit();
}
?>
Any help would be greatly appreciated! Thanks :)