1
0
mirror of https://github.com/e107inc/e107.git synced 2025-07-31 20:00:37 +02:00

Issue #3559, Fixes #3589, Issue #2982, Issue #2927 Replace all glyphicons with FontAwesome.

This commit is contained in:
Cameron
2019-02-22 14:56:47 -08:00
parent 9e6c2a79f0
commit 5dc45298f6
16 changed files with 45 additions and 45 deletions

View File

@@ -2209,12 +2209,12 @@ function libraryGetStatus($details)
if($details['installed'] == true)
{
$icon = $tp->toGlyph('glyphicon-ok');
$icon = $tp->toGlyph('fa-check');
$text = LAN_OK;
return '<span class="text-success" data-toggle="tooltip" data-placement="top" title="' . $text . '">' . $icon . '</span>';
}
$icon = $tp->toGlyph('glyphicon-remove');
$icon = $tp->toGlyph('fa-remove');
$text = $details['error'];
return '<span class="text-danger" data-toggle="tooltip" data-placement="top" title="' . $text . '">' . $icon . '</span>';
}

View File

@@ -2758,7 +2758,7 @@ class users_admin_form_ui extends e_admin_form_ui
$btn = '<div class="btn-group pull-right">
<button aria-expanded="false" class="btn btn-default btn-secondary btn-user-action dropdown-toggle" data-toggle="dropdown">
<span class="user-action-indicators" id="user-action-indicator-'.$user_id.'">'.e107::getParser()->toGlyph('cog').'</span>
<span class="user-action-indicators" id="user-action-indicator-'.$user_id.'">'.e107::getParser()->toGlyph('fa-cog').'</span>
<span class="caret"></span>
</button>
<ul class="dropdown-menu">

View File

