This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
//session_start(); | |
header('Cache-control: private'); // IE 6 FIX | |
function showUrl($lang){ | |
$url = basename($_SERVER['REQUEST_URI']); | |
if(isset($_GET['page'])){ | |
$url = "?page=".$_GET['page']; | |
$url .="&lang=".$lang; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function isNumeric(n) { | |
return !isNaN(parseFloat(n)) && isFinite(n); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
if(isset($_GET['uid']) && isset($_GET['mid'])){ | |
$mailid = (int)$_GET['mid']; | |
$userid = (int)$_GET['uid']; | |
$db = new mysqli_connect('databaseserver', 'databaseuser', 'databasepassword', 'databasename'); | |
$db->query("INSERT INTO mailreaders (mailid, userid) VALUES ($mailid, $userid)"); | |
$im=imagecreatetruecolor(1,1); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$('#e_form').each(function() { | |
this.reset(); //Here form fields will be cleared. | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@charset "utf-8"; | |
@import "reset.css"; | |
/* GLOBAL CSS | |
-------------------------------------------------- */ | |
/* RESPONSIVE CSS | |
-------------------------------------------------- */ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* http://meyerweb.com/eric/tools/css/reset/ | |
v2.0 | 20110126 | |
License: none (public domain) | |
*/ | |
html, body, div, span, applet, object, iframe, | |
h1, h2, h3, h4, h5, h6, p, blockquote, pre, | |
a, abbr, acronym, address, big, cite, code, | |
del, dfn, em, img, ins, kbd, q, s, samp, | |
small, strike, strong, sub, sup, tt, var, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* CONFIG */ | |
define("DB_HOST", "localhost"); | |
define("DB_USER", "root"); | |
define("DB_PASS", ""); | |
define("DB_DATABASE", "my_db"); | |
/* CONNECTION */ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function random_password($chars = 8) { | |
$letters = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789.-+=_,!@$#*%<>[]{}'; | |
return substr(str_shuffle($letters), 0, $chars); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function getURLParameter(name) { | |
return decodeURIComponent((new RegExp('[?|&]' + name + '=' + '([^&;]+?)(&|#|;|$)').exec(location.search)||[,""])[1].replace(/\+/g, '%20'))||null; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$max_file_size = 5*1024*1024; //5MB | |
$path = "admin/upload/"; // Upload directory | |
//$count = 0; // nr.successfully uploaded files | |
$valid_formats = array("rar","zip","7z","pdf","xlsx","xls","docx","doc","txt"); | |
$valid_formats_server = array( | |
"application/pdf", | |
"application/octet-stream", |
OlderNewer