How to install nginx-vod-module on CentOS

How to install nginx-vod-module – NGINX-based VOD Packager – on CentOS? Step 1: Result: Step 2 Result: Done, now you can use this file to test nginx-vod-module: https://github.com/kaltura/nginx-vod-module/blob/master/test/nginx.conf

Read full story Comments { 0 }

PHP: how to save a remote file using CURL

How to save a remote file using CURL? You can read more about CURLOPT_WRITEFUNCTION in this article: PHP: Example of usage CURLOPT_WRITEFUNCTION

Read full story Comments { 0 }

PHP: upload file to FTP server

How to upload file to FTP server using PHP?

Read full story Comments { 0 }

PHP: How to check if a remote file exists

Main method is read header file, so, you can read 2 article first: PHP: How to get size of a remote file PHP: How to get size of a remote file – Part 2 Here, we give some methods: Method 1: Example: Result:

Read full story Comments { 0 }

How to build nginx-vod-module on CentOS

How to build nginx-vod-module – NGINX-based VOD Packager – on CentOS? Step 1: First, you must install some requirements like: git, gcc, gcc-c++ Install GIT Install GCC, GCC-C++ Step 2: Step 3: Result: Step 4: Installing NGINX Dependencies 1. The PCRE library – required by NGINX Core and Rewrite modules and provides support for regular […]

Read full story Comments { 0 }

How to build the OpenSSL library on CentOS

We make an example on CentOS 7 64bits. Step 1: Result: make make install

Read full story Comments { 0 }

How to build the zlib library on CentOS

We do an example on CentOS 7 64bits Step 1: Result: Step 2: Result: Step 3: Step 4:

Read full story Comments { 0 }

How to build the PCRE library on CentOS

Here we make an example for CentOS 7 64bits Step 1: Step 2: Result: Step 3: Step 4: Result: Step 5: Step 6: Done!

Read full story Comments { 0 }

How to protect password a folder in Nginx

Example: we need protect folder /home/nginx/domains/tutorialspots.com/public/secure with a username and password. Step 1: login server via SSH Step 2: create file .htpasswd eg: /home/nginx/domains/tutorialspots.com/public/secure/.htpasswd you can replace username with your name login eg: admin Then you will see: Example result: You will get file .htaccess with content like: You can use this command to generate […]

Read full story Comments { 0 }

JS: Calculate Distance Between Two Coordinates

This routine calculates the distance between two points (given the latitude/longitude of those points). It is being used to calculate the distance between two locations: Example: Result: 423232.8593012345 Note: Result as meters Ellipsoidal parameters: Name Major axis, a (km) Flattening (f) WGS84 6378.13700 1/298.257223563 GRS80/NAD83 6378.13700 1/298.257222101 WGS66 6378.145 1/298.25 GRS67/IAU68 6378.16000 1/298.2472 WGS72 6378.135 […]

Read full story Comments { 0 }