htmlArea

A directory of browser-based WYSIWYG editors

  MAIN
INDEX
SEARCH
POSTS
WHO'S
ONLINE
LOG
IN

Home: htmlArea 2: htmlArea 2 & 3 archive (read only): htmlArea v2.0 - Add-Ons:
"Image Manager"-like file manager


The htmlArea 2 & 3 editors have been discontinued.

We've made these forums available as a read-only reference and knowledge-base for people using or developing editors based on htmlArea 2 or 3.

Anyone who is interested in taking over version 2 or 3 is free to do so. All we ask is that you choose a new name that doesn't have "htmlarea" in it to avoid confusion with this site. We'll even give you a link in the directory to make it easier for people to find you. If you are developing or hosting an htmlArea based-editor under a new name, please submit it to our directory.

First page Previous page 1 2 Next page Last page  View All


taurentius
Novice

Apr 10, 2003, 6:59 PM

Post #1 of 44 (12037 views)
Shortcut
"Image Manager"-like file manager Can't Post

Dear all,

I was wondering whether some people have a developed a file manager, similar to the PHP image manager. I saw some posts about it, but they are pretty old.
If no one has, it might be a nice new add-on?

--t


(This post was edited by taurentius on Apr 10, 2003, 7:33 PM)


barry-hunter
Novice

Apr 10, 2003, 7:52 PM

Post #2 of 44 (12020 views)
Shortcut
Re: [taurentius] "Image Manager"-like file manager [In reply to] Can't Post

I am currently working on just that, I am adapting the Image manager basiclly.

If i get it to work I'll post it here!



Best regards,

Barry


taurentius
Novice

Apr 11, 2003, 12:47 AM

Post #3 of 44 (12004 views)
Shortcut
Re: [taurentius] "Image Manager"-like file manager [In reply to] Can't Post

Dear all,

I felt kind of active tonight and worked my way through adapting the image manager so that it supports the display and insertion of any file type. It lets you browse for an uploaded file you want to link to. Admitted, it's only a modest adaptation of the original script, but it might be of use for more people than just me.
Suggestions or comments are welcome, as long as they're constructive of course Tongue

--t


(This post was edited by taurentius on Apr 11, 2003, 8:24 AM)
Attachments: fileManager.zip (35.4 KB)
  screenshot.jpg (34.3 KB)


wei
User

Apr 11, 2003, 9:13 PM

Post #4 of 44 (11940 views)
Shortcut
Re: [taurentius] "Image Manager"-like file manager [In reply to] Can't Post

Dear taurentius

Wow, execellent, I was starting to do the file manager. But you have already done it :) Great work.



wei


taurentius
Novice

Apr 12, 2003, 5:32 AM

Post #5 of 44 (11929 views)
Shortcut
Re: [wei] "Image Manager"-like file manager [In reply to] Can't Post

dear wei,

thanks for the compliment, but it's really your work :) I just made some minor adaptations... I also made a dialog based on the image manager where you can browser for another page that is in a database. Useful if you want to provide a CMS for a dynamic, database-driven website. The implementation is, however, greatly dependent on the way you have structured your database, so I don't think it's useful if I post the code here. If someone is interested, I can of course always add it later. (Basically I just have a "content" table and a "category" table and each content entry belongs to a certain category; categories are only one level deep, but in principle could be extended to multiple levels...) See the screenshot for what it looks like...

--t


(This post was edited by taurentius on Oct 22, 2003, 7:07 AM)
Attachments: internal_screenshot.jpg (28.4 KB)
  internal_screenshot2.jpg (30.8 KB)


mbourque
Novice

Apr 12, 2003, 7:48 AM

Post #6 of 44 (11915 views)
Shortcut
Re: [taurentius] "Image Manager"-like file manager [In reply to] Can't Post

I cannt seem to get this to work. Where exactly do I add the code?


Code
   

