diff --git a/e107_admin/auth.php b/e107_admin/auth.php
index c40890362..0286f4d3e 100644
--- a/e107_admin/auth.php
+++ b/e107_admin/auth.php
@@ -36,6 +36,12 @@ if($core->get('admintheme') != 'bootstrap3')
 	$core->save();	
 	e107::getRedirect()->redirect(e_SELF);		
 }
+if($core->get('admincss') === 'admin_dark.css' || $core->get('admincss') === 'admin_light.css')
+{
+	$core->update('admincss','css/bootstrap-dark.min.css');
+	$core->save();
+	e107::getRedirect()->redirect(e_SELF);	;
+}
 
 // Check Admin-Perms for current language and redirect if necessary. 
 if(USER && !getperms('0') && vartrue($pref['multilanguage']) && !getperms(e_LANGUAGE) && empty($_E107['no_language_perm_check']))
diff --git a/e107_admin/eurl.php b/e107_admin/eurl.php
index 80595e2a6..0c95fcbae 100644
--- a/e107_admin/eurl.php
+++ b/e107_admin/eurl.php
@@ -760,7 +760,7 @@ class eurl_admin_form_ui extends e_admin_form_ui
 			$text .= "
                 <tr>
                     <td>".$this->moreInfo($title, $info)."</td>
-                    <td><select name='eurl_config[$module]' class='input-block-level'>".$opt."</select></td>
+                    <td><select name='eurl_config[$module]' class='form-control input-block-level'>".$opt."</select></td>
                     <td>";
 		
 			$bTable = ($admin['generate']['table']);
diff --git a/e107_admin/header.php b/e107_admin/header.php
index a6ee16982..8eb8535fd 100644
--- a/e107_admin/header.php
+++ b/e107_admin/header.php
@@ -227,6 +227,7 @@ else // backend css.
 	}
 
 		//NEW - Iframe mod
+		/*
 	if(!deftrue('e_IFRAME') && !empty($pref['admincss']))
 	{
 		$css_file = file_exists(THEME.'admin_'.$pref['admincss']) ? 'admin_'.$pref['admincss'] : $pref['admincss'];
@@ -245,7 +246,7 @@ else // backend css.
 		$css_file = (file_exists(THEME.'admin_style.css')) ? 'admin_style.css' : 'style.css';
 		//echo "<link rel='stylesheet' href='".$css_file."' type='text/css' />\n";
 		$e_js->themeCSS($css_file);
-	}
+	}*/
 
 
 
diff --git a/e107_admin/prefs.php b/e107_admin/prefs.php
index 2b4c12d03..14830aac1 100644
--- a/e107_admin/prefs.php
+++ b/e107_admin/prefs.php
@@ -453,7 +453,7 @@ $text .= "<fieldset class='e-hideme' id='core-prefs-email'>
 					<tr>
 						<td><label for='testaddress'>".LAN_MAILOUT_110."</label><br /></td>
 						<td class='form-inline'>".$frm->admin_button('testemail', LAN_MAILOUT_112,'other')."&nbsp;
-							<input name='testaddress' id='testaddress' class='tbox' placeholder='user@yoursite.com' type='text' size='40' maxlength='80' value=\"".(varset($_POST['testaddress']) ? $_POST['testaddress'] : USEREMAIL)."\" />
+							<input name='testaddress' id='testaddress' class='tbox form-control input-xxlarge' placeholder='user@yoursite.com' type='text' size='40' maxlength='80' value=\"".(varset($_POST['testaddress']) ? $_POST['testaddress'] : USEREMAIL)."\" />
 						</td>
 					</tr>
 		
@@ -739,7 +739,7 @@ $text .= "
 					<tr>
 						<td><label for='timezone'>".PRFLAN_56."</label></td>
 						<td>
-							".$frm->select('timezone', $timeZones, vartrue($pref['timezone'], 'UTC'))."
+							".$frm->select('timezone', $timeZones, vartrue($pref['timezone'], 'UTC'),'size=xlarge')."
 						</td>
 					</tr>
 				</tbody>
diff --git a/e107_admin/search.php b/e107_admin/search.php
index a78f55659..da0c337b8 100644
--- a/e107_admin/search.php
+++ b/e107_admin/search.php
@@ -385,7 +385,7 @@ else
 							<td>".$value."</td>
 							<td class='center'>".r_userclass("core_handlers[".$key."][class]", $search_prefs['core_handlers'][$key]['class'], "off", "public,guest,nobody,member,admin,classes")."</td>
 							<td class='center'>
