fbpx
35 C
Lahore
- Advertisement -spot_img

TAG

Code Snippets

PHP: How to fix Image rotation issue in img tag because of EXIF

Photos captured by some smartphones especially iPhones are automatically rotated when we use it in <img> tag which is mostly not acceptable as we...

PHP: Array Version of htmlspecialchars() function

htmlspecialchars() function should be used for security reason to echo values from any variable. But htmlspecialchars() doe's not work for arrays so following function would...

How to Change Bootstrap Carousel Slide Speed

The speed cannot be controlled by the API. Though you can modify CSS that is in charge of that. find in the bootstrap.css file: .carousel-inner...

How to lock screen orientation to portrait or landscape?

This article will show you how to lock screen orientation to one direction. Environment Details: - Phonegap Build - cli-5.2.0 - Device: iPhone S5 9.3.2 For locking orientation to...

SSH: How to stop a script running in the background?

Open/Login SSH into the server Type in ps x See the list of processes currently on your server Get the PID(process id) from...

PHP: How to run / execute a script in the background forever through SSH ?

You can execute a php script in the background forever by using SSH through PHP but for that you have to make sure first...

Cordova: How to download file and get download progress?

var assetURL = 'http://www.anywebsite.com/test.mp3'; var store = cordova.file.externalRootDirectory; // output in android: file:///storage/emulated/0/ // or // var store = "cdvfile://localhost/persistent/"; var fileName = 'Sounds/test.mp3'; // NOTE: Sounds folder should...

Cordova: How to check if a file exists or not?

document.addEventListener("deviceready", init, false); //The directory to store data var store; //File name of our important data file we didn't ship with the app var fileName = "testfile.txt"; function init()...

Cordova: How to get list of all Files/Directories in a directory?

function success(entries) { var i; for (i=0; i<entries.length; i++) { console.log('En...

Cordova: How to create directory?

/* ############ # Method 1 # ############ */ // output in android: file:///storage/emulated/0/ var base_url = cordova.file.externalRootDirectory; // or // var base_url = "cdvfile://localhost/persistent/"; var new_directory = 'TEST'; // To Create a sub...

Latest news

- Advertisement -spot_img