Canvas element added to drop a dup of our image into
4 input boxes also added to show current mouse XY hex & RGB values and
similar values when clicking the canvas image.
New flags added to stop closing the popup unless we click outside of
these elems
Finally, split everything onto multiple lines for readability
To set it to Unix as the default. Opening files with \n line endings in
relatively modern programs will know to use line breaks here if not the
native OS preference
We weren't getting the new filemtime after saving and using the
$filemtime var value prior to the save. Needs to be reestablished prior
to setting the array value.
If the dir exists, run thru from 2 to 1billion looking for next
available number and set the $dest name as that. All exactly the same as
how it works for pasting files.
Ternary expression to get same saveType results
Create a new $filemtime var and set to 1000000 for non Linux systems
We now have something to compare with
(Tho will always be this on Windows etc)
Detect if the finfo_open function is available and if not, grab the file
extension and compare against an array to work out accepted text based
and image based file types to know wether to open in editor or pop open
as an image
Allow 'empty' to appear in the MIME type, so we can accept things such
as application/x-empty, which indicates an empty file. Wouldn't open
them previously.
This is so & becomes & ...what you draw out of the textarea
is then &
In turn this allows all HTML entities of this style to work and as we
aren't using PHP's htmlentities(), we don't end with junk chars on
slanted apostrophes, degree symbols etc.
Test if the rename has taken place and only if it has, call
updateFileManagerList etc. If it hasn't set the renamed var to false. If
renamed var is false, show the improved error message (gives note on
permissions).
Calling updateFileManagerList now includes a 6th argument and if a true
value is passed, then it's indicating an uploaded file and shouldn't set
the openFiles array value.
This function will get uploaded file details for each file uploaded and
when uploaded, move the file to the user selected folder. Also shows
error message if there is an issue. Either way, when finished it will
clear the selectedFiles, file menu and hide the loading mask to return
user to normal view.
$dest now has double slashes replaced with singles
Now also considers if a file exists before copying
If it does, next available number up to 1 billion postfixed to end of
filename
Copy with that new filename, next number postfixed
Slight adjust to filename shown in file manager to match
Looks to see if the location is writable and if so, copy our file to
that location
Then adds the new file to the file manager, otherwise, informs you it
couldn't do it
Clears server message eitherway
You cannot get access to ICEcoder unless you have logged in, so
restrictedFiles is not needed anymore
Removed it and all instances of it's usage
Only updating pluginsContainer if it's a DOM elem
Change title tag of login/set password screen conditionally
Moving away from the idea of multiple user levels, users will either
have full access or no access
Swapped all userLevel session vars to a loggedIn var, which is a bool
Makes things simpler and paves the way towards the new login screen
(before you see any files, code etc)
Upon replaceText being needed, we detect if we have a high enough
userLevel and if it's writable, if not provide an appropriate message to
the user
Otherwise - read, replace and save the new content with the find/replace
combo requested
Clear the server message and item from the queue
If for some reason the createNewCMInstance function isn't ready &
available, reload the iframe containing file-control.php which works
with the issue by giving more time and leave a note in the console.log.
Also move everything to do with the the loading process into the
successful part of the if condition.
Redo layout on loading of file to avoid occassional broken layout issues
Wrap all load processes in a 4ms timeout to avoid DOM & JS availability
errors
If we're saving a new file, fileLoc is the file location otherwise it's
empty
Error catching given filenames not beginning with a / by prefixing with
one
No need to conditionally define $file on action/contents
$file is now either existing or new filename
Converted to fullpath and fileLoc and fileName established from this
Extension checking on fileName now not full path ($file)
Variable reassignment, fileName now used much more
Path realignments in many areas
Big chunks of code removed, simplified or made singularly available
Better error handling & code optimisation/shortening
Now making $file the common filename (instead of $saveFile)
This is changed to a full path now as we receive a relative path
$fileName and $fileLoc chunks worked out from this
isset catching on newFileName before looking at value
Renaming the tab on saving new file
htmlentities wrapped around loaded file on overwrite collision
Not giving away fullpath info on unwritable files if we're not logged
Conditional getInput dialog prompt
Simplified code in quite a few areas
Newly created folders no have 705 perms and / is r'trimmed from docRoot
(as iceRoot is prefixed with a /)
The short URL used in getInput prompt dialog now has // replaced with /
to error catch
Was previously passing back the full path to updateFileManagerList. Now
removing the docRoot portion and so now passing back a relative path.
Removed old shortURL starts substr, no longer needed.
Stops conversion of entities such as & to &. Obviously we want it to
be exactly the same as the loaded file and this should ensure that is
the case.