-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathfunctions3.php
More file actions
46 lines (38 loc) · 786 Bytes
/
functions3.php
File metadata and controls
46 lines (38 loc) · 786 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
<?
$movieTitle = "Top Gun";
function displayCredits( $myMovieTitle, $actorName )
{
//global $movieTitle;
print( "Now showing: <span class=\"movie\">{$myMovieTitle}</span><br>" );
print( "Staring: <span class='actor'>{$actorName}</span> <br>" );
}
?>
<!DOCTYPE html>
<html>
<head>
<title></title>
<style>
.movie
{
color: green;
}
.actor
{
font-family: Verdana;
color: blue;
}
</style>
</head>
<body>
<h2>My Favorite Movies</h2>
<?
displayCredits( $movieTitle, "Tom Cruise" );
displayCredits( "Singles", "Campbell Scott" );
?>
<script>
alert( "thanks for using our movie app!" );
</script>
<button id="getMyActors">Get My Actors</button>
<div>(c) BAVC PHP Class 2018</div>
</body>
</html>