-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathserver.php
More file actions
55 lines (31 loc) · 780 Bytes
/
server.php
File metadata and controls
55 lines (31 loc) · 780 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
47
48
49
50
51
52
53
<head>
<link rel="stylesheet" href="/bootstrap.css">
</head>
<body>
<?php
include('simple_html_dom.php');
$url = $_GET['url'];
//
//
$html = file_get_html($url);
foreach($html->find('meta') as $e){
if($e->property == "og:title"){
$title = $e->content;
}
}
// Channel Icon
foreach($html->find('meta') as $e){
if($e->property == "og:image"){
$icon = $e->content;
//echo "<b>Post Icon : <b> <img src='".$image. "' /></br>";
}
}
// ==== Subscribed ===
foreach($html->find('div') as $e){
$subscribe = $e->innertext;
$sub = htmlspecialchars($subscribe);
//echo "<b>Post Icon : <b> <img src='".$image. "' /></br>";
}
echo "<img class='container col-5' src='".$icon."' style='height: 200px; margin-top: 50px' >";
echo "<h1>". $title ."</h1></br>";
?>