This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

[Module] ELFileManager (build on elfinder)
#10
RE: [Module] ELFileManager (build on elfinder)
Here ya go Diablo925, iframe version:

module.zpm:

PHP Code:
<@ Init @>
<
div class="zmodule_content panel" id="zmodule_header_<@ ModuleName @>">
    <div class="panel-heading">
        <img src="<@ ModuleIcon @>" width="35" height="35" border="0" alt="<@ ModuleName @>">

        <div class="zmodule_title">
            <@ ModuleName @>
        </div>

        <div class="zmodule_desc" id="zmodule_desc_<@ ModuleName @>"><@ ModuleDesc @></div>
        
    
</div>
    
    
<form name="FileManager" action="modules/ELFileManager/app/elfinder.php?id=<@ UserID @>" target="FileManager" method="post" onsubmit="var w=window.open('', 'FileManager', 'scrollbars=no,menubar=no,height=600,width=1024,resizable=no,toolbar=no,location=no,status=no'); w.focus();">
            <table class="table table-striped">
                <tr>
                    <th nowrap="nowrap"><button class="btn btn-primary" type="submit" name="inOpen" value="<@ UseriD @>"><: Launch In New Window :></button></th>
                </tr>
            </table>
        </form>
<!-- 
iframe by TGates -->
<
iframe src="modules/ELFileManager/app/elfinder.php?id=<@ UserID @>" scrolling="no" width="100%" height="200px" id="iframe1" marginheight="0" frameborder="0" onLoad="autoResize('iframe1');"></iframe>
</
div

Controller.ext.php:

PHP Code:
<?php

class module_controller extends ctrl_module
{
 
   /* Load JS */
 
   static function getInit() {
 
       global $controller;
 
       $line '';
 
       $line .= '<!-- iframe by TGates -->
            <script language="JavaScript">
            <!--
            function autoResize(id){
                var newheight;
                var newwidth;

                if(document.getElementById){
                    newheight = document.getElementById(id).contentWindow.document .body.scrollHeight;
                    newwidth = document.getElementById(id).contentWindow.document .body.scrollWidth;
                }

                document.getElementById(id).height = (newheight) + "px";
                document.getElementById(id).width = (newwidth) + "px";
            }
            //-->
            </script>'

 
       return $line;
 
   }

    static function 
getUserID() 
 
      
 
             global $controller
            
$currentuser ctrl_users::GetUserDetail(); 
            
$userid $currentuser['userid']; 
            return 
$userid
    }

}
?>

And in elfinder.php change line 48 to:
PHP Code:
width 950
-TGates - Project Council

SEARCH the Forums or read the DOCUMENTATION before posting!
Support Sentora and Donate: HERE

Find my support or modules useful? Donate to TGates HERE
Developers and code testers needed!
Contact TGates for more information
Reply
Thanks given by: Diablo925


Messages In This Thread
RE: [Module] ELFileManager (build on elfinder) - by TGates - 10-24-2015, 04:34 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
[MODULE] phpMyAdmin-AU (Auto-Update) TGates 14 40 ,828 06-15-2021, 06:54 AM
Last Post: TGates
[MODULE] SenBrand - Basic Branding module for Sentora TGates 20 43 ,667 06-04-2021, 11:47 AM
Last Post: ccr1969
[MODULE] CoinCorner BitCoin Module Xversion 4 13 ,126 06-03-2021, 05:02 AM
Last Post: zHostingSolutions

Forum Jump:


Users browsing this thread: 7 Guest(s)