Umbraco TinyMCE - No Absolute URLs in Insert / Update Link

it made me crazy for several hours, I managed to fix it on my local development machine, and of course when I said that it didn’t work.

Here is what I did in setting up Umbraco:

in the Config / tinyMceConfig.Config file, I added:

<config key="relative_urls">false</config> <config key="convert_urls">false</config> <config key="remove_script_host">false</config> 

I also made corrections to the Javascript code in insertLink.aspx to set localUrl to empty, as this made it work on dev machine. Does anyone know how to fix this really dumb error on my real server?

thanks

+4
source share
1 answer

Unfortunately, you cannot override "remove_script_host" because it is hardcoded in umbraco.editorControls.tinyMCE3.TinyMCE:

Line 250: config.Add("remove_script_host", "true"); .

And when you add a new value to the configuration file - you will get "true, false" instead of "false" , because of the NameValueCollection it is used.

And as we know, when you add 2 elements with the same key in NameValueCollection, as a result you will have a concatenation of these two values ​​with a comma separator .. p>

Therefore, do not waste time figuring out what is wrong with your "remove_script_host" configuration.

+1
source

Source: https://habr.com/ru/post/1433385/


All Articles