pupsnow / mathmleditor

Automatically exported from code.google.com/p/mathmleditor
1 stars 0 forks source link

Problem with relative path in configuration file #37

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Hi,

I have a problem with relative path. That's why I request your help. Because 
it's a WAR app, i need to use relative path in my configuration. For example, 
the final URL of the application is www.company.com/customer#1.

in configMathMLEditor.xml : <property 
id="urlGenerateImage">../../../../os/mathMLPicture</property>

mathMLPicture=servlet to save the picture and generate the path. 
This servlet generate the url "os/doc?filename="+name+"."+type;"

But the editor send a bad url to the editor 
example : 
"_mce_src="../os/os/doc?filename=21D2A817-B2F5-62E4-1164-B1DBE9BF0F35.JPG" 
src="../../../os/os/doc?filename=21D2A817-B2F5-62E4-1164-B1DBE9BF0F35.JPG"

I think that the SWF interpret the URL generate by the servlet as a relative 
URL to "urlGenerateImage" path.

I hope not to be too confusing in my explanation.

BR.

Original issue reported on code.google.com by tricot.c...@gmail.com on 21 Dec 2010 at 6:38

GoogleCodeExporter commented 9 years ago
Hi 

The swf takes from the server the absolute or relative path and always generate 
the absolue path (using the property urlGenerateImage).
But in property id="urlGenerateImage" I expected to have an absolute path.

Do this limit you?

thank you
alex

Original comment by ionel.alexandru@gmail.com on 21 Dec 2010 at 10:17

GoogleCodeExporter commented 9 years ago
Hi

It's limit me because I have many different deploiement configuration and for 
example the path to the servlet (or JSP) which generate the picture can be =
www.company1.com/path1/path2/os/generatePicture
www.company2.com/path1/os/generatePicture
www.company3.com/os/generatePicture

That's why I define the property as a relative path to the servlet.

BR

C.

Original comment by tricot.c...@gmail.com on 22 Dec 2010 at 7:12

GoogleCodeExporter commented 9 years ago
ok, I will think to have a solution

Original comment by ionel.alexandru@gmail.com on 22 Dec 2010 at 10:32

GoogleCodeExporter commented 9 years ago
Great! :-)

Original comment by tricot.c...@gmail.com on 23 Dec 2010 at 8:22

GoogleCodeExporter commented 9 years ago
try now, Let me know if you have more problems

Original comment by ionel.alexandru@gmail.com on 21 Jan 2011 at 9:42

GoogleCodeExporter commented 9 years ago
Hello,
I am very annoyed because I tested several times and I always see the same 
behavior: ok with http and bad  with https. It's very strange: (

Again thank you for the efforts

Original comment by tricot.c...@gmail.com on 25 Jan 2011 at 9:03