FilesRead (line
124)
Read files in a directory
array
FilesRead
(string $strDir, [string $strFileToSearch = ''], [boolean $isSimple = false])
-
string
$strDir: searched directory (relative)
-
string
$strFileToSearch: which file to search
-
boolean
$isSimple: if true then with $LastModified
lb2string (line
110)
replace linebreaks to
void
lb2string
(string $string, [string $replace = '<br>'])
-
string
$string
-
string
$replace: what to replace
putToArray (line
164)
Put things into an array
Helper function used in regular expression search to creates an array usable for instance by $_SESSION['references']
array|content
putToArray
(string $content, array &$arrayToPut, [boolean $print = false])
-
string
$content
-
boolean
$print: do print?
-
array
&$arrayToPut: put in which array
replaceHTMLcode (line
94)
Replace difficult code characters
For instance with javascript overlib it collapse to have in abstracts or notes a single quote
void
replaceHTMLcode
( $string)
tabprint (line
32)
Print a pretty table to save
Used for references. Usage eg.:
call_user_func('tabprint', $SQL-
Result-
Array, MySQL-
Table-
Definition, $addStructure)
It tries to change fields according to MySQL table fields
HTML
tabprint
(array $arrTabFieldData, array $arrMysqlTableStructure, [array $addStructure = array()], [array $addElements = array()])
-
array
$arrTabFieldData: values from MySQL data table
-
array
$arrMysqlTableStructure: MySQL table structure
-
array
$addStructure: additional HTML elements as array. Array key = data base field e.g.
array(
'name_author' => ' disabled class="disabled" '
);
-
array
$addElements: additional input elements as array. Array key = data base field e.g.
array(
'id' => ' <input ...> '
);
user_sortwords (line
194)
Sort comma lists by patternSplit or arrays to strings
string|false
user_sortwords
(mixed $words, [bool $isUnique = TRUE], [string $patternSplit = " *, +"], [string $patternJoin = ", "])
-
mixed
$words: string with commas or array
-
bool
$isUnique: should sorting be unique?
-
string
$patternSplit: the pattern to split the string
-
string
$patternJoin: the pattern to join the string again