About phptuts

Author Archive | phptuts

Cordova lesson 2: Create the App

Go to the directory where you maintain your source code, and create a cordova project: This creates the required directory structure for your cordova app. By default, the cordova create script generates a skeletal web-based application whose home page is the project’s www/index.html file. Example: Cordova project directory structure Directory structure Cordova CLI works with […]

Read full story Comments { 0 }

Cordova lesson 1: Installing the Cordova CLI

The Cordova command-line tool is distributed as an npm package. To install the cordova command-line tool, follow these steps: 1. Download and install Node.js. On installation you should be able to invoke node and npm on your command line. Read more: How to install NodeJS on Centos 2. (Optional) Download and install a git client, […]

Read full story Comments { 0 }

Enable Auto Import in Android Studio

Introduce: By default, when programming languages such as C/C ++, C #, Swift, or Java, you must declare yourself the libraries that contain the methods or classes we use, with C/C ++ using #include, with C# uses using using with Swift and Java using the Import keyword. And sometimes they just remember the class name […]

Read full story Comments { 0 }

GMaps: how to open all infoWindow when loaded map

Simple you can do it with some simple line code: Example:

Read full story Comments { 0 }

Javascript: how to unshift an object?

How to unshift an object in Javascript? Here my method: Example: Result:

Read full story Comments { 0 }

Javascript: how to reverse an object?

How to reverse an object in Javascript ? Here my method: Example: Result:

Read full story Comments { 0 }

Date setTimezoneOffset method

As you all know, all date methods work only in the context of local time (user) or UTC, but sometimes you want to work in other contexts (time zones), the standard js forgot about the antagonist for getTimezoneOffset, and this is my method: Result:

Read full story Comments { 0 }

How to chmod folders or files only

To chmod folders only, you can use command: To chmod files only, you can use command:

Read full story Comments { 0 }

Using FTP with VPSSIM on CentOS

Use vpssim menu: Choose menu 9 then choose sub-menu 5 to setup FTP server: Now you will see this screen: Type 1 to create an FTP account, then type your domain like: tutorialspots.com

Read full story Comments { 0 }

How to create websocket secure by using NodeJS

Method 1: In this article: How to run a https website with Nodejs, express and socket.io Method 2: use NGINX file .conf Now, you can use websocket to create websocket secure: Read more: Example chat application using Nodejs + Socket.io Example chat application using Nodejs + ws Example chat application using Nodejs + Websocket

Read full story Comments { 0 }