-								<select name='core_handlers[".$key."][order]' class='tbox order'>
+								<select name='core_handlers[".$key."][order]' class='tbox order form-control input-small'>
 		";
 		for($a = 1; $a <= $handlers_total; $a++) {
 			$text .= ($search_prefs['core_handlers'][$key]['order'] == $a) ? "<option value='".$a."' selected='selected'>".$a."</option>" : "<option value='".$a."'>".$a."</option>";
@@ -438,7 +438,7 @@ else
 							<td>".$search_info[0]['qtype'] . "</td>
 							<td class='center'>".r_userclass("plug_handlers[".$plug_dir."][class]", $search_prefs['plug_handlers'][$plug_dir]['class'], "off", "public,guest,nobody,member,admin,classes")."</td>
 							<td class='center'>
-								<select name='plug_handlers[".$plug_dir."][order]' class='tbox order'>
+								<select name='plug_handlers[".$plug_dir."][order]' class='form-control input-small order'>
 		";
 		for($a = 1; $a <= $handlers_total; $a++)
 		 {
diff --git a/e107_core/shortcodes/batch/admin_shortcodes.php b/e107_core/shortcodes/batch/admin_shortcodes.php
index 287614cec..55e1314ce 100644
--- a/e107_core/shortcodes/batch/admin_shortcodes.php
+++ b/e107_core/shortcodes/batch/admin_shortcodes.php
@@ -711,7 +711,7 @@ class admin_shortcodes
 	{
 		if(e_DEBUG !== false)
 		{
-			return "<div class='navbar-right navbar-text admin-icon-debug' title='DEBUG MODE ACTIVE'>".e107::getParser()->toGlyph('fa-bug')."&nbsp;</div>";
+			return "<div class='navbar-right navbar-text admin-icon-debug' title='DEBUG MODE ACTIVE'>".e107::getParser()->toGlyph('fa-bug', array('class'=>'text-warning'))."&nbsp;</div>";
 		}
 
 	}
diff --git a/e107_handlers/e107_class.php b/e107_handlers/e107_class.php
index 243db8511..45ff72db4 100644
--- a/e107_handlers/e107_class.php
+++ b/e107_handlers/e107_class.php
@@ -2060,6 +2060,11 @@ class e107
 		
 		$jshandler = self::getJs();
 		$jshandler->setDependency($dep);
+
+		if(strpos($data,'http:')===0)
+		{
+			$type = 'url';
+		}
 		
 		switch ($type) 
 		{
diff --git a/e107_handlers/e_parse_class.php b/e107_handlers/e_parse_class.php
index 563e6c7bb..7e1b09d78 100644
--- a/e107_handlers/e_parse_class.php
+++ b/e107_handlers/e_parse_class.php
@@ -3702,8 +3702,9 @@ class e_parser
 
 		$idAtt = (!empty($parm['id'])) ? "id='".$parm['id']."' " : '';
 		$style = (!empty($parm['style'])) ? "style='".$parm['style']."' " : '';
+		$class = (!empty($parm['class'])) ? $parm['class']." " : '';
 		
-		$text = "<".$tag." {$idAtt}class='".$prefix.$id.$size.$spin.$rotate.$fixedW."' {$style}></".$tag.">" ;
+		$text = "<".$tag." {$idAtt}class='".$class.$prefix.$id.$size.$spin.$rotate.$fixedW."' {$style}></".$tag.">" ;
 		$text .= ($space !== false) ? $space : "";
 		
 		return $text;
diff --git a/e107_handlers/form_handler.php b/e107_handlers/form_handler.php
index 2970a3e1c..cbf71da19 100644
--- a/e107_handlers/form_handler.php
+++ b/e107_handlers/form_handler.php
@@ -2205,9 +2205,14 @@ class e_form
 		
 		$labelFound = vartrue($options['label']);
 		unset($options['label']); // label attribute not valid in html5
-				
+
 		$options = $this->format_options('radio', $name, $options);
 		$options['checked'] = $checked; //comes as separate argument just for convenience
+
+		if(empty($options['id']))
+		{
+			$options['id'] = '';
+		}
 		// $options['class'] = 'inline';	
 		$text = "";
 		
@@ -2423,11 +2428,11 @@ class e_form
 		{
 			if(!empty($options['class']))
 			{
-				$options['class'] .= " input-".$options['size'];
+				$options['class'] .= "form-control input-".$options['size'];
 			}
 			else
 			{
-				$options['class'] = "input-".$options['size'];
+				$options['class'] = "form-control input-".$options['size'];
 			}
 
 			unset($options['size']); // don't include in html 'size='. 	
@@ -3379,7 +3384,7 @@ class e_form
 
 			case 'radio':
 				//$def_options['class'] = ' ';
-				$def_options = array('class' => '');
+				$def_options = array('class' => '', 'id'=>'');
 				unset($def_options['size'], $def_options['selected']);
 				break;
 
diff --git a/e107_handlers/theme_handler.php b/e107_handlers/theme_handler.php
index 93f41f395..98bf20bb9 100644
--- a/e107_handlers/theme_handler.php
+++ b/e107_handlers/theme_handler.php
@@ -447,8 +447,8 @@ class e_theme
 
 			foreach($vars['stylesheets']['css'] as $val)
 			{
-				$notadmin = vartrue($val['@attributes']['admin']) ? false : true;
-
+			//	$notadmin = vartrue($val['@attributes']['admin']) ? false : true;
+				$notadmin = (varset($val['@attributes']['scope']) !== 'admin') ? true : false;
 				$vars['css'][] = array("name" => $val['@attributes']['file'], "info"=> $val['@attributes']['name'], "nonadmin"=>$notadmin, 'scope'=> vartrue($val['@attributes']['scope']));
 			}
 
@@ -828,7 +828,7 @@ class themeHandler
 
 		if(!empty($themeArray[$file]['css']) && count($themeArray[$file]['css']) > 1)
 		{
-			$themeArray[$file]['multipleStylesheets'] = TRUE;	
+			$themeArray[$file]['multipleStylesheets'] = true;
 		}
 
 
@@ -2007,7 +2007,7 @@ class themeHandler
 						
 						$adminstyles = $file->get_files(e_ADMIN."includes");
 						
-						$astext = "\n<select id='mode2' name='adminstyle' class='tbox'>\n";
+						$astext = "\n<select id='mode2' name='adminstyle' class='form-control input-medium'>\n";
 						
 						foreach ($adminstyles as $as)
 						{
@@ -2027,9 +2027,11 @@ class themeHandler
 						<tr>
 							<td><b>" . TPVLAN_89 . "</b></td>
 							<td colspan='2'>
+								<div class='checkbox'>
 								<label class='checkbox'>
 									" . $frm->checkbox('adminpref', 1, (varset($pref['adminpref'], 0) == 1)) . "
 								</label>
+								</div>
 							</td>
 						</tr>
 						\n";
@@ -2065,7 +2067,7 @@ class themeHandler
 								case 2: // admin mode.
 									$for = $frm->name2id("admincss-".$css['name']);
 									$text2 = "<td class='center'>";
-									$text2 .= $frm->radio('admincss', $css['name'], vartrue($pref['admincss'])== $css['name']);
+									$text2 .= $frm->radio('admincss', $css['name'], vartrue($pref['admincss'])== $css['name'], array('id'=>$for));
 									$text2 .= "</td>";
 									$text2 .= "<td><label for='".$for."'>".$css['info']."</label></td>";
 									$text2 .= "<td>".($css['info'] ? $css['info'] : ($css['name'] == "admin_style.css" ? TPVLAN_23 : TPVLAN_24))."</td>\n";
@@ -2182,6 +2184,8 @@ class themeHandler
 		}
 
 
+
+
 		foreach($theme['css'] as $k=>$vl) // as defined.
 		{
 			if(!empty($detected[$vl['name']])) // remove any detected files which are listed
@@ -2215,6 +2219,11 @@ class themeHandler
 
 				case 2: // admin
 
+					if(e_DEVELOPER !== true || e_DEBUG !== true)
+					{
+						return array();
+					}
+
 					if($vl['name'] == "style.css" || empty($vl['info'])) // Hide the admin css unless it has a header. eg. /* info: Default stylesheet */
 					{
 						$remove[$k] = $vl['name'];
@@ -2225,7 +2234,7 @@ class themeHandler
 						$remove[$k] = $vl['name'];
 					}
 
-					if($vl['scope'] == 'front')
+					if($vl['scope'] === 'front')
 					{
 						$remove[$k] = $vl['name'];
 					}
@@ -2609,33 +2618,21 @@ class themeHandler
 	
 	function setAdminStyle()
 	{
-		global $pref,$e107cache;
-		
-		$ns = e107::getRender();
-		$mes = e107::getMessage();
-		/*$pref['admincss'] = $_POST['admincss'];
-		 $pref['adminstyle'] = $_POST['adminstyle'];
-		 $e107cache->clear_sys();
-		 if(save_prefs())
-		 {
-		 $mes->add(TPVLAN_43, E_MESSAGE_SUCCESS);
-		 $this->theme_adminlog('04',$pref['adminstyle'].', '.$pref['admincss']);
-		 }
-		 else
-		 {
-		 $mes->add(TPVLAN_43, E_MESSAGE_ERROR);
-		 }*/
-
-		
 		//TODO adminlog
-		e107::getConfig()
-			->setPosted('admincss', $_POST['admincss'])
-			->setPosted('adminstyle', $_POST['adminstyle'])
-			->setPosted('adminpref', varset($_POST['adminpref'], 0));
+
+		$config =  e107::getConfig();
+
+		if(!empty($_POST['admincss']))
+		{
+			$config->setPosted('admincss', $_POST['admincss']);
+		}
+
+		return $config->setPosted('adminstyle', $_POST['adminstyle'])
+			->setPosted('adminpref', varset($_POST['adminpref'], 0))->save(true,true,false);
 		
-		return (e107::getConfig()->dataHasChangedFor('admincss')
+		/*return (e107::getConfig()->dataHasChangedFor('admincss')
 			|| e107::getConfig()->dataHasChangedFor('adminstyle')
-			|| e107::getConfig()->dataHasChangedFor('adminpref'));
+			|| e107::getConfig()->dataHasChangedFor('adminpref'));*/
 	}
 	
 	function SetCustomPages($array)
diff --git a/e107_themes/bootstrap3/admin_dark.css b/e107_themes/bootstrap3/admin_dark.css
index 2f43f1948..51f73130e 100644
--- a/e107_themes/bootstrap3/admin_dark.css
+++ b/e107_themes/bootstrap3/admin_dark.css
@@ -11,10 +11,7 @@ thead tr {
     border: 1px solid rgb(3, 3, 3);
 }
 
-.adminlist tr > td {
-	
-min-height:50px;
-}
+
 
 .datetimepicker {
 	background-color: #191919;
diff --git a/e107_themes/bootstrap3/admin_style.css b/e107_themes/bootstrap3/admin_style.css
index b1e97e77b..3c7403942 100644
--- a/e107_themes/bootstrap3/admin_style.css
+++ b/e107_themes/bootstrap3/admin_style.css
@@ -1306,6 +1306,9 @@ td.forumheader { background-image: linear-gradient(#303030,#212121 60%,#171717);
 .navbar-nav > li > a.admin-icon-avatar { padding-top: 11px; padding-bottom: 10px;}
 
 form#simplesef h4 { margin: 0 }
+.adminlist tr > td { min-height:50px; }
+
+.navbar-fixed-top { height: 51px; }
 
 
 /*
diff --git a/e107_themes/bootstrap3/admin_theme.php b/e107_themes/bootstrap3/admin_theme.php
index 66bb696a8..73bbf31ec 100644
--- a/e107_themes/bootstrap3/admin_theme.php
+++ b/e107_themes/bootstrap3/admin_theme.php
@@ -24,9 +24,19 @@ e107::library('load', 'bootstrap');
 e107::library('load', 'fontawesome');
 e107::library('load', 'bootstrap.editable');
 
-e107::css('theme', 'css/bootstrap-dark.min.css');
+
+$adminStyle = e107::pref('core', 'admincss');
+
+//e107::css('theme', 'css/bootstrap-dark.min.css');
+e107::css('theme', $adminStyle);
 e107::css('theme', 'admin_style.css');
-e107::css('theme', 'admin_dark.css');
+
+if(!deftrue('e_DEBUG'))
+{
+	e107::css('theme', 'admin_dark.css');
+}
+
+
 e107::css('theme', 'ie_all.css', null, 'all', "<!--[if IE]>", "<![endif]-->");
 
 e107::css('inline', "
diff --git a/e107_themes/bootstrap3/theme.xml b/e107_themes/bootstrap3/theme.xml
index 8191d3f68..f42d03734 100644
--- a/e107_themes/bootstrap3/theme.xml
+++ b/e107_themes/bootstrap3/theme.xml
@@ -20,6 +20,7 @@
 	<stylesheets>
 		<css file="style.css" name="Default"  />
         <css file="css/bootstrap-dark.min.css" name="Bootstrap3 Dark Admin" scope='admin' />
+        <css file="http://bootswatch.com/sandstone/bootstrap.min.css" name="Bootwatch Sandstone" scope='admin' />
         <css file="*" name="*"  />
 	</stylesheets>
 	<layouts>