else if (cmdID.toLowerCase() == 'linktofile') {
var fileLink = showModalDialog(_editor_url + "popups/file/insert_file.php",
editdoc,
"resizable: no; help: no; status: no; scroll: no; ");
if (fileLink) { editor_insertHTML(objname, unescape( fileLink) ); }



taurentius
Novice

Apr 12, 2003, 8:20 AM

Post #7 of 44 (11900 views)
Shortcut
Re: [mbourque] "Image Manager"-like file manager [In reply to] Can't Post

Remember that this is code for htmlArea 2.x, not 3.0a. It should work if you put the code in the function editor_action in editor.js. I put the code below the part where "insertlink" is handled.

Also, don't forget to add the button and the button-producing code:

Code
 "linktofile": ['linktofile', 'Link to a File', 'editor_action(this.id)', 'ed_linktofile.gif'],

further up in the file. (I attached an icon you can use :P)

What might be causing an error is that I assume that a window name "editdoc" has already been defined. You can change that into 'insertlinkdialog' or something else.

Let me know if it works.

--t


(This post was edited by taurentius on Apr 12, 2003, 8:21 AM)
Attachments: ed_linktofile.gif (0.91 KB)


Luis
Veteran

Apr 12, 2003, 4:57 PM

Post #8 of 44 (11844 views)
Shortcut
Re: [mbourque] "Image Manager"-like file manager [In reply to] Can't Post

Make a search in editor.js for
// CUSTOM BUTTONS START HERE
and put the code the line above.


Don't give up!!
http://webstationone.com/test/htmlarea


AlRashid
Novice

Apr 12, 2003, 6:52 PM

Post #9 of 44 (11834 views)
Shortcut
Re: [taurentius] "Image Manager"-like file manager [In reply to] Can't Post

Good work!
I'm working on some additional features for image & link_to_file managers ( detailed view that displays filename, size, extension, date/time modified with sorting capabilities. View the screenshot.)
However I don't know how to pass parameters from the main window (Directory, Up, New, View buttons) to the files.php script showed in the iframe bellow? I'd like to pass the type of view ( eg. List, Details, Thumbnails) to files.php, and this value should be preserved while browsing in the iframe window. How can I do that?
Attachments: linktofile-details.jpg (39.0 KB)


taurentius
Novice

Apr 12, 2003, 8:32 PM

Post #10 of 44 (11817 views)
Shortcut
Re: [AlRashid] "Image Manager"-like file manager [In reply to] Can't Post

Hi AlRashid,

Your screenshot looks very nice! Did you base it on the image manager or the file manager or did you make it yourself? Actually, at first I misread your question and thought you wanted to pass variables from the files.php to the insert_file.php form elements (which is very basic). As you want it the other way round, things are probably a bit more complicated.

Much depends on what you want to construe. If a user changes the "view", do you want it to load a "different" page (e.g. files.php?view=thumbnails)? Or something else? In the first case, you could address the issue by calling a javascript whenever the selected view changes. For example, on change:


Code
  imgManager.location='files.php?view=thumbnails'

Passing on values to other elements in the iframe can be done by addressing the correct element id (e.g. imgManager.form[0].bla).

As you probably want to ensure that the user stays on the same page, only changing the view, you might have to make a two-stage rocket: first, trigger a "changeView" javascript, which triggers a javascript "giveLocation" in the files.php, which returns the current location/dirParam of the iframe as an attribute to a javscript "changeIframe" in insert_file.php (which on turn changes the location of the iframe).

Perhaps it is also possible to just get the current location of the iframe (e.g. imgManager.location();) and build from there...

Preserving the view value while browsing should be possible if you parse and store the $_GET["view"] variable and concatenate that to each link.

Good luck and if I can help, let me know :)

--t


(This post was edited by taurentius on Apr 12, 2003, 8:35 PM)


mixmuis
User

Apr 13, 2003, 3:10 PM

Post #11 of 44 (11715 views)
Shortcut
Re: [mbourque] "Image Manager"-like file manager [In reply to] Can't Post

i had the problem to

place a } under the code and it works, the readme file has a'typo' on this.



// CUSTOM BUTTONS START HERE

