1. Introducing PHP
Activity 1.1: Displaying Query Strings in the Browser
Solution
- Create a file named
movies.php
. - Capture query string data in the file to store the details of the movies, such as the name, the actors, and the release years:
<?php $name = $_GET['movieName']; $star = $_GET['movieStar']; $year = $_GET['movieYear']; ?>
- Create a basic HTML structure and then display the captured query strings:
movies.php
8 <head> 9 <meta charset="UTF-8"> 10 <meta name="viewport" content="width=device-width, initial-scale=1.0"> 11 <meta http-equiv="X-UA-Compatible" content="ie=edge"> 12 <title><?php echo ...