[General Topics] benkxda:
Code editors

To write code, you'll need code editors and some of them are quite good for doing that. Try some of these following, if you don't have any yet.

AIDE Web - Html,Css,JavaScript - paid: IAP

Updated: December 11, 2014

Current Version: 1.0.3beta

AWD - PHP/HTML/CSS/JS IDE - paid: IAP

Updated: April 30, 2015

Current Version: 0.41

XDA application thread by [MENTION=4110849]divers[/MENTION]

DroidEdit (free code editor) - paid: DroidEdit Pro (code editor))

Updated: March 03, 2015

Current Version: 1.23.0

Quoda Code Editor - paid: IAP

Updated: August 14, 2014

Current Version: 1.0.1.2

Turbo Editor ( Text Editor ) - paid: IAP, Turbo Editor PRO (Text Editor)

Updated: May 15, 2015

Current Version: 2.1

XDA application thread by [MENTION=4692685]Vlad Mihalachi[/MENTION]

Web servers with PHP support

Some web servers with integrated PHP interpreter are listed below. A lot of those on Google Play have a free trial period, so try before you buy.

Down below you find three free web servers with PHP interpreter. I also checked which server software they're running and it's version, as well as the version of the PHP interpreter.

AndroPHP

Updated: February 8, 2013

Current Version: 1.2.0

Web server: Lighttpd 1.4.29

PHP version: 5.4.8

View the complete output of phpinfo() as PDF (196 kB)

[IMG="AndroPHP"]http://i.imgur.com/bVvv3dm.png?1[/IMG] [IMG="AndroPHP"]http://i.imgur.com/cofy8DB.png?1[/IMG]

Palapa Web Server

Updated: August 26, 2014

Current Version: 2.1.1

Web server: Lighttpd 1.4.32

PHP version: 5.5.15

View the complete output of phpinfo() as PDF (291 kB)

[IMG="Palapa Web Server"]http://i.imgur.com/QKe5Tor.png?1[/IMG] [IMG="Palapa Web Server"]http://i.imgur.com/l0fpGfS.png?1[/IMG]

Server for PHP

Updated: May 24, 2015

Current Version: 1.7.0

Web server: PHP 5.6.9 Development Server

PHP version: 5.6.9

View the complete output of phpinfo() as PDF (361 KB)

[IMG="Server for PHP"]http://i.imgur.com/ZvQto5q.png?1[/IMG] [IMG="Server for PHP"]http://i.imgur.com/gdtuIrZ.png?1[/IMG]

This one is basically a server collection, tons of servers for all your needs. Slightly outdated, no update for quite a long time, therefore an old PHP version. Hopefully the app gets new and updated servers. Trial version available.

Servers Ultimate (7 days trial) - paid: Servers Ultimate Pro

Updated: June 16, 2014

Current Version: 6.3.10

Web server: Lighttpd

PHP version: 5.4.8

View the complete output of phpinfo() as PDF (197 kB)

XDA application thread by [MENTION=706513]Themuzz[/MENTION]

[IMG="Servers Ultimate Pro"]http://i.imgur.com/TWsEj1l.png?1[/IMG] [IMG="Servers Ultimate Pro"]http://i.imgur.com/MrMYwKQ.png?1[/IMG]

Web server monitor

To monitor your mobile web server, I recommend to set up a server monitor app, like Monyt - Server Monitor. The app itself is a client, pulling information from a script you have to place on your server. Just for the records, it's a PHP script.

Monyt - Server Monitor

Updated: March 15, 2013

Current Version: 1.1.4

XDA application thread by [MENTION=4875730]evilsocket[/MENTION]

Install Monyt - Server Monitor from Google Play store (on any Android device, this is basically only the client)

Paste the PHP code into a *.php file (link in the Google Play description) (on the server)

Configure the app, at least enter the URL to the PHP script

The monitor app can also be installed on your mobile server.

Some screenshots made on a Sony Xperia Z3

[IMG="Monyt"]http://i.imgur.com/M3MFET0.png?1[/IMG] [IMG="Monyt"]http://i.imgur.com/e6T3Isl.png?1[/IMG] [IMG="Monyt"]http://i.imgur.com/YDpKmQ5.png?1[/IMG]

Current link and content of the PHP script: http://www.monyt.net/monyt-server-script.txt

<?php

error_reporting(0);

define( "MONYT_SCRIPT_VERSION", "1.0.1" );

