-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtest.php
More file actions
56 lines (44 loc) · 1.45 KB
/
Copy pathtest.php
File metadata and controls
56 lines (44 loc) · 1.45 KB
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
54
55
56
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" >
<title>Canvas - CyCal</title>
<link href="css/reset.css" rel="stylesheet" type="text/css">
<link href="css/mainstyle.css" rel="stylesheet" type="text/css">
<link href="js/css/jquery-ui.css" rel="stylesheet" type="text/css">
<script type="text/javascript" src="js/jquery-1.6.2.min.js"></script>
<script type="text/javascript" src="js/jquery-ui.min.js"></script>
<?php
//Must be included inside the Header (at bottom)
include 'includes/topbar_header.php';
require "includes/simple_html_dom.php";
?>
</head>
<body>
<?php
//Must be included at the top of the <body> tag
include 'includes/topbar.php';
// $html = @file_get_contents("http://www.event.iastate.edu/rssgen.php?featured=1");
// if($html === false)
// errorMessage('Invalid RSS Feed: '.$value);
// foreach($html->find('content') as $element)
// echo $element->href . '<br>';
// if($title != true || $des != true || $link != true){
// echo"Not valid RSS";
// }
$html = file_get_html('http://xkcd.com/rss.xml');
$good = null;
$rss = $html->find('rss',0);
if($rss != null){
$chan = $html->find('rss',0)->find('channel',0);
if($chan != null){
$good = true;
}
}
if($good == null){
echo"Not valid RSS";
}
//->find('channel',0)->find('title', 0)->plaintext;
?>
<p>Content here!</p>
</body>
</html>