elioncho
2009-Feb-09 05:17 UTC
Insight on creating an online file editor (create, edit files, browse tree structure)
Hello guys, Can anyone give any ideas on how to start working to do an online file editor. I want the user to create his/her own directory on the server an be able to create new text files and edit them online. A file tree should be available to check the current files in his/her directory. Can anyone give me any insight, ideas on how to begin working on this? Thanks a lot, Elías --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Sazima
2009-Feb-09 13:05 UTC
Re: Insight on creating an online file editor (create, edit files, browse tree structure)
Well, you could try to 1st implement a "remote shell", that is, you submit a command (like ls -la), your controller executes it and then you display the result in the browser. Maybe Capistrano gives you a start on that. After that you can work on the user interface (file tree, etc). You then start working with file editing: you need to read the file (maybe lock it), display to the user in a text area (possibly with a WYSIWYG editor like www.fckeditor.net) and then submit the contents to the server and save the file (check if it still exists) and so on... After everything is working, you might find it appealing glue it all together with AJAX. Finally, you need to control permissions, security, etc. Good luck! Cheers, Sazima On Feb 9, 3:17 am, elioncho <elion...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Hello guys, > > Can anyone give any ideas on how to start working to do an online file > editor. I want the user to create his/her own directory on the server > an be able to create new text files and edit them online. A file tree > should be available to check the current files in his/her directory. > Can anyone give me any insight, ideas on how to begin working on this? > > Thanks a lot, > > Elías--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
elioncho
2009-Feb-09 14:52 UTC
Re: Insight on creating an online file editor (create, edit files, browse tree structure)
Hello, Thanks for the tips. So the basic idea is to create the user directory folders and files with shell commands via the controllers. Do you have any ideas on how to create a file tree? Maybe a component from YUI or the google webkit or maybe a plugin (or gem) which can help me to show a tree structure an be able to click on files an open them in the textarea? Thanks again for your input, Elías On Feb 9, 8:05 am, Sazima <rsaz...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Well, you could try to 1st implement a "remote shell", that is, you > submit a command (like ls -la), your controller executes it and then > you display the result in the browser. Maybe Capistrano gives you a > start on that. > > After that you can work on the user interface (file tree, etc). > > You then start working with file editing: you need to read the file > (maybe lock it), display to the user in a text area (possibly with a > WYSIWYG editor likewww.fckeditor.net) and then submit the contents to > the server and save the file (check if it still exists) and so on... > > After everything is working, you might find it appealing glue it all > together with AJAX. > > Finally, you need to control permissions, security, etc. > > Good luck! > > Cheers, Sazima > > On Feb 9, 3:17 am, elioncho <elion...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > Hello guys, > > > Can anyone give any ideas on how to start working to do an online file > > editor. I want the user to create his/her own directory on the server > > an be able to create new text files and edit them online. A file tree > > should be available to check the current files in his/her directory. > > Can anyone give me any insight, ideas on how to begin working on this? > > > Thanks a lot, > > > Elías--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---