Les données retournées sont au format XML.
Document trouvé et modifié depuis Pastebin.
<?php | |
/* From https://www.usps.com/send/official-abbreviations.htm */ | |
$us_state_abbrevs_names = array( | |
'AL'=>'ALABAMA', | |
'AK'=>'ALASKA', | |
'AS'=>'AMERICAN SAMOA', | |
'AZ'=>'ARIZONA', | |
'AR'=>'ARKANSAS', |
# Given | |
Given I am on [the] homepage | |
Given I am on "url" | |
# When | |
When I go to [the] homepage | |
When I go to "url" | |
When I reload the page |
Les données retournées sont au format XML.
Document trouvé et modifié depuis Pastebin.
var actionUtil = require('sails/lib/hooks/blueprints/actionUtil'); | |
module.exports = function getCount (req, res) { | |
var Model = actionUtil.parseModel(req) | |
, criteria = actionUtil.parseCriteria(req); | |
Model.count(criteria, function(error, response) { | |
if (error) { | |
return res.serverError('database_error', error); |
This is a bash script that will automatically turn your wifi off if you connect your computer to an ethernet connection and turn wifi back on when you unplug your ethernet cable/adapter. If you decide to turn wifi on for whatever reason, it will remember that choice. This was improvised from this mac hint to work with Yosemite, and without hard-coding the adapter names. It's supposed to support growl, but I didn't check that part. I did, however, add OSX notification center support. Feel free to fork and fix any issues you encounter.
Most the credit for these changes go to Dave Holland.
/** | |
* Node.js proxy to redirect domain to correct server | |
* Also check is server is alive or send a maintenance page | |
*/ | |
var http = require('http'), | |
httpProxy = require('http-proxy'), | |
proxy = httpProxy.createProxyServer({}), | |
request = require('request'), | |
domains = { | |
"domain1.com" : "localhost:8080", |
require 'sinatra' | |
require 'sinatra' | |
require "cgi" | |
require 'json' | |
require 'tex2png' | |
| |
| |
def upload(path) | |
`curl -F file=@#{path} -F token=xoxp-xxxxxxxxx-xxxxxxxxx https://slack.com/api/files.upload` | |
end |
A small library for padding strings in JavaScript. Marmalade-free.
![NPM version][shield-npm] ![Node.js version support][shield-node] ![Build status][shield-build] ![Code coverage][shield-coverage]
#!/bin/bash | |
sudo rm -fr /opt/franz | |
sudo rm -fr /usr/share/applications/franz.desktop | |
# create installation dir | |
sudo mkdir -p /opt/franz | |
#install franz |