else if (cmdID.toLowerCase() == 'linktofile') {
var fileLink = showModalDialog(_editor_url + "popups/filemanager/insert_file.php",
editdoc,
"resizable: no; help: no; status: no; scroll: no; ");
if (fileLink) { editor_insertHTML(objname, unescape( fileLink) ); }
}


(This post was edited by mixmuis on Apr 13, 2003, 3:13 PM)


taurentius
Novice

Apr 13, 2003, 3:36 PM

Post #12 of 44 (11706 views)
Shortcut
Re: [mixmuis] "Image Manager"-like file manager [In reply to] Can't Post

yup, type-o. sorry 'bout that Crazy
hope it works out for mbourque now
maybe if it works, you can delete your editor.js post?

--t


mixmuis
User

Apr 13, 2003, 3:38 PM

Post #13 of 44 (11704 views)
Shortcut
Re: [taurentius] "Image Manager"-like file manager [In reply to] Can't Post

when i press the file in the manager i see //filename.rar
and the link contains also // in the url.. can i fixe this ?


taurentius
Novice

Apr 13, 2003, 4:50 PM

Post #14 of 44 (11691 views)
Shortcut
Re: [mixmuis] "Image Manager"-like file manager [In reply to] Can't Post

the double "//" is indeed a small bug, but I think it only occurs if you want to link to a file in the root directory. I'll have a look at it at a later point, I'm afraid don't have time to look at it right now Unsure

--t


mixmuis
User

Apr 13, 2003, 4:52 PM

Post #15 of 44 (11688 views)
Shortcut
Re: [taurentius] "Image Manager"-like file manager [In reply to] Can't Post

i modded the config file, problems solved so far,

now working on a not working delete function of the dir :(


taurentius
Novice

Apr 13, 2003, 5:02 PM

Post #16 of 44 (11687 views)
Shortcut
Re: [mixmuis] "Image Manager"-like file manager [In reply to] Can't Post

good that it works for you :) I don't have any problems deleting (empty) folders though? when does it occur? anyway, there's lots of room for improvement for the script, so knock yourself out Cool

--t


mixmuis
User

Apr 13, 2003, 5:06 PM

Post #17 of 44 (11685 views)
Shortcut
Re: [taurentius] "Image Manager"-like file manager [In reply to] Can't Post

<a href="files.php?dir=<? echo $path; ?>" onClick="changeLoadingStatus('load')">
<img src="images/folder.gif" width="80" height="80" border=0 alt="<? echo $dir; ?>">


there was a BASE_URL before $path, (http link)
with the unlink it is not working, stil lhaving probs with deleting dir, but solution is here in my mind, withg the beer :)


mixmuis
User

Apr 13, 2003, 5:08 PM

Post #18 of 44 (11683 views)
Shortcut
Re: [mixmuis] "Image Manager"-like file manager [In reply to] Can't Post

done,

changed the url in files.php just like posted before
and changed the line

$del_folder = dir_name($BASE_DIR).$folder;

in

$del_folder = dir_name($BASE_DIR)."/".$folder;

in files.php


AlRashid
Novice

Apr 14, 2003, 6:05 AM

Post #19 of 44 (11647 views)
Shortcut
Re: [mixmuis] "Image Manager"-like file manager [In reply to] Can't Post

Thanx Taurentius for your help.
Finally I get it work, but it's a mixture of javascript and php i'm not very proud of. I modified your version of filemanager, I tried to do only minimal changes, so that eventually wei could re-read his code. But I had to remove the delete folder function (rm_all_dir($dir)) which did not work for me and the small piece of file sorting code at the end of files.php.


(This post was edited by AlRashid on Apr 14, 2003, 3:47 PM)
Attachments: filemanager-details.gif (16.9 KB)
  htmlarea-filemanager.zip (50.6 KB)


mixmuis
User

Apr 14, 2003, 6:27 AM

Post #20 of 44 (11640 views)
Shortcut
Re: [AlRashid] "Image Manager"-like file manager [In reply to] Can't Post

