Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

SitePoint PHP Blog:
The Android Elephpant - Laravel on your Android Phone?
Mar 14, 2017 @ 18:06:05

On the SitePoint PHP blog there's a new tutorial posted with an interesting idea for the use of PHP - running it on an Android phone (a Laravel application specifically).

It was not that long ago that Christopher Pitt wrote an excellent article about writing and running PHP code on an iPad. After reading it, I thought to myself "It would be really cool to do the same on Android": being able to write and edit code on the fly, for example while traveling, and not having to take the laptop everywhere. So I’ve decided to do some research and see what I could come up with.

For this article, you can use any type of Android device. I’ve done it on my phone, but an Android tablet with a Bluetooth keyboard would probably be the ideal setup.

Using the Termux application and using it to install various packages for both development and PHP usage. They also install Vim, Git and Composer to make package management easier. Once the environment is installed it moves on to the Laravel installation (that works just fine), installing SQLite for the database and building out the user authentication and authorization handling with Laravel's "make:auth" artisan command.

tagged: android tutorial phone laravel install configuration

Link: https://www.sitepoint.com/android-elephpant-laravel-android-phone/

Laravel News:
New Community Project: Laravel Notification Channels
Aug 15, 2016 @ 15:53:13

On the Laravel News site there's a new post talking about a new community effort that's been started in the Laravel ecosystem centering around notification channels. A "notification channel" is a method used to interact directly with your users - in this case using Pusher notifications via a simplified interface.

Laravel 5.3 will ship with a notification system that includes a Nexmo SMS driver, a Mail driver, and the ability to include custom drivers. Now that we have this system built-in we can use the new Pusher service from inside our Laravel applications.

All we need to do is to create a custom driver and that’s it, we’ll be able to send Push notifications to our Mobile devices right away. With the help of Freek Van der Herten and Marcel Pociot we managed to build an easy to use driver for Pusher Push Notifications.

The Pusher system not only allows sending messages to you users via the web but also push notifications to mobile devices (iOS and Android). A simple code snippet is included showing the Laravel-centric interface to the functionality and a link to more code examples on a GitHub repository. The post ends with a brief section about creating customer drivers as well.

tagged: laravel community project notification channel pusher ios android

Link: https://laravel-news.com/2016/08/new-community-project-laravel-notification-channels/

SitePoint PHP Blog:
Mobile App Development with Zend Studio
Jun 29, 2015 @ 15:14:41

