docRoot defined in settings.php now so no need to set
docRoot swapped for iceRoot in a few areas (there were kind of one and
the same before, ugghh)
Conditionally prefix file refs with $docRoot and/or $iceRoot if
different paths are needed
Removed shortURLStarts - too inefficient & problematic
Only on winow load begin to createNewCMInstance
(In the rare case the files frame loads before the editor frame)
Code simplified in a few areas
causes probs if you have the same term more than once in your path
(ie, var/www/mysite/www), previously took first www
Now takes last one and solves path issues in quite a few areas
All server variables such as codeMirrorDir, visibleTabs etc now in
$ICEcoder array
This is so we have a single object to contain all settings, just like
the JS equivalent
alert calls now routed to message function
confirm calls now routed to ask function
prompt calls now routed to getInput function
This is so you can replace how these are handled if you wish
(Useful if you want to get away from browser chrome & UA dialogs)
New function to change permissions on request
Takes permission & applies top file/folder
Then updates file manager tree and server message
If it can't be changed, provide alert message
Setting innerHTML works fine in Chrome & Firefox but not IE
In order to make IE compatible, made this improvement
(More syntactically appropriate anyway)
Insetad of notifying user that file they're attempting to save, now they
can revert
This means the file they're trying to save is reverted to the server
file
Changes they have made are copied into a new file
User can optionally cancel to avoid this
Hex codes shortened if poss (ie, #888888 becomes #888 and #ff0000
becomes #f00)
Swapped text colour on tabs, selected now has black text, others white
text
Wrapped an additional if around the save operations
This is to check if we have latest file, allowing collab edits
(if we attempt save and don't have latest modified date time, alert user
Other minor updates to work with new MDT vars, params, arrays
clearstatcache necessary to get latest modified datetime
When you save, if there is a stickyTab window, it reloads
Popups for images now have white glow around them, plus fix to text color
Moved clearing the server message to cover images too
Now asks for overwrite permission if saving new file or save as over another file
Server message now shows your new filename when saving
Error catching so if not saving it clears server message
When an action is performed (or not performed due to error), it is cleared from the server queue
Saving is now done from the saveTemp1 textarea element (a snapshot when save is requested by user)
Alerts now show when an action cannot be taken (such as not having permission to save file etc)
Clearing of serverMessage upon successfully processing action
Adding, editing or removing file or folders now triggers function to update manager
Previously it reloaded the file manager, but this is no longer needed
Overall result is that it works much faster, you don't lose your opened tree structure etc
PHP will now load content into textarea container, but replacing </textarea> with altered tag
This ensures the actual textarea container isn't escpaed early
This replacement is reversed back to the original by the contentCleanup function
Tab now renamed on saving file under new name
Clear history moved to a repurposed contentCleanUp function in JS file
Clear & set active line class to line 1
Global variables removed from JS file
Plugins system evolved, now including setInterval
Seperate CodeMirror instances per tab
backupOpenFiles plugin created
Minor fixes & improvements