JQuery file to add Scroll to top button in website

Just add the below file before your </body> tag, thats it…

Download Scroll to Top File

and change image name on Line no. 18

Enjoy…

Advertisements

Extract ZIP file using PHP code

<?php
// assuming file.zip is in the same directory as the executing script.
$file = ‘file.zip’;

// get the absolute path to $file
$path = pathinfo(realpath($file), PATHINFO_DIRNAME);

$zip = new ZipArchive;
$res = $zip->open($file);
if ($res === TRUE) {
// extract it to the path we determined above
$zip->extractTo($path);
$zip->close();
echo “WOOT! $file extracted to $path”;
} else {
echo “Doh! I couldn’t open $file”;
}

?>