Skip to content

Instantly share code, notes, and snippets.

@lornajane
lornajane / gist:dc2b38443e5e1dbb5ab8
Created July 8, 2015 20:40
Android compile error
$ gradle build
Picked up JAVA_TOOL_OPTIONS: -javaagent:/usr/share/java/jayatanaag.jar
FAILURE: Build failed with an exception.
* What went wrong:
A problem occurred configuring root project 'android-app'.
> Could not resolve all dependencies for configuration ':_debugCompile'.
> Could not find com.android.support:appcompat-v7:22.2.0.
Searched in the following locations:
@lornajane
lornajane / text.txt
Created July 23, 2015 18:29
Gist created by API
Some riveting text
@lornajane
lornajane / text.txt
Created July 23, 2015 18:30
Gist created by API
Some riveting text
// PHP 5 wrappers (PHP 5.6 Ubuntu package)
// stream_get_wrappers()
Array
(
[0] => https
[1] => ftps
[2] => compress.zlib
[3] => compress.bzip2
[4] => php
[5] => file
<?php
$client = new SoapClient('http://api.radioreference.com/soap2/?wsdl&v=latest');
$countries = $client->getCountryList();
print_r($countries);
@lornajane
lornajane / text.txt
Created July 23, 2015 18:30
Gist created by API
Some riveting text
@lornajane
lornajane / comments.php
Created August 16, 2011 13:09
comments
<h1>Submit A Comment</h1>
<form method="post">
<p>Name: <input name="name" /></p>
<p>Comment: <textarea name="comment"></textarea></p>
<input type="submit" />
</form>
<?php
if($_POST) {
foreach ($thing as $value) {
if(!empty($value)) {
if(is_array($value)) {
foreach($value as $subitem) {
$array[] = $subitem;
}
} else {
$array[] = $value;
}
}
@lornajane
lornajane / data-array.php
Created May 28, 2012 15:08
Multidimensional Array
<?php
$events[] = array(
"name" => "phpDay 2012",
"start_date" => "2012-05-18T00:00:00+02:00",
"end_date" => "2012-05-19T23:59:59+02:00",
"description" => "The GrUSP, the Italian PHP user group, organises the 8th phpDay, a conference dedicated to PHP for the enterprise.",
"href" => "http://www.phpday.it",
"hosts" => array(
"Daniel Londero",
@lornajane
lornajane / gist:2928842
Created June 14, 2012 07:45
PHP 5.3 vs PHP 5.4
5.3.12 5.4.3
Run 1 2.07883811 0.94130707
Run 2 2.03927302 0.96553779
Run 3 2.03478503 0.96503210
Run 4 2.05938697 0.94606614
Run 5 2.04912210 0.95049596