fixing indentation on FrandroidBridge
This commit is contained in:
parent
401663aac0
commit
14af7d93ba
1 changed files with 59 additions and 52 deletions
|
@ -9,16 +9,20 @@
|
||||||
* @description Returns the 5 newest posts from Frandroid (full text)
|
* @description Returns the 5 newest posts from Frandroid (full text)
|
||||||
* @maintainer cjohnson
|
* @maintainer cjohnson
|
||||||
*/
|
*/
|
||||||
class FrandroidBridge extends BridgeAbstract{
|
class FrandroidBridge extends BridgeAbstract
|
||||||
|
{
|
||||||
|
|
||||||
public function collectData(array $param){
|
public function collectData(array $param)
|
||||||
|
{
|
||||||
|
|
||||||
function FrandroidStripCDATA($string) {
|
function FrandroidStripCDATA($string)
|
||||||
|
{
|
||||||
$string = str_replace('<![CDATA[', '', $string);
|
$string = str_replace('<![CDATA[', '', $string);
|
||||||
$string = str_replace(']]>', '', $string);
|
$string = str_replace(']]>', '', $string);
|
||||||
return $string;
|
return $string;
|
||||||
}
|
}
|
||||||
function FrandroidExtractContent($url) {
|
function FrandroidExtractContent($url)
|
||||||
|
{
|
||||||
$html2 = file_get_html($url);
|
$html2 = file_get_html($url);
|
||||||
$html3 = $html2->find('div.post-content', 0);
|
$html3 = $html2->find('div.post-content', 0);
|
||||||
$html3->find('div.no-sidebar-ad-top', 0)->outertext = '';
|
$html3->find('div.no-sidebar-ad-top', 0)->outertext = '';
|
||||||
|
@ -49,15 +53,18 @@ class FrandroidBridge extends BridgeAbstract{
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getName(){
|
public function getName()
|
||||||
|
{
|
||||||
return 'Frandroid';
|
return 'Frandroid';
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getURI(){
|
public function getURI()
|
||||||
|
{
|
||||||
return 'http://www.frandroid.com/';
|
return 'http://www.frandroid.com/';
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getCacheDuration(){
|
public function getCacheDuration()
|
||||||
|
{
|
||||||
return 300; // 5min
|
return 300; // 5min
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue