Merge branch 'master' of https://git.seemsleg.it/ef/php-func-lib into
HEAD Conflicts: string.php
This commit is contained in:
commit
90fe919d65
12
_func.php
12
_func.php
@ -1,10 +1,10 @@
|
|||||||
<?php
|
<?php
|
||||||
// include ('config.php');
|
// include ('config.php');
|
||||||
include ('sql.php');
|
include_once ('sql.php');
|
||||||
$sql = new SQL ();
|
$sql = new SQL ();
|
||||||
include ('string.php');
|
include_once ('string.php');
|
||||||
include ('numbers.php');
|
include_once ('numbers.php');
|
||||||
include ('mail.php');
|
include_once ('mail.php');
|
||||||
include ('debug.php');
|
include_once ('debug.php');
|
||||||
include ('markdown.php');
|
include_once ('markdown.php');
|
||||||
?>
|
?>
|
||||||
@ -1,5 +1,5 @@
|
|||||||
<?php
|
<?php
|
||||||
define ( 'SQL_LOG', 1 ); // schreibt sql querys in eine log
|
if (!defined('SQL_LOG')) define ( 'SQL_LOG', 1 ); // schreibt sql querys in eine log
|
||||||
|
|
||||||
$_m['host'] = 'localhost';
|
$_m['host'] = 'localhost';
|
||||||
$_m['user'] = '';
|
$_m['user'] = '';
|
||||||
|
|||||||
2
sql.php
2
sql.php
@ -8,7 +8,7 @@ class SQL {
|
|||||||
public $cnt_get = 0;
|
public $cnt_get = 0;
|
||||||
public $cnt_set = 0;
|
public $cnt_set = 0;
|
||||||
public function __construct() {
|
public function __construct() {
|
||||||
require ('secret.php');
|
require_once ('secret.php');
|
||||||
|
|
||||||
$this->m = $_m;
|
$this->m = $_m;
|
||||||
$this->pre = $_m ['pre'];
|
$this->pre = $_m ['pre'];
|
||||||
|
|||||||
@ -50,8 +50,8 @@ function endsWith($haystack, $needle) {
|
|||||||
|
|
||||||
return $length === 0 || (substr ( $haystack, - $length ) === $needle);
|
return $length === 0 || (substr ( $haystack, - $length ) === $needle);
|
||||||
}
|
}
|
||||||
function onlyAlpha($str, $auch = '') {
|
function onlyAlpha($str) {
|
||||||
return preg_replace ( "/[^a-zA-Z0-9 \-\_" . $auch . "]+/", "", $str );
|
return preg_replace ( "/[^a-zA-Z0-9 \-\_]+/", "", $str );
|
||||||
}
|
}
|
||||||
function shortener($str, $len = 50, $fill = '...') {
|
function shortener($str, $len = 50, $fill = '...') {
|
||||||
if (strlen ( $str ) > $len) {
|
if (strlen ( $str ) > $len) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user