Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6833383
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T22:58:17+00:00 2026-05-26T22:58:17+00:00

I use iBrowser to upload images into TinyMCE editor. It uses ilibs_dir config param

  • 0

I use iBrowser to upload images into TinyMCE editor. It uses ilibs_dir config param to set folder where images will be stored. I would like to integrate it with my site that has many users. How can i set different folder of each users? I have my user ID stored in $userId value in my PHP script that emits the TinyMCE editor.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T22:58:17+00:00Added an answer on May 26, 2026 at 10:58 pm

    You should not create a different folder for each user, but instead let PHP manage it. You could/should store the images in 1 folder, and save it to a MySQL database which image is from which user. Then when TinyMCE requests an image, let php check if the user owns that image, and if so, give it.

    The image list you can supply to TinyMCE can also be created by PHP, and supply the image list in JSON list to TinyMCE ( http://www.tinymce.com/wiki.php/Configuration:external_image_list_url )

    This way you have total control over the images, and it is also much more secure.

    edit: Got an example for you how to create the list with PHP:

    header("Content-type: text/javascript");
    $js = 'var tinyMCEImageList = new Array(';
    $images = array('image1' => 'http://www.example.com/image1.jpg', 'image2' => 'http://www.example.com/image2.jpg');
    foreach ($images as $name => $url) {
        $js .= '["'.$name.'", "'.$url.'"],';
    }
    $js = rtrim($js, ',').');';
    echo $js;
    

    This outputted file should be included in the website through a script file as a JavaScript file.

    <script type="text/javascript" src="PATH TO PHP FILE WITH LIST" />
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Use MongoDB GridFS store images and images stored directly on disk What are the
use Rack::Static, :urls => ['/stylesheets', '/images'], :root => 'public' run proc { |env| [200,
Use Case When a user goes to my website, they will be confronted with
USE master GO DECLARE @DbName nvarchar(MAX) SET @DbName = N'DataBase' ALTER DATABASE @DbName SET
Use a hidden field will fix my issue... i got it.. Hi All, I
Use paperclip for my images. Models: class Country < ActiveRecord::Base has_many :regions has_many :assets,
Use of function calls in where clause of stored procedure slows down performance in
USE [Fk_Test2] GO /****** Object: Table [dbo].[Owners] Script Date: 08/20/2010 16:52:44 ******/ SET ANSI_NULLS
USE AdventureWorks2008R2; GO INSERT INTO myTestSkipField SELECT * FROM OPENROWSET(BULK 'C:\myTestSkipField-c.dat', FORMATFILE='C:\myTestSkipField.fmt' ) AS
I'm trying to use this line to detect browser type: IE or Firefox. alert(isBrowser(Microsoft));

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.