Announcement

Do not use the forums to submit bug reports, feature requests or patches, submit a New Ticket instead.

#1 2012-04-03 04:33:39

Hablitzl
New member
Registered: 2012-04-03
Posts: 1

Dynamic path to image directory for ExtendedFileManager

I call Xinha from my php script. How can I set the image file path dynamically for the ExtendedFileManager? I found some instructions, but it dosn't work???
If I work with static config in the plugindir all is ok, but I must change to different directories so that the users have no access to the other dirs.

I don't understand the instruction of installation. There is a config file in the plugindir, butt all examples make the configuration in the php file of the cms. Whe I do so, I get an error "xinha_confi is null" from my php script:

********** index.php *******************************
    <script type="text/javascript">
        _editor_url="/xinha";
        _editor_lang="de";
        _editor_skin="xp-blue";
        _editor_icons="classic";
    </script>
    <script type="text/javascript" src="/xinha/XinhaCore.js"></script>
    <script type="text/javascript" src="my_config.js"></script>
    <script type="text/javascript">
       with (xinha_config.ExtendedFileManager) {
            <?php

            // define backend configuration for the plugin
            $IMConfig = array();

            $IMConfig['allow_upload'] = true;
           ....

            require_once '../../xinha/contrib/php-xinha.php';
            xinha_pass_to_php_backend($IMConfig);
            ?>               
            }
    </script>
**********************************************

If I set in config a variable from mainscript it's unknown.

What to do and in which file?

Thanks

Last edited by Hablitzl (2012-04-05 09:18:20)

Offline

#2 2012-04-09 05:21:45

gogo
Xinha Leader
From: New Zealand
Registered: 2005-02-11
Posts: 1,015
Website

Re: Dynamic path to image directory for ExtendedFileManager

You must load plugins before. 

See newbie guide.

http://trac.xinha.org/wiki/NewbieGuide

You shoudl configure EFM in Step 3 of the script (of course you must make your config script parsed by PHP).


James Sleeman

Offline

Board footer

Powered by FluxBB