Category Archives: Technical

“Rational” IT related entries.

Restrict page access to authorized MODx managers only

A while ago I needed to create a private zone with documentation, accessible only by the MODx managers (I’m talking about MODx Evolution here). In order to restrict access I wrote a simple snippet, which you can now use as … Continue reading

Posted in Programming, Releases | Tagged | Leave a comment

Add an <option> to a <select> using Mootools

var newoption = new Option(“option html”, “option value”); try { $(‘myselect’).add(newoption, null); } catch (err) { $(‘myselect’).add(newoption); } To select the newly created option: newoption.setProperty(‘selected’, ‘selected’);

Posted in Programming | Tagged , | Leave a comment