mirror of
https://github.com/e107inc/e107.git
synced 2025-08-01 20:30:39 +02:00
Download search template fix.
This commit is contained in:
@@ -34,7 +34,7 @@ if (!e107::isInstalled('download'))
|
|||||||
if(deftrue('BOOTSTRAP'))
|
if(deftrue('BOOTSTRAP'))
|
||||||
{
|
{
|
||||||
define("IMAGE_DOWNLOAD", (file_exists(THEME."images/download.png") ? THEME."images/download.png" : e_IMAGE."generic/download.png"));
|
define("IMAGE_DOWNLOAD", (file_exists(THEME."images/download.png") ? THEME."images/download.png" : e_IMAGE."generic/download.png"));
|
||||||
define("IMAGE_NEW", (file_exists(THEME."images/new.png") ? THEME."images/new.png" : e107::getParser()->toGlyph('icon-star',false)));
|
define("IMAGE_NEW", (file_exists(THEME."images/new.png") ? THEME."images/new.png" : 'icon-star.glyph'));
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@@ -867,12 +867,30 @@ class download_shortcodes extends e_shortcode
|
|||||||
|
|
||||||
function sc_download_cat_search()
|
function sc_download_cat_search()
|
||||||
{
|
{
|
||||||
return "<form class='form-search' method='get' action='".e_BASE."search.php'>
|
$text = "<form class='form-search form-inline' method='get' action='".e_BASE."search.php'>";
|
||||||
<p>
|
$text .= '<div><div class="input-group">';
|
||||||
<input class='tbox search-query' type='text' name='q' size='30' value='' placeholder=\"".LAN_dl_41."\" maxlength='50' />
|
$text .= "<input class='tbox form-control search-query' type='text' name='q' size='30' value='' placeholder=\"".LAN_dl_41."\" maxlength='50' />
|
||||||
<input class='btn btn-primary button' type='submit' name='s' value='".LAN_GO."' />
|
<input type='hidden' name='r' value='0' />
|
||||||
|
<input type='hidden' name='t' value='downloads' />
|
||||||
|
";
|
||||||
|
|
||||||
|
$text .= '
|
||||||
|
<span class="input-group-btn">
|
||||||
|
<button class="btn btn-default" type="submit" name="s" value="1">
|
||||||
|
<span class="glyphicon glyphicon-search"></span>
|
||||||
|
</button>
|
||||||
|
</span>
|
||||||
|
</div><!-- /input-group -->
|
||||||
|
</div></form>';
|
||||||
|
|
||||||
|
return $text;
|
||||||
|
|
||||||
|
return "<form class='form-search form-inline' method='get' action='".e_BASE."search.php'>
|
||||||
|
<div class='input-group'>
|
||||||
|
<input class='tbox form-control search-query' type='text' name='q' size='30' value='' placeholder=\"".LAN_dl_41."\" maxlength='50' />
|
||||||
|
<button class='btn btn-primary button' type='submit' name='s' value='1' />".LAN_GO."</button>
|
||||||
<input type='hidden' name='r' value='0' />
|
<input type='hidden' name='r' value='0' />
|
||||||
</p>
|
</div>
|
||||||
</form>";
|
</form>";
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -906,12 +924,14 @@ class download_shortcodes extends e_shortcode
|
|||||||
|
|
||||||
private function renderNewIcon()
|
private function renderNewIcon()
|
||||||
{
|
{
|
||||||
if(strstr(IMAGE_NEW,'<i '))
|
if(strstr(IMAGE_NEW,'<i ') || strstr(IMAGE_NEW,'<span'))
|
||||||
{
|
{
|
||||||
return IMAGE_NEW;
|
return IMAGE_NEW;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
return e107::getParser()->toIcon(IMAGE_NEW);
|
||||||
|
|
||||||
return "<img src='".IMAGE_NEW."' alt='*' style='vertical-align:middle' />";
|
// return "<img src='".IMAGE_NEW."' alt='*' style='vertical-align:middle' />";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
?>
|
?>
|
Reference in New Issue
Block a user