projects
/
tweeper.git
/ commitdiff
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d01598c
)
Make get_contents() a static method
author
Antonio Ospite <ospite@studenti.unina.it>
Sun, 11 Aug 2013 19:11:03 +0000
(21:11 +0200)
committer
Antonio Ospite <ospite@studenti.unina.it>
Sun, 11 Aug 2013 23:21:44 +0000
(
01:21
+0200)
tweeper.php
patch
|
blob
|
history
diff --git
a/tweeper.php
b/tweeper.php
index
74e9e2f
..
6cdf8cf
100644
(file)
--- a/
tweeper.php
+++ b/
tweeper.php
@@
-105,7
+105,7
@@
class Tweeper {
$this->xsltProcessor->importStylesheet($xslDoc);
}
- private function get_contents($uri) {
+ private
static
function get_contents($uri) {
# https://www.wjsams.com/c/docs/Wiki/Php-HowToSetUserAgentOnFileGetContents
$opts = array(
'http' => array(
@@
-123,7
+123,7
@@
class Tweeper {
}
public function tweep($uri) {
- $html =
$this->
get_contents($uri);
+ $html =
Tweeper::
get_contents($uri);
$xmlDoc = new DOMDocument();
$xmlDoc->loadHTML($html);