-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathindex.php
50 lines (36 loc) · 843 Bytes
/
index.php
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
47
48
49
50
<?php
// passing value to varible directly
// You can need to change this value with youtube video ID,
$yid = $_GET['id'];
if(!isset($yid)) {
$yid = 'lF-jPBnZ098'; // we added this line for demo purpose, if you don't pass any value to variable
}
// calling class
require_once('class.php');
// Creating object
$object = new ytiframe();
// Calling Class
$response = $object->generate($yid);
?>
<html>
<head>
<title>YouTube To Mp3 Iframe Widgets</title>
<style>
div.error {
border: 2px solid #ccc!important;
border-radius: 16px;
padding: 0.01em 10px;
}
</style>
</head>
<body>
<?php
// IFRAME EMBED CODE
if(isset($yid)&&($response)) {
echo "You Iframe Embed code:<br/>";
echo $response; // This variable contains iframe code
echo "<br/>";
}
?>
</body>
</html>