Merge branch '0.7.x' of git@gitorious.org:laconica/dev into 0.7.x
This commit is contained in:
commit
26b0bc3aab
|
@ -78,6 +78,62 @@ class NoticesearchAction extends SearchAction
|
|||
return _('Text search');
|
||||
}
|
||||
|
||||
|
||||
function showExportData()
|
||||
{
|
||||
$q = $this->trimmed('q');
|
||||
if (!$q) {
|
||||
return;
|
||||
}
|
||||
$fl = new FeedList($this);
|
||||
$fl->show(array(0 => array('href' => common_local_url('noticesearchrss', array('q' => $q)),
|
||||
'type' => 'rss',
|
||||
'version' => 'RSS 1.0',
|
||||
'item' => 'noticesearchrss')));
|
||||
}
|
||||
|
||||
|
||||
|
||||
function showFeeds()
|
||||
{
|
||||
$q = $this->trimmed('q');
|
||||
if (!$q) {
|
||||
return;
|
||||
}
|
||||
|
||||
$this->element('link', array('rel' => 'alternate',
|
||||
'href' => common_local_url('noticesearchrss',
|
||||
array('q' => $q)),
|
||||
'type' => 'application/rss+xml',
|
||||
'title' => _('Search Stream Feed')));
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Show header
|
||||
*
|
||||
* @param array $arr array containing the query
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
|
||||
function extraHead2()
|
||||
{
|
||||
$q = $this->trimmed('q');
|
||||
if ($q) {
|
||||
$this->element('link', array('rel' => 'alternate',
|
||||
'href' => common_local_url('noticesearchrss',
|
||||
array('q' => $q)),
|
||||
'type' => 'application/rss+xml',
|
||||
'title' => _('Search Stream Feed')));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Show results
|
||||
*
|
||||
|
@ -119,26 +175,6 @@ class NoticesearchAction extends SearchAction
|
|||
$page, 'noticesearch', array('q' => $q));
|
||||
}
|
||||
|
||||
/**
|
||||
* Show header
|
||||
*
|
||||
* @param array $arr array containing the query
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
|
||||
function extraHead()
|
||||
{
|
||||
$q = $this->trimmed('q');
|
||||
if ($q) {
|
||||
$this->element('link', array('rel' => 'alternate',
|
||||
'href' => common_local_url('noticesearchrss',
|
||||
array('q' => $q)),
|
||||
'type' => 'application/rss+xml',
|
||||
'title' => _('Search Stream Feed')));
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Show notice
|
||||
*
|
||||
|
|
|
@ -112,6 +112,13 @@ class FeedList extends Widget
|
|||
$feed['textContent'] = "Atom";
|
||||
break;
|
||||
|
||||
case 'noticesearchrss':
|
||||
$feed_classname = $feed['type'];
|
||||
$feed_mimetype = "application/".$feed['type']."+xml";
|
||||
$feed_title = $feed['version']." feed for this notice search";
|
||||
$feed['textContent'] = "RSS";
|
||||
break;
|
||||
|
||||
case 'tagrss':
|
||||
$feed_classname = $feed['type'];
|
||||
$feed_mimetype = "application/".$feed['type']."+xml";
|
||||
|
|
Loading…
Reference in New Issue
Block a user