On the SitePoint PHP blog they've posted a new tutorial from Daniel Berman about using Zend Studio to create mobile applications in the same interface you're using (if you're a Zend Studio user) to create your PHP applications.

The world has turned mobile. This is not new, and it should therefore be no surprise to anyone that the results of the 2015 DevPulse survey by Zend show that a vast majority of PHP developers are working on, or intend to work on, mobile apps.

Mobile app development poses many challenges for developers, one of which is tying in the front end of the mobile application with the back-end web service APIs. This tutorial describes how to simultaneously create, test and modify both the front and back end of a modern mobile app using Zend Studio’s mobile development features.

He breaks the rest of the post up into several steps to help you get a simple mobile project up and running, complete with a basic Apigility API backend:

  • Creating a Cloud Connected Mobile Project
  • Previewing your App
  • Developing the Back-End APIs
  • Developing the Front-End
  • Testing as an Android Native App
  • Exporting a Native Application Package

The end result is a simple "cloud connected" application that can be installed directly on an Android device as a ".apk" package.

tagged: tutorial mobile application zendstudio android api apigility

Link: http://www.sitepoint.com/mobile-app-development-zend-studio/

Three Devs & A Maybe Podcast:
Paranoid Android
Oct 10, 2014 @ 16:24:48

The latest episode of the Three Devs & A Maybe podcast has been released - episode #46: Paranoid Android. Join hosts Michael Budd, Fraser Hart, Lewis Cains and Edd Mann as they talk about PHP libraries, freelancing and more.

This week we start off the discussion with our bad pronunciation of PHP libraries. We then move on to highlight the stress of wrapping up freelance projects - with clients constantly requesting changes (mission creep). Finally, we chat about Google Web Designer and the new Alan Turing movie (The Imitation Game).

Other topics mentioned include the Trello service, making custom jQuery events and PHP's imagick image handling. You can listen to this latest episode either through the in-page audio player or by downloading the mp3 of the show. You can also subscribe to their feed if you enjoy the show and want to hear more great episodes.

tagged: threedevsandamaybe podcast ep46 paranoid android

Link: http://threedevsandamaybe.com/paranoid-android/

MakeUseOf:
Create The Perfect PHP Development Environment In Android
Mar 05, 2014 @ 16:39:17

On the MakeUseOf site there's a recent post showing how you can create the "perfect PHP development environment" on your Android-based device. Obviously, it's much more useful on a tablet, but in theory it could be used on a smartphone.

It turns out you can actually code on Android productively. For the longest time, it has been accepted that whilst computers are for productivity and creativity, Tablets exist purely to allow the passive consumption of content. I believed that as well. I’m a software developer by trade, and I use a 13" Macbook Pro to write all my code. I wouldn’t have it any other way. OS X comes with everything I need to be productive as a developer, and I’ve built my workflow around that. Android on the other hand? I’ve never really thought about writing code on Android. [...] But then I bought a decent Bluetooth keyboard, and everything changed. I’ve now built a PHP development environment around my 2012 Nexus 7 tablet, and I love it.

He breaks it down and shows some of the tools he uses for his development including the use of VIM Touch for editing and the Palapa Web Server for local hosting of his applications. Screenshots of the setup and configuration are also included.

tagged: development environment android vimtouch palapa webserver

Link: http://www.makeuseof.com/tag/create-perfect-php-development-environment-android/

Gonzalo Ayuso:
Sending Android Push Notifications from PHP to phonegap applications
Aug 06, 2013 @ 15:26:09

Gonzalo Ayuso has a new post today showing how he set up Android push notifications to a Phonegap-based application with PHP.

Last days I’ve been working within a Phonegap project for Android devices using Push Notifications. The idea is simple. We need to use the Push Notification Plugin for Android. First we need to register the Google Cloud Messaging for Android service at Google’s console, and then we can send Push notifications to our Android device.

He includes the steps you'll need to push the notification and the library to make the cURL connection out to the Google messaging platform. He's posted the full code out to github.

tagged: phonegap android push notification google cloud tutorial

Link: http://gonzalo123.com/2013/08/05/sending-android-push-notifications-from-php-to-phonegap-applications

Community News:
Make PHP-Based Android Applications with Zend Studio 10
Oct 24, 2012 @ 16:54:26

At this year's ZendCon conference a new technology was introduced (well, and upgrade to an existing product) that allows PHP developers to create Android applications from Zend Studio 10.

ZendCon, the annual trade show for Zend, the PHP company, announced that Zend Studio 10 (Zend’s IDE) will include functionalities that will let PHP developers prototype and build native mobile apps using PHP. The new capability includes a drag-and-drop mobile interface builder, integration with the Apache project’s Cordova to access native mobile APIs such as those for cameras and accelerometers, and built-in PhoneGap integration for developers to publish native app packages to the various app stores.

You can see an example of the software in action here (video) and get a bit more information about the offering from this article from VentureBeat.

tagged: android application phonegap zendstudio integration update

Link:

Android Hive:
Android Push Notifications using Google Cloud Messaging (GCM), PHP and MySQL
Oct 17, 2012 @ 13:53:04

On the Android Hive there's a recent tutorial posted showing you how to use Google Cloud Messaging and PHP+MySQL to do push notifications on an Android phone.

As per google’s documentation “Google Cloud Messaging for Android (GCM) is a service that helps developers send data from servers to their Android applications on Android devices”. Using this service you can send data to your application whenever new data is available instead of making requests to server in timely fashion. Integrating GCM in your android application enhances user experience and saves lot of battery power.

You can either follow along with the tutorial via the screencast (and download the code) or you can read through the text version, complete with code snippets, SQL and screenshots to help you along the way. The code for the Android side is included as well.

tagged: push notification android tutorial googlecloudmessaging mysql

Link:

PHPMaster.com:
Let's Talk: Efficient Communication for PHP and Android, Part 2
Jun 05, 2012 @ 18:19:33

On PHPMaster.com today they've posted the second part of their series looking at combining a PHP backend and an Android application (by Matt Turland). In the previous article, he helped you set up some of the Android side to be able to reach out to a PHP web service. In this second part he gets into the sending and receiving of messages between the client and server.

Part 1 of this series focused on getting the Android application set up to make an HTTP request. In part 2, we’ll focus on implementing the use of data serialization and compression on the Android and PHP sides of the request.

He has it broken up into the different steps of the process:

  • Determining the Data Serialization Format
  • Determining the Data Compression Format
  • Sending the Response
  • Decompressing the Response
  • Deserializing the Response

He also includes a section about caching the responses you get back from the server, an important step that can save you (and your users) some headaches and maybe even give a bit of a speed boost.

tagged: android webservice data serialization compression response

Link:

PHPMaster.com:
Let’s Talk: Efficient Communication for PHP and Android, Part 1
May 28, 2012 @ 21:20:09

On PHPMaster.com today, they've started a new series about integrating two popular technologies - PHP and the Android OS - in this new tutorial from Matthew Turland. He'll show both sides of the code needed to get your Android app talking to a PHP backend.

This two-part article will guide you through the process of building an efficient PHP-based REST web service to be consumed by an Android-based application. Some of the concepts presented here are also applicable to other mobile platforms, such as iOS. I assume you already know the basics of PHP and Android development and that you have a suitable development environments set up for both. I’ll focus mainly on showing you how to handle data serialization and compression in both environments.

In this first part, he starts from the client side, creating the code (Java) that's needed to create the connection to the backend. He stets it up as a background task so its execution won't block the main app from working. He shows how to execute it, running an "on create" method and checking to ensure the network is available for the request.

tagged: tutorial android communication backend mobile java

Link:


Trending Topics: