Categories
PHP WordPress

Optimizing default WordPress REST API user endpoint for redundant DB calls made for permissions check.

While working with one of our client at rtCamp who was using REST API for thier website with PWA theme, We found out that it was taking way too much time at user endpoint wp/v2/users/{id}

Categories
PHP WordPress

Setting up WordPress.com VIP Development Environment with EasyEngine (Nginx)

Hey there, As you know VIP Quickstart has been deprecated recently. Here is some easy way to get started with VIP development, We hope soon EasyEngine will V4 launch with VIP support but for now, lets do all thing manually. You need Ubuntu 14 / 16 LTS with sudo access also we need svn and […]

Categories
js PHP

Google Maps API drawing polygon with JSTS Librery

One of our clients has asked for a road map feature for their website. basically what he needs is A Road map that lists all places around the route. Now getting distance between two points was very easy the important thing is how to draw a polygon around the route. After a lot of browsing […]

Categories
PHP

php text to speech with google api

// Convert Words (text) to Speech (MP3) // ———————————— $word=$_POST[‘word’]; // Google Translate API cannot handle strings > 100 characters $word = substr($word, 0, 100); // Replace the non-alphanumeric characters // The spaces in the sentence are replaced with the Plus symbol $word = urlencode($word); // If the MP3 file exists, do not create a […]

Categories
PHP

Sending MIME Mail with PHP

You can send email with PHP Mailer with attachment and MIME type, with help of following libraries 1)PHP Mailer you can download latest version from github Example: php require ‘class.phpmailer.php’; $mail = new PHPMailer; $mail->IsSMTP(); // Set mailer to use SMTP $mail->Host = ‘smtp1.example.com;smtp2.example.com’; // Specify main and backup server $mail->SMTPAuth = true; // Enable […]

Categories
PHP

Way2sms PHP API

Hello , build your own sms base application in php with this way2sms api interface post comments and queries /** * sendWay2SMS * Function to send to sms to single/multiple people via way2sms * @author Milind * @category SMS * @example sendWay2SMS ( ‘9000012345’ , ‘password’ , ‘987654321,9876501234’ , ‘Hello World’) * @url http://milindmore22.blogspot.in/2012/07/way2sms-php-api.html * […]