very nice piece of work! i love it this way!

thnx!


mixmuis
User

Apr 14, 2003, 6:59 AM

Post #21 of 44 (11636 views)
Shortcut
Re: [AlRashid] "Image Manager"-like file manager [In reply to] Can't Post


In Reply To
Thanx Taurentius for your help.
Finally I get it work, but it's a mixture of javascript and php i'm not very proud of. I modified your version of filemanager, I tried to do only minimal changes, so that eventually wei could re-read his code. But I had to remove the delete folder function (rm_all_dir($dir)) which did not work for me and the small piece of file sorting code at the end of files.php. Download here.


is there a option to set the listing default to DETAILS ?


DreamWork
New User

Apr 24, 2003, 4:24 AM

Post #22 of 44 (11194 views)
Shortcut
Re: [taurentius] "Image Manager"-like file manager [In reply to] Can't Post

hi taurentius

what du you mean with this

To run the script, add a button to the toolbar with id "linktofile".

i dont show a new button on my editor ! :(



so long


SolarLunar
New User

Apr 28, 2003, 9:36 AM

Post #23 of 44 (11045 views)
Shortcut
Re: [taurentius] "Image Manager"-like file manager [In reply to] Can't Post

Hi all,



Ive tried to use the filemanager but there are still some little Probs...

I cant create or delete a folder and there is no way to upload or delete a file..
the Manager shows me correctly the files and folders - but only when i upload them with FTP ..
the inserted Link is correct too - the chmod of the file root folder is 777 but no upload possible so far..

maybee there is hack to fix this ..

Thx - sorry for this stupid english .. im a little german user ;o)



SolarLunar - stay funky - play vinyl!!


Tzvook
Novice

Apr 28, 2003, 2:30 PM

Post #24 of 44 (11023 views)
Shortcut
Re: [SolarLunar] "Image Manager"-like file manager [In reply to] Can't Post

Hi taurentius

Have I told you that I like your file addon ?
serve me well !!!
The only thing I need in it is a CHMOD

Sly
================================
But now I see a prob. (after playing a bit)

If I enter a sub-dir I can't go back and the scroll-down on top
gives just a "/" ........ and then if I make a new directory it lets me go up again, and gives the directories again in the scroller....

In code mod the link looks like that: <A href="http://popups/bmp.gif" target=_blank>bmp.gif (935 btyes)</A> which is wrong of course but can be changes easily :-)

I moved the "icong + images" from outside of the popups dir, but that's not likely the problem....... is it happaning to you too ?
maybe a path prob?

Any Idea?

======
Tzvook
======

(This post was edited by Tzvook on Apr 28, 2003, 3:20 PM)


vonbrocklin
Novice

May 1, 2003, 5:22 PM

Post #25 of 44 (10762 views)
Shortcut
Re: [taurentius] "Image Manager"-like file manager [In reply to] Can't Post


In Reply To
the double "//" is indeed a small bug, but I think it only occurs if you want to link to a file in the root directory. I'll have a look at it at a later point, I'm afraid don't have time to look at it right now Unsure

--t




NOTE: There was a problem with reassigning the newPath variable. The pathFix hack below solves this.
I fixed this if anybody is interested. Just go into files.php and find this line from the table that starts at about line 237:


Code
  REPLACE THIS:   
<a href="javascript:;" onClick="fileSelected('<? echo $newPath."/".$file_name; ?>',
'<? echo $file_name." (".parse_size($size).")"; ?>')">
WITH THIS:


<? $pathFix = $newPath;
if ($pathFix = "/") { $pathFix = ""; } ?>


<a href="javascript:;" onClick="fileSelected('<? echo $pathFix."/".$file_name; ?>',
'<? echo $file_name."
(".parse_size($size).")"; ?>')">

I'm sure there is a more logical place to fix this wherever the newPath variable is set but I was in a hurry and this seems to work fine.


(This post was edited by vonbrocklin on May 2, 2003, 12:37 PM)

First page Previous page 1 2 Next page Last page  View All
 
 


Search for (options)