@@ -572,7 +572,7 @@ class news_shortcodes extends e_shortcode
{
//TODO - discuss - a pref for 'new browser window' loading, or a parm or leave 'new browser window' as default?
$default = (deftrue('BOOTSTRAP')) ? $tp->toGlyph('icon-edit',false) : "<img src='".e_IMAGE_ABS."admin_images/edit_16.png' alt=\"".LAN_EDIT."\" class='icon' />";
$default = (deftrue('BOOTSTRAP')) ? $tp->toGlyph('fa-edit',false) : "<img src='".e_IMAGE_ABS."admin_images/edit_16.png' alt=\"".LAN_EDIT."\" class='icon' />";
$adop_icon = (file_exists(THEME."images/newsedit.png") ? "<img src='".THEME_ABS."images/newsedit.png' alt=\"".LAN_EDIT."\" class='icon' />" : $default);

View File

@@ -302,41 +302,41 @@ function sc_user_email($parm='')
switch ($parm)
{
case 'email':
return ($boot) ? $tp->toGlyph('envelope') : $this->sc_user_email_icon();
return ($boot) ? $tp->toGlyph('fa-envelope') : $this->sc_user_email_icon();
break;
case 'lastvisit':
return ($boot) ? $tp->toGlyph('time') : '';
return ($boot) ? $tp->toGlyph('fa fa-clock-o') : '';
break;
case 'birthday':
return ($boot) ? $tp->toGlyph('calendar') : $this->sc_user_birthday_icon();
return ($boot) ? $tp->toGlyph('fa-calendar') : $this->sc_user_birthday_icon();
break;
case 'level':
return ($boot) ? $tp->toGlyph('signal') : '';
return ($boot) ? $tp->toGlyph('fa-signal') : '';
break;
case 'website':
return ($boot) ? $tp->toGlyph('home') : '';
return ($boot) ? $tp->toGlyph('fa-home') : '';
break;
case 'location':
return ($boot) ? $tp->toGlyph('map-marker') : '';
return ($boot) ? $tp->toGlyph('fa-map-marker') : '';
break;
case 'icq':
return ($boot) ? $tp->toGlyph('comment') : '';
return ($boot) ? $tp->toGlyph('fa-comment') : '';
break;
case 'msn':
return ($boot) ? $tp->toGlyph('comment') : '';
return ($boot) ? $tp->toGlyph('fa-comment') : '';
break;
default:
case 'realname':
case 'user':
return ($boot) ? $tp->toGlyph('user') : $this->sc_user_realname_icon();
return ($boot) ? $tp->toGlyph('fa-user') : $this->sc_user_realname_icon();
break;
}
@@ -593,7 +593,7 @@ function sc_user_email($parm='')
if($parm == 'prev')
{
$icon = (deftrue('BOOTSTRAP')) ? $tp->toGlyph('chevron-left') : '&lt;&lt;';
$icon = (deftrue('BOOTSTRAP')) ? $tp->toGlyph('fa-chevron-left') : '&lt;&lt;';
return isset($userjump['prev']['id']) ? "<a class='e-tip' href='".$url->create('user/profile/view', $userjump['prev']) ."' title=\"".$userjump['prev']['name']."\">".$icon." ".LAN_USER_40."</a>\n" : "&nbsp;";
// return isset($userjump['prev']['id']) ? "&lt;&lt; ".LAN_USER_40." [ <a href='".$url->create('user/profile/view', $userjump['prev'])."'>".$userjump['prev']['name']."</a> ]" : "&nbsp;";
@@ -601,7 +601,7 @@ function sc_user_email($parm='')
}
else
{
$icon = (deftrue('BOOTSTRAP')) ? $tp->toGlyph('chevron-right') : '&gt;&gt;';
$icon = (deftrue('BOOTSTRAP')) ? $tp->toGlyph('fa-chevron-right') : '&gt;&gt;';
return isset($userjump['next']['id']) ? "<a class='e-tip' href='".$url->create('user/profile/view', $userjump['next'])."' title=\"".$userjump['next']['name']."\">".LAN_USER_41." ".$icon."</a>\n" : "&nbsp;";
// return isset($userjump['next']['id']) ? "[ <a href='".$url->create('user/profile/view', $userjump['next'])."'>".$userjump['next']['name']."</a> ] ".LAN_USER_41." &gt;&gt;" : "&nbsp;";
}

View File

@@ -2194,10 +2194,10 @@ class e107
public static function css($type, $data, $dep = null, $media = 'all', $preComment = '', $postComment = '', $dependence = null)
{
if((strpos($data,'bootstrap.css')!==false || strpos($data,'bootstrap.min.css')!==false) && !defined("BOOTSTRAP")) // detect bootstrap is enabled. - used in nextprev.sc and forum currently.
/* if((strpos($data,'bootstrap.css')!==false || strpos($data,'bootstrap.min.css')!==false) && !defined("BOOTSTRAP")) // detect bootstrap is enabled. - used in nextprev.sc and forum currently.
{
define("BOOTSTRAP", true);
}
}*/
if(self::$_css_enabled === false)
{

View File

@@ -60,7 +60,7 @@ class emailprint
if(deftrue('BOOTSTRAP'))
{
$genericMail = $tp->toGlyph('icon-envelope',false); // "<i class='icon-envelope'></i>";
$genericMail = $tp->toGlyph('fa-envelope',false); // "<i class='icon-envelope'></i>";
$genericPrint = $tp->toGlyph('fa-print',false); // "<i class='icon-print'></i>";
$class = varset($parm['class']) ? $parm['class'] : "";
}

View File

@@ -380,8 +380,8 @@ class rater
if(deftrue('BOOTSTRAP'))
{
$upImg = $tp->toGlyph('icon-thumbs-up',false); // "<i class='icon-thumbs-up'></i>";
$upDown = $tp->toGlyph('icon-thumbs-down',false); // "<i class='icon-thumbs-down'></i>";
$upImg = $tp->toGlyph('fa-thumbs-up',false); // "<i class='icon-thumbs-up'></i>";
$upDown = $tp->toGlyph('fa-thumbs-down',false); // "<i class='icon-thumbs-down'></i>";
}
$text = "<span id='{$id}-up'>".intval($curVal['up'])."{$p}</span>

View File

@@ -1063,7 +1063,7 @@ class user_class
*/
public function ucGetClassIDFromName($name)
{
return $this->getId($name);
return $this->getID($name);
}

View File

@@ -53,7 +53,7 @@ If you find the menus are not updating correctly, clicking the refresh button be
".$frm->admin_button('reset','Refresh','cancel')."</div>
</form>
[br]
".e107::getParser()->toGlyph('search')." indicates that the menu's visibility has been modified.
".e107::getParser()->toGlyph('fa-search')." indicates that the menu's visibility has been modified.
[/html]
";

View File

@@ -415,7 +415,7 @@ class download_shortcodes extends e_shortcode
if(deftrue('BOOTSTRAP'))
{
$img = e107::getParser()->toGlyph('icon-download.glyph',false);
$img = e107::getParser()->toGlyph('fa-download',false);
// $img = '<i class="icon-download"></i>';
}
@@ -704,7 +704,7 @@ class download_shortcodes extends e_shortcode
if(deftrue('BOOTSTRAP'))
{
$img = e107::getParser()->toGlyph('download',$parm); // '<i class="icon-download"></i>';
$img = e107::getParser()->toGlyph('fa-download',$parm); // '<i class="icon-download"></i>';
}
if ($pref['agree_flag'] == 1)
@@ -955,7 +955,7 @@ class download_shortcodes extends e_shortcode
$url = e107::url('download', 'item', $dlrowrow);
$icon = (deftrue('BOOTSTRAP')) ? $tp->toGlyph('chevron-left') : '&lt;&lt;';
$icon = (deftrue('BOOTSTRAP')) ? $tp->toGlyph('fa-chevron-left') : '&lt;&lt;';
return "<a class='e-tip' href='".$url ."' title=\"".$dlrowrow['download_name']."\">".$icon." ".LAN_PREVIOUS."</a>\n";
@@ -982,7 +982,7 @@ class download_shortcodes extends e_shortcode
extract($dlrowrow);
$url = $url = e107::url('download', 'item', $dlrowrow);
$icon = (deftrue('BOOTSTRAP')) ? $tp->toGlyph('chevron-right') : '&gt;&gt;';
$icon = (deftrue('BOOTSTRAP')) ? $tp->toGlyph('fa-chevron-right') : '&gt;&gt;';
return "<a class='e-tip' href='".$url."' title=\"".$dlrowrow['download_name']."\">".LAN_NEXT." ".$icon."</a>\n";

View File

@@ -1003,10 +1003,10 @@ function fadminoptions($thread_info)
$lan = array('stick'=>LAN_FORUM_8007,'unstick'=>LAN_FORUM_8008,'lock'=>LAN_FORUM_8009, 'unlock'=>LAN_FORUM_8010);
$icon = array(
'unstick' => $tp->toGlyph('chevron-down'),
'stick' => $tp->toGlyph('chevron-up'),
'lock' => $tp->toGlyph('lock'),
'unlock' => $tp->toGlyph('unlock'),
'unstick' => $tp->toGlyph('fa-chevron-down'),
'stick' => $tp->toGlyph('fa-chevron-up'),
'lock' => $tp->toGlyph('fa-lock'),
'unlock' => $tp->toGlyph('fa-unlock'),
);

View File

@@ -838,14 +838,14 @@
<ul class="dropdown-menu pull-right text-right">';
$text .= "<li class='text-right'><a href='" . e_HTTP . "email.php?plugin:forum." . $this->postInfo['post_thread'] . "'>" . LAN_FORUM_2044 . " " . $tp->toGlyph('envelope') . "</a></li>";
$text .= "<li class='text-right'><a href='" . e_HTTP . "print.php?plugin:forum." . $this->postInfo['post_thread'] . "'>" . LAN_FORUM_2045 . " " . $tp->toGlyph('print') . "</a></li>"; // FIXME
$text .= "<li class='text-right'><a href='" . e_HTTP . "email.php?plugin:forum." . $this->postInfo['post_thread'] . "'>" . LAN_FORUM_2044 . " " . $tp->toGlyph('fa-envelope') . "</a></li>";
$text .= "<li class='text-right'><a href='" . e_HTTP . "print.php?plugin:forum." . $this->postInfo['post_thread'] . "'>" . LAN_FORUM_2045 . " " . $tp->toGlyph('fa-print') . "</a></li>"; // FIXME
if(USER) // Report
{
$urlReport = e107::url('forum', 'post') . "?f=report&amp;id=" . $this->postInfo['post_thread'] . "&amp;post=" . $this->postInfo['post_id'];
// $urlReport = $this->e107->url->create('forum/thread/report', "id={$this->postInfo['post_thread']}&post={$this->postInfo['post_id']}");
$text .= "<li class='text-right'><a href='" . $urlReport . "'>" . LAN_FORUM_2046 . " " . $tp->toGlyph('flag') . "</a></li>";
$text .= "<li class='text-right'><a href='" . $urlReport . "'>" . LAN_FORUM_2046 . " " . $tp->toGlyph('fa-flag') . "</a></li>";
}
// Edit
@@ -855,7 +855,7 @@
$url = e107::url('forum', 'post') . "?f=edit&amp;id=" . $this->postInfo['post_thread'] . "&amp;post=" . $this->postInfo['post_id'];
//$url = e107::getUrl()->create('forum/thread/edit', array('id' => $this->postInfo['post_thread'], 'post'=>$this->postInfo['post_id']));
$text .= "<li class='text-right'><a href='" . $url . "'>" . LAN_EDIT . " " . $tp->toGlyph('edit') . "</a></li>";
$text .= "<li class='text-right'><a href='" . $url . "'>" . LAN_EDIT . " " . $tp->toGlyph('fa-edit') . "</a></li>";
}
@@ -866,7 +866,7 @@
* AND if this post is the last post in the thread */
if($this->thread->threadInfo['thread_active'] && empty($this->postInfo['thread_start']) )
{
$text .= "<li class='text-right'><a href='" . e_REQUEST_URI . "' data-forum-action='deletepost' data-forum-post='" . $this->postInfo['post_id'] . "'>" . LAN_DELETE . " " . $tp->toGlyph('trash') . "</a></li>";
$text .= "<li class='text-right'><a href='" . e_REQUEST_URI . "' data-forum-action='deletepost' data-forum-post='" . $this->postInfo['post_id'] . "'>" . LAN_DELETE . " " . $tp->toGlyph('fa-trash') . "</a></li>";
}
}
@@ -874,7 +874,7 @@
{
$url = e107::url('forum', 'post') . "?f=quote&amp;id=" . $this->postInfo['post_thread'] . "&amp;post=" . $this->postInfo['post_id'];
//$url = e107::getUrl()->create('forum/thread/quote', array('id' => $this->postInfo['post_thread'], 'post'=>$this->postInfo['post_id']));
$text .= "<li class='text-right'><a href='" . $url . "'>" . LAN_FORUM_2041 . " " . $tp->toGlyph('share-alt') . "</a></li>";
$text .= "<li class='text-right'><a href='" . $url . "'>" . LAN_FORUM_2041 . " " . $tp->toGlyph('fa-share-alt') . "</a></li>";
// $text .= "<li class='text-right'><a href='".e107::getUrl()->create('forum/thread/quote', array('id' => $this->postInfo['post_id']))."'>".LAN_FORUM_2041." ".$tp->toGlyph('share-alt')."</a></li>";
}
@@ -893,24 +893,24 @@
$url = e107::url('forum', 'post') . "?f=edit&amp;id=" . $this->postInfo['post_thread'] . "&amp;post=" . $this->postInfo['post_id'];
// $url = e107::getUrl()->create('forum/thread/edit', array('id' => $this->postInfo['post_thread'], 'post'=>$this->postInfo['post_id']));
$text .= "<li class='text-right'><a href='" . $url . "'>" . LAN_EDIT . " " . $tp->toGlyph('edit') . "</a></li>";
$text .= "<li class='text-right'><a href='" . $url . "'>" . LAN_EDIT . " " . $tp->toGlyph('fa-edit') . "</a></li>";
}
// only show delete button when post is not the initial post of the topic
// if(!$this->forum->threadDetermineInitialPost($this->postInfo['post_id']))
if(empty($this->postInfo['thread_start']))
{
$text .= "<li class='text-right'><a href='" . e_REQUEST_URI . "' data-forum-action='deletepost' data-forum-post='" . $this->postInfo['post_id'] . "'>" . LAN_DELETE . " " . $tp->toGlyph('trash') . "</a></li>";
$text .= "<li class='text-right'><a href='" . e_REQUEST_URI . "' data-forum-action='deletepost' data-forum-post='" . $this->postInfo['post_id'] . "'>" . LAN_DELETE . " " . $tp->toGlyph('fa-trash') . "</a></li>";
}
if($type == 'thread')
{
$url = e107::url('forum', 'move', array('thread_id' => $this->postInfo['post_thread']));
$text .= "<li class='text-right'><a href='" . $url . "'>" . LAN_FORUM_2042 . " " . $tp->toGlyph('move') . "</a></li>";
$text .= "<li class='text-right'><a href='" . $url . "'>" . LAN_FORUM_2042 . " " . $tp->toGlyph('fa-arrows') . "</a></li>";
}
elseif(e_DEVELOPER === true) //TODO
{
$text .= "<li class='text-right'><a href='" . e107::url('forum', 'split', array('thread_id' => $this->postInfo['post_thread'], 'post_id' => $this->postInfo['post_id'])) . "'>" . LAN_FORUM_2043 . " " . $tp->toGlyph('cut') . "</a></li>";
$text .= "<li class='text-right'><a href='" . e107::url('forum', 'split', array('thread_id' => $this->postInfo['post_thread'], 'post_id' => $this->postInfo['post_id'])) . "'>" . LAN_FORUM_2043 . " " . $tp->toGlyph('fa-cut') . "</a></li>";
}
}

