[GH-ISSUE #20] Embedding Tinyfilemanager #12

Closed
opened 2026-03-02 15:54:59 +03:00 by kerem · 3 comments
Owner

Originally created by @bachellerieloic on GitHub (Oct 24, 2017).
Original GitHub issue: https://github.com/prasathmani/tinyfilemanager/issues/20

I'm currently trying to embbed TinyFileManager in a website.

The authentication form appears, but then, nothing is being displayed.

Do you have any idea why...

I use an Include... and it works since the form is displayed.

Thank you !

Originally created by @bachellerieloic on GitHub (Oct 24, 2017). Original GitHub issue: https://github.com/prasathmani/tinyfilemanager/issues/20 I'm currently trying to embbed TinyFileManager in a website. The authentication form appears, but then, nothing is being displayed. Do you have any idea why... I use an Include... and it works since the form is displayed. <?php include 'tinyfilemanager.php'; ?> Thank you !
kerem 2026-03-02 15:54:59 +03:00
  • closed this issue
  • added the
    question
    label
Author
Owner

@prasathmani commented on GitHub (Nov 3, 2017):

please check the $root_path.
try this,


class SomeController
{
    public function actionIndex()
    {
        define('FM_EMBED', true);
        define('FM_SELF_URL', UrlHelper::currentUrl()); // must be set if URL to manager not equal PHP_SELF
        require 'path/to/filemanager.php';
    }
}
<!-- gh-comment-id:341827683 --> @prasathmani commented on GitHub (Nov 3, 2017): please check the $root_path. try this, <pre><code> class SomeController { public function actionIndex() { define('FM_EMBED', true); define('FM_SELF_URL', UrlHelper::currentUrl()); // must be set if URL to manager not equal PHP_SELF require 'path/to/filemanager.php'; } } </code></pre>
Author
Owner

@MGeurts commented on GitHub (Jan 18, 2018):

Could you show us (an example) how to embed FM in a normal page by using the class above?
Thanks

<!-- gh-comment-id:358635065 --> @MGeurts commented on GitHub (Jan 18, 2018): Could you show us (an example) how to embed FM in a normal page by using the class above? Thanks
Author
Owner

@prasathmani commented on GitHub (Jan 19, 2018):

try this simple one.

<?php
define('FM_EMBED', true);
define('FM_SELF_URL', $_SERVER['PHP_SELF']);
require 'tinyfilemanager/tinyfilemanager.php';
?>
<!-- gh-comment-id:358872679 --> @prasathmani commented on GitHub (Jan 19, 2018): try this simple one. ``` <?php define('FM_EMBED', true); define('FM_SELF_URL', $_SERVER['PHP_SELF']); require 'tinyfilemanager/tinyfilemanager.php'; ?> ```
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/tinyfilemanager#12
No description provided.