Initial commit

This commit is contained in:
Rayhan Hanaputra
2025-10-10 22:18:06 +07:00
committed by GitHub
commit ea02892f14
1246 changed files with 289342 additions and 0 deletions
@@ -0,0 +1,23 @@
<?php
namespace Utils;
class Util {
public function isAlphaNumeric($str){
return preg_match("/^[a-zA-Z0-9]+$/", $str) ? true : false;
}
public function alphaNumeric($str, $default = ''){
return preg_match("/^[a-zA-Z0-9]+$/", $str) ? $str : $default;
}
public function alertExit($str, $back = 1){
echo "<script>alert(`$str`); window.location.href = '/';</script>; if($back) history.back();";
;
exit();
}
}