View File

@@ -407,7 +407,7 @@ class rssCreate
header('Content-type: application/xml', TRUE);
$rss_title = $tp->toRss($tp->toHtml($pref['sitename'],'','defs')." : ".$tp->toHtml($rss_title,'','defs'));
$rss_title = $tp->toRss($tp->toHTML($pref['sitename'],'','defs')." : ".$tp->toHTML($rss_title,'','defs'));
$rss_namespace = ($this->rssNamespace) ? "xmlns:".$this->rssNamespace : '';
$rss_custom_channel = ($this->rssCustomChannel) ? $this->rssCustomChannel : '';
$time = time();
@@ -466,7 +466,7 @@ class rssCreate
<link>".$pref['siteurl']."</link>
<description>".$tp->toRss($pref['sitedescription'])."</description>\n";
echo $tp->toHtml($rss_custom_channel,FALSE)."\n"; // must not convert to CDATA.
echo $tp->toHTML($rss_custom_channel,FALSE)."\n"; // must not convert to CDATA.
echo "
<language>".CORE_LC.(defined("CORE_LC2") ? "-".CORE_LC2 : "")."</language>

View File

@@ -78,7 +78,7 @@ if(deftrue('BOOTSTRAP'))
$text .= '
<span class="input-group-btn">
<button class="btn btn-default btn-secondary" type="submit" name="s">'.$tp->toGlyph('search').'</button>
<button class="btn btn-default btn-secondary" type="submit" name="s">'.$tp->toGlyph('fa-search').'</button>
</span>
</div>
</form>';

View File

@@ -162,7 +162,7 @@ class search extends e_shortcode
$text = "<div class='input-group'>
<input class='tbox form-control m_search' type='text' id='q' name='q' size='35' value='".$value."' maxlength='50' />
<div class='input-group-btn'>
<button class='btn btn-primary' type='submit' name='s' value='1' >".$tp->toGlyph('search',false)."</button>
<button class='btn btn-primary' type='submit' name='s' value='1' >".$tp->toGlyph('fa-search',false)."</button>
<button class='btn btn-primary dropdown-toggle' tabindex='-1' data-toggle='dropdown' type='button'><span class='caret'></span></button>
";