if( isset($_GET['version'] ) )
{
die( MONYT_SCRIPT_VERSION );
}
else if( isset($_GET['check']) )
{
$aCheck = array
(
'monyt' => MONYT_SCRIPT_VERSION,
'distro' => '',
'kernel' => '',
'cpu' => '',
'cores' => ''
);

$sDistroName = '';
$sDistroVer = '';

foreach (glob("/etc/*_version") as $filename)
{
list( $sDistroName, $dummy ) = explode( '_', basename($filename) );

$sDistroName = ucfirst($sDistroName);
$sDistroVer = trim( file_get_contents($filename) );

$aCheck['distro'] = "$sDistroName $sDistroVer";
break;
}

if( !$aCheck['distro'] )
{
if( file_exists( '/etc/issue' ) )
{
$lines = file('/etc/issue');
$aCheck['distro'] = trim( $lines[0] );
}
else
{
$output = NULL;
exec( "uname -om", $output );
$aCheck['distro'] = trim( implode( ' ', $output ) );
}
}

$cpu = file( '/proc/cpuinfo' );
$vendor = NULL;
$model = NULL;
$cores = 0;
foreach( $cpu as $line )
{
if( preg_match( '/^vendor_id\s*:\s*(.+)$/i', $line, $m ) )
{
$vendor = $m[1];
}
else if( preg_match( '/^model\s+name\s*:\s*(.+)$/i', $line, $m ) )
{
$model = $m[1];
}
else if( preg_match( '/^processor\s*:\s*\d+$/i', $line ) )
{
$cores++;
}
}

$aCheck['cpu'] = "$vendor, $model";
$aCheck['cores'] = $cores;
$aCheck['kernel'] = trim(file_get_contents("/proc/version"));

die( json_encode($aCheck) );
}

$aStats = array( 'monyt' => MONYT_SCRIPT_VERSION );

$aStats['uptime'] = trim( file_get_contents("/proc/uptime") );

$load = file_get_contents("/proc/loadavg");
$load = explode( ' ', $load );

$aStats['load'] = $load[0].', '.$load[1].', '.$load[2];

$memory = file( '/proc/meminfo' );
foreach( $memory as $line )
{
$line = trim($line);

if( preg_match( '/^memtotal[^\d]+(\d+)[^\d]+$/i', $line, $m ) )
{
$aStats['total_memory'] = $m[1];
}
else if( preg_match( '/^memfree[^\d]+(\d+)[^\d]+$/i', $line, $m ) )
{
$aStats['free_memory'] = $m[1];
}
}

$aStats['hd'] = array();

foreach( file('/proc/mounts') as $mount )
{
$mount = trim($mount);
if( $mount && $mount[0] == '/' )
{
$parts = explode( ' ', $mount );
if( $parts[0] != $parts[1] )
{
$device = $parts[0];
$folder = $parts[1];
$total = disk_total_space($folder) / 1024;
$free = disk_free_space($folder) / 1024;

if( $total > 0 )
{
$used = $total - $free;
$used_perc = ( $used * 100.0 ) / $total;

$aStats['hd'][] = array
(
'dev' => $device,
'total' => $total,
'used' => $used,
'free' => $free,
'used_perc' => $used_perc,
'mount' => $folder
);
}
}
}
}

$ifname = NULL;

if( file_exists('/etc/network/interfaces') )
{
foreach( file('/etc/network/interfaces') as $line )
{
$line = trim($line);

if( preg_match( '/^iface\s+([^\s]+)\s+inet\s+.+$/', $line, $m ) && $m[1] != 'lo' )
{
$ifname = $m[1];
break;
}
}
}
else
{
foreach( glob('/sys/class/net/*') as $filename )
{
if( $filename != '/sys/class/net/lo' && file_exists( "$filename/statistics/rx_bytes" ) && trim( file_get_contents("$filename/statistics/rx_bytes") ) != '0' )
{
$parts = explode( '/', $filename );
$ifname = array_pop( $parts );
}
}
}

if( $ifname != NULL )
{
$aStats['net_rx'] = trim( file_get_contents("/sys/class/net/$ifname/statistics/rx_bytes") );
$aStats['net_tx'] = trim( file_get_contents("/sys/class/net/$ifname/statistics/tx_bytes") );
}
else
{
$aStats['net_rx'] =
$aStats['net_tx'] = 0;
}

die( json_encode( $aStats ) );

?>