Skip to content

Instantly share code, notes, and snippets.

@aquasmit
aquasmit / file uploading checklist - php.ini
Created May 27, 2015 20:23
file uploading checklist - php.ini
file_uploads on (or true or 1)
upload_tmp_dir NULL
post_max_size 8M
upload_max_filesize 2M
max_execution_time 30 (in seconds)
max_input_time -1 (no limit)
memory_limit 128M
@aquasmit
aquasmit / wamp-server-network-access
Last active August 29, 2015 14:21
Apache 2.4.x - Allow wamp server access from any machine in network using http://
Open httpd.conf and replace line
Require local
by
Require all granted
That's all. After you restart Wamp server, you will be able to access your machine frm any machine in network using URL like http://aquasmit (assuming that aquasmit is your machine name)
@aquasmit
aquasmit / javascript-getelements
Last active August 29, 2015 14:21
JavaScript - getElements
(function(){
console.log(document.getElementById('mainHeading'));
console.log(document.getElementsByClassName('heading'));
console.log(document.getElementsByTagName('p'));
console.log(document.getElementsByName('txtName'));
//get first <p> element
console.log(document.getElementsByTagName('p')[0]);