Move all session_id and check calls function calls that we have to Session class
In Login class use new false return for session set check
Be sure all session set variables are unset, do extra unset call and
destroy call on close session
Login class does not set GLOBALS anymore (DEBUG_ALL, DB_DEBUG)
Update Logging to check for DEBUG_ALL from SESSION and set DEBUG_ALL on
and PRINT_ALL on.
All logging setting vars are primary via options and only if not set
there fallback to SESSION/GLOBALS and then defaults
DB:IO code for debug flag check has been updated for primary check in
config, then session/globals
Debug update for logging tester for first step to remove Basic class
call.
NOTE: after basic php unit tests are written the clean up for no longer
using Basic class has to start.
Switch to logging class for logging only needs
Various fixes in the logging class for more clear internal flags setting
and clearn up of complex type checks and debug validation checks.
Add basic debugger logging class phpunit checker (based on debug/print
and only very basic for echo)
Other minor fixes and updates (phpunit with inital dead code check)
Because we do not have double byte characters in there we use a string
so we don't have to do any array work. Return is also a string and not
an array that is then converted to string.
Add info to Colors Class for oklab code that we should use as basic for
all conversions
phpstan will throw an error because pg_* methods have changed from
resource to object in php 8.1
So current var has object|resource dual type and this will fail
Added ignore for phpstan in the config file.
Also added conditional config file for phpstan where we can set based on
current active PHP version
baseline file created with --generate-baseline is added for error check
PHP version check now works with only max too, if called with (null,
'1.2.3') then php version will be checked <= 1.2.3
Debug Support has a to string print method printToString which tries to
print all types of var content as string (bool, int, float, resource,
object, etc)
Debug Support printAr supports ##HTMLPRE## style too (flag true)
DB/IO + PgSQL is changed from is_resource check to "false" check to be
compatible with new PHP 8.1 pgsql connect interface where all resources
are changed to objects PgSql\Connect|Resource|...
If not created Logger class will be auto created in \DB\IO
Recommended to run a CoreLibs\Debug\Logging([...]); and use this class
for all ACL\Login, Admin\Backend, DB\IO, Output\Form\Generate calls.
Last parameter after DB CONFIG is the log parameter
Session create has been moved to a new Create\Session class from the
\Basic class and MUST be started before using ACL\Login. Currently
ACL\Login will fallback and start it if no session is yet started.
See the Readme.md file for which classes use _SESSION data
In future the _SESSION settings should be moved to some wrapper class
for this so we can unit test sessions
Only Output\Form\Generate class call has the new changed with the second
parameter no longer beeing the table width setting but the class
setting.
But as this is a semi retired class and only used for edit_base this is
not 100% breaking.
All other classes can be used as is and have internal fallback to run as
before.
Deprecation messages will be added later.
Add note that on change in lib/ folder (add/name/delete) 'composer
dump-autoload' must be run to update the composer auto loader as this is
currently on testing to not use internal autoloader
update all composer/vender autoload configs
Check\Basic: just apply updates in deprecated method calls
Check\Jason: has been deprecaged and moved to Convert\Json. Primary issue
was wrong name "Jason" instead of "Json"
Check\Password: only
Check\PhpVersion: fix version check for >9 numbers
Combined\Array: variable name change to be more clear, all searches are
strict for recoursive search, new option for recoursive search many to
return only found array data and no control array info. for backwards
compatible this is default set to ($old = true) and needs to be set to
false to get the new format,
array search normal has a new strict flag for forcing strict compare on
search.
remove some unneeded is_array checks,
fixed the flatten array to key to not only use leave elements, but all
array keys, if only leaves are wanted the new method
flattenArrayKeyLeavesOnly only returns key from leaves
Combined\DateTime: checkDateTime got more correct error checks on
invalid data
compareDate uses strtotimestamp for more easier compare like
compareDateTime does, both to a check on inalid timestamp now
calcDaysInterval also aborts on invalid data now
Convert\Byte: str to bytes does not drop the minus sign anymore
Convert\Colors: any error will now return false and not set to some
neutral gray. also fix missing round on hsb/hsl special return groups
Convert\Html: add constants for CHECKED/SELECTED options, fix remove
linebreak to not add two spaces if \r\n was found
Convert\Json: moved from Check\Jason and add two new error types
Convert\MimeAppName: do not set if mime type or app name is empty
Create\Hash: add crc32b to hash allows types so we can create a normal
not reversed crc32b
Create\Uids: move default hash type to var in class, fix defined
constant check
Debug\FileWriter: add log folder setting to override config constant
settings and also check if we can actually write to the folder and if
BASE and LOG constants are not empty
Get\System: add constant for getPageName and fix getHostName to be more
shorter and faster
Language\L10n: remove \Basic class extends because we don't need it
there at all
Template\SmartyExtend: fix constant check
Add test host soba-dev.tequila.jp, others will be added
config.other had errors with double define a constant
Supress phan/phpstan errors for ...array calls in methods
Smarty extended class is now included in checks and is fixed.
Add the lib/ folder to the composer.json autoloader block so we can use
the composer autoloader and not the one from CoreLibs
Added an autoloader load test backend file
Dropped old insert_id and insert_id_ext and only kepy insert_id_arr.
Added insert_id_pk_name to get the inserted pk name.
Insert RETURNING also works on non set pk name with RETURNING set
Moved the get insert (RETURNING) into method so it can be called from
both dbExec and dbExecute flow.
Error code 31 is only thrown if no returning is set and insert flow
cannot find a primary key for this table
Update all old insert_id calls from other classes
Will check if there is a read_env_file.php and then run it to load .env
file in /configs folder
This file can hold secrets that are not to be checked into git
Updated edit.js file to be eslint compatible
Update core template main body with better position for overlib init,
pagename div id add, remove px from any size call (width)
DB IO adds return for config settings, fix db async check to always
return boolean only, add had error variable return method
Some minor fixes in Smarty Extended for some legacy admin page variables
needed.
Update Error reporting to be self containing with defines
Added more tests to debug, form, system class tests
IO: max calls check return variable name was wrong
Logging: changed from preg to str replace for HTMLPRE tag clean up
Debug: empty string debug, returns filled string with dummy text if
string is empty()
System: return base name as is array
Updated Array IO check for loading control array not only from file, but
from direct variable if set or from an array filled with control array
Some code clean up in smarty class (check if $cms object is actually
set)
Logger/Support Debug clean up for some minor logic with debug prefixes
DB IO update debug prefix for log line so we can have a HTML formatted
prefix for echo output