I want to do exactly what is featured here: http://www.online-html-editor.de/index_en.php
I want a user to be able to browse their machine to an HTML file and then alter and save that file back to their hard drive. I cannot seem to find that feature anywhere.
Any help would be much appreciated.
Cheers!
Fri, 05/15/2009 - 00:43
#1
Re: Import HTML file and then save out file....
Thanks again.
Re: Import HTML file and then save out file....
Re: Import HTML file and then save out file....
Thank you.
Re: Import HTML file and then save out file....
1. read from POST multipart form data
2. save to a request variable to content of the upload
3. create an instance, assign the value of the variable to the FCKeditor value.
You're done.
Re: Import HTML file and then save out file....
If you have the knowledge, share. Write a response as if you are teaching a ten year old. Assume they know very little. When this topic comes up again, copy and paste.
Re: Import HTML file and then save out file....
Re: Import HTML file and then save out file....
Alright. I think I am approaching this wrong. If we look at my first post, you will see that I show exactly what I want FCK editor to do: allow a user to upload HTML into a text field and save out that file to their desktop. Originally I thought this would be a simple task and that there would be an "Open Document" button on FCK. I later realized that the feature was added onto the WYSIWYG editor as an HTML/PHP form solution.
I am currently working with this, http://www.raditha.com/megaupload/, to make an upload form. I did not realize so much was involved. I now have to have a way to clean out the database entries, as to not have any privacy issues about saving a users document.
Am I going in the right direction? Is there a better, more elegant solution? Can you point me to one of your previous posts?
Re: Import HTML file and then save out file....
I would be easier to follow my steps.
The first you should do is to make the upload work with a simple form:
The file content will be in the post body. Please install Firebug and Fiddler, they will ease your work tremendously. Figure out how to read form data with PHP. This is enough for the beginning. Accomplish that and we will continue then. I just don't want to overload you. You wouldn't benefit from.
Re: Import HTML file and then save out file....
I am having some trouble with uploader.php. I used this: http://www.tizag.com/phpT/fileupload.php and can't get it to actually upload the file. Any suggestions?
Re: Import HTML file and then save out file....
Hi:
I have found a kinda solucion for this.. but I'm stuck at the end part.
I use this class to convert the OpenDocument to xHTML > http://odt2xhtml.eu.org/index_en.html then I copy it to an temporal folder TEMP and the name of the file is importado.html
And then I build the FCKEditor class: