• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Not planned JavaScript Modification

AndyB

Well-known member
#1
Often we need to modify the core Javascript files to achieve the functionality we want. Of course at upgrade time this requires redoing the modifications manually.

It would be great to see a Javascript Modification function similar to Template Modification. That way we could create add-ons for the core Javascript changes.
 

Rigel Kentaurus

Well-known member
#3
Could you give an example of when you needed to modify javascript files?

I have hardly had to do that, I write my own javascript files and that is enough. Only exception might be the redactor icons, and I am sure that can be worked around :)
 

AndyB

Well-known member
#4
Could you give an example of when you needed to modify javascript files?
I modify three of the core Javascript files for the following reasons:

1) Remove some Redactor icons
2) Remove some HTML tags when text is pasted into the editor
3) Remove overlay trigger when username is clicked
 

AndyB

Well-known member
#7
Allowing any form to write to files that arbitrarily get run by your server or a client computer is a very, very bad idea for security reasons.
We can already include Javascript into templates using the Template Modification system, not sure how that is any less of a security risk?
 

Jeremy

Well-known member
#8
Including via templates and directly writing to your server are two completely different notions of security. Allowing scripts to write to your server and modify files is completely different then placing an include into a template.
 

AndyB

Well-known member
#9
When a template includes the <script>JavaScript code</script> could it include any JavaScript code just like the .js file?