... | ... |
@@ -3,8 +3,9 @@ |
3 | 3 |
// http://simplehtmldom.sourceforge.net/ |
4 | 4 |
include "lib/simple_html_dom.php"; |
5 | 5 |
|
6 |
-$url = "http://media.daum.net/cp/11?page=1®Date=20171111"; |
|
6 |
+$url = "https://hiseon.me"; |
|
7 | 7 |
|
8 |
+// HTML 객체 생성 |
|
8 | 9 |
$html = file_get_html($url); |
9 | 10 |
|
10 | 11 |
foreach($html->find('a') as $a) { |
1 | 1 |
new file mode 100644 |
... | ... |
@@ -0,0 +1,14 @@ |
1 |
+<?php |
|
2 |
+ |
|
3 |
+// http://simplehtmldom.sourceforge.net/ |
|
4 |
+include "lib/simple_html_dom.php"; |
|
5 |
+ |
|
6 |
+$url = "http://media.daum.net/cp/11?page=1®Date=20171111"; |
|
7 |
+ |
|
8 |
+$html = file_get_html($url); |
|
9 |
+ |
|
10 |
+foreach($html->find('a') as $a) { |
|
11 |
+ echo $a->href. "\n"; |
|
12 |
+} |
|
13 |
+ |
|
14 |
+?> |