hi,
during image insertion, when we browse an image on the server... how can we configure the FCKEditor to return or display the whole/absolute path of the image... like to return this --> http://.../UserFiles/Image/about.gif instead of this --> /UserFiles/Image/about.gif ?
i have read there's this FCKConfig.BaseHref in which you can define the base URL to be used for all resources... but this is quite useful when you have different domains... so the absolute path would only return if you are using the editor in a different domain... right? or... have i misunderstood it...
hope to hear any response...
thanks and regards,
hTroy
Thu, 03/06/2008 - 21:10
#1
Re: How to display the absolute path of the image?
Re: How to display the absolute path of the image?
i have the same problem...
i can view an image because his path is '../images/Image/myImage.jpg' when the image is in the directory /images/image/
help us
byebye!
Re: How to display the absolute path of the image?
Re: How to display the absolute path of the image?
I'm still quite the noob at this, so could you be a leetle more specific?
Is this appended to an existing php file, and if so, which?
or is it a new php file, and if so, do I need to edit any other files?
Thanks again
Re: How to display the absolute path of the image?
Ok, you don't need to alter ant FCKEditor files.
The clue is to create php function which patch incoming (from fckeditor) text.
You have to add full path to the img places, for exmpl:
When your php script receive text from fckeditor with many img paths like ' src="../files/Image/' ,
then you should patch'em lke ' src="http://www.mydom.com/files/Image/...'
this is done with str_replace func:
str_replace(' src=\"../files/Image/', ' src="http://www.mydom.com/files/Image/', $fckeditortext);
Re: How to display the absolute path of the image?
I'm feeling kind of dumb about this by now. I'm even more confused by your answer!
I don't write PHP very much, I've so far only used some existing OSS code and tweaked it to make it work for me.
I'm setting up a page using Javascript integration, because that's what I'm familiar with, as described here:
http://docs.fckeditor.net/FCKeditor_2.x ... JavaScript.
My intention is to use it as an online code generator, and manually copy the HTML code created by FCKeditor into another application.
I don't have a script to receive the text directly from the editor.
I'm not sure how to apply this function to the FCKeditor using PHP.
I was hoping that it could be used to make FCKeditor display the absolute paths when you click the "Source" button.
Thanks anyway.
Re: How to display the absolute path of the image?
hi tmpbob,
thanks for the idea... although im having the fckeditor with it's asp.net integration, but yeah i got the idea now...
my next concern is... on uploading of images, how can i set the would-be-created "UserFiles" folder to a specific location of my choosing?
for example, the UserFiles folder will be created in root/UserFiles (automatically, i haven't done anything)... but i need to set it on root/subapp/UserFiles (what needs to be done?)...
thank you so much for any notes...
Re: How to display the absolute path of the image?
Hi there.
This is my first post. I've got the same problem. I want to put the absolute path of the images, because I need it for a e-mail bulletin.
This is my solution:
In the file [path to editor]/editor/filemanager/connectors/php/config.php, find the $Config['UserFilesPath'] line and put something like:
Re: How to display the absolute path of the image?
my solution is