mirror of
https://github.com/xevidos/codiad.git
synced 2024-11-14 07:41:14 +01:00
Added js and css versions to default theme files.
This commit is contained in:
parent
c833bb72de
commit
0904b5328a
2 changed files with 9 additions and 3 deletions
|
@ -93,6 +93,7 @@ class Common {
|
|||
define( "LANGUAGE", "en" );
|
||||
}
|
||||
|
||||
require_once( COMPONENTS . "/update/class.update.php" );
|
||||
require_once( COMPONENTS . "/sql/class.sql.php" );
|
||||
global $sql;
|
||||
$sql = sql::get_instance();
|
||||
|
@ -195,6 +196,11 @@ class Common {
|
|||
return( $return );
|
||||
}
|
||||
|
||||
public static function get_version() {
|
||||
|
||||
return Update::VERSION;
|
||||
}
|
||||
|
||||
public static function is_admin() {
|
||||
|
||||
global $sql;
|
||||
|
@ -659,4 +665,5 @@ function isAvailable($func) { return Common::isAvailable($func); }
|
|||
function logout() { return Common::logout(); }
|
||||
function get_users( $return = "return", $exclude_current = false ) { return Common::get_users( $return, $exclude_current ); }
|
||||
function search_users( $username, $return = "return", $exclude_current = false ) { return Common::search_users( $username, $return, $exclude_current ); }
|
||||
function get_version() { return Common::get_version(); }
|
||||
?>
|
||||
|
|
|
@ -32,7 +32,6 @@ if( defined( "SITE_NAME" ) && ! ( SITE_NAME === "" || SITE_NAME === null ) ) {
|
|||
|
||||
?>
|
||||
<!doctype html>
|
||||
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
|
@ -45,7 +44,7 @@ if( defined( "SITE_NAME" ) && ! ( SITE_NAME === "" || SITE_NAME === null ) ) {
|
|||
if(file_exists(THEMES . "/". $theme . "/".$sheet)){
|
||||
echo('<link rel="stylesheet" href="themes/'.$theme.'/'.$sheet.'">');
|
||||
} else {
|
||||
echo('<link rel="stylesheet" href="themes/default/'.$sheet.'">');
|
||||
echo('<link rel="stylesheet" href="themes/default/'.$sheet.'?v=' . get_version() . '">');
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -55,7 +54,7 @@ if( defined( "SITE_NAME" ) && ! ( SITE_NAME === "" || SITE_NAME === null ) ) {
|
|||
echo('<link rel="stylesheet" href="themes/'.$theme.'/'.$component.'/screen.css">');
|
||||
} else {
|
||||
if(file_exists("themes/default/" . $component . "/screen.css")){
|
||||
echo('<link rel="stylesheet" href="themes/default/'.$component.'/screen.css">');
|
||||
echo('<link rel="stylesheet" href="themes/default/'.$component.'/screen.css?v=' . get_version() . '">');
|
||||
} else {
|
||||
if(file_exists(COMPONENTS . "/" . $component . "/screen.css")){
|
||||
echo('<link rel="stylesheet" href="components/'.$component.'/screen.css">');
|
||||
|
|
Loading…
Reference in a new issue