mirror of
https://github.com/misterunknown/ifm.git
synced 2025-08-10 18:14:00 +02:00
fixed some problems with inline mode
This commit is contained in:
@@ -1238,6 +1238,3 @@ function IFM( params ) {
|
||||
this.initLoadConfig();
|
||||
};
|
||||
}
|
||||
|
||||
var ifm = new IFM();
|
||||
ifm.init( "ifm" );
|
||||
|
File diff suppressed because one or more lines are too long
@@ -14,7 +14,6 @@ $IFM_SRC_JS = "src/ifm.js";
|
||||
|
||||
$IFM_BUILD_STANDALONE = "ifm.php";
|
||||
$IFM_BUILD_LIB_PHP = "build/ifmlib.php";
|
||||
$IFM_BUILD_LIB_JS = "build/ifm.js";
|
||||
|
||||
/**
|
||||
* Prepare main script
|
||||
@@ -55,4 +54,3 @@ file_put_contents( $IFM_BUILD_STANDALONE, array(
|
||||
*/
|
||||
file_put_contents( $IFM_BUILD_LIB_PHP, $main );
|
||||
file_put_contents( $IFM_BUILD_LIB_PHP, $phpincludes, FILE_APPEND );
|
||||
file_put_contents( $IFM_BUILD_LIB_JS, file_get_contents( $IFM_SRC_JS ) );
|
||||
|
@@ -1238,6 +1238,3 @@ function IFM( params ) {
|
||||
this.initLoadConfig();
|
||||
};
|
||||
}
|
||||
|
||||
var ifm = new IFM();
|
||||
ifm.init( "ifm" );
|
||||
|
@@ -77,6 +77,7 @@ class IFM {
|
||||
<div id="ifm"></div>';
|
||||
$this->getJS();
|
||||
print '
|
||||
<script>var ifm = new IFM(); ifm.init( "ifm" );</script>
|
||||
</body>
|
||||
</html>
|
||||
';
|
||||
@@ -88,7 +89,7 @@ class IFM {
|
||||
$this->getJS();
|
||||
}
|
||||
|
||||
private function getCSS() {
|
||||
public function getCSS() {
|
||||
print '
|
||||
<style type="text/css">';?> @@@src/includes/bootstrap.min.css@@@ <?php print '</style>
|
||||
<style type="text/css">';?> @@@src/includes/fontello-embedded.css@@@ <?php print '</style>
|
||||
@@ -96,7 +97,7 @@ class IFM {
|
||||
';
|
||||
}
|
||||
|
||||
private function getJS() {
|
||||
public function getJS() {
|
||||
print '
|
||||
<script>';?> @@@src/includes/ace.js@@@ <?php print '</script>
|
||||
<script>';?> @@@src/includes/jquery.min.js@@@ <?php print '</script>
|
||||
@@ -156,6 +157,7 @@ class IFM {
|
||||
print json_encode(array("status"=>"ERROR", "message"=>"No valid working directory"));
|
||||
}
|
||||
}
|
||||
exit( 0 );
|
||||
}
|
||||
|
||||
public function run( $mode="standalone" ) {
|
||||
@@ -166,7 +168,7 @@ class IFM {
|
||||
else
|
||||
chdir( realpath( $this->config['root_dir'] ) );
|
||||
$this->mode = $mode;
|
||||
if ( isset($_REQUEST['api']) || $mode == "api" ) {
|
||||
if ( isset( $_REQUEST['api'] ) || $mode == "api" ) {
|
||||
$this->handleRequest();
|
||||
} elseif( $mode == "standalone" ) {
|
||||
$this->getApplication();
|
||||
|
Reference in New Issue
Block a user