Skip to content

Instantly share code, notes, and snippets.

package main
import (
"flag"
"log"
"net/http"
"net/http/httputil"
"net/url"
"os"
"os/signal"
/**
* Allows "named" parameters for vprintf. You can use one of two ways to name the values
* in the string. Mixing and matching in the same string is supported.
*
* It also throws an error when you don't have a value in the array as expected.
*
* $a = array("lazy" => "z", "jmp" => "jumps", "qik" => "QUICK", "times" => 10.625);
*
* The following strings can all be used: %(name)s -- python || %name$s --php
*
<?php
/**
* return all of the commandline options as a nice list of things.
* This is modeled after the Python Optparse. (so it's easy!!) with some
* BASH getops flavor.
*
* @author Nika Jones
*
* @copyright 2010 Appcelerator Inc.
*
/**
* Breaks XML down into a nice array... it flattens namespace prefixes without a schema.
*
* @author Nika Jones
*
* @copyright 2010 Appcelerator Inc.
*
* Licensed under the terms of the Apache Public License
* http://www.apache.org/licenses/LICENSE-2.0
*