Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Config RSS Lines #11

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions conf/default.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<?php
/**
* @license GPL 2 (http://www.gnu.org/licenses/gpl.html)
*
* @author Florian Lamml <[email protected]>
*/

$conf['rsslines'] = '5'; // How many lines of rss
8 changes: 8 additions & 0 deletions conf/metadata.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<?php
/**
* @license GPL 2 (http://www.gnu.org/licenses/gpl.html)
*
* @author Florian Lamml <[email protected]>
*/

$meta['rsslines'] = array('string'); // How many lines of rss
2 changes: 1 addition & 1 deletion plugin.info.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
base rss
author Algorys
email [email protected]
date 2017-11-17
date 2021-07-20
name rss
desc display rss feed in your wiki

2 changes: 1 addition & 1 deletion syntax.php
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ function _render_rss($renderer, $data){
$renderer->doc .= '<h3>'.(string)$fluxrss->channel->title.'</h3>';
$renderer->doc .= '<p>'.(string)$fluxrss->channel->description.'</p>';
$i = 0;
$nb_to_display = 5;
$nb_to_display = $this->getConf('rsslines');
$renderer->doc .= '<ul>';
foreach($fluxrss->channel->item as $item) {
$renderer->doc .= '<li>';
Expand Down