Skip to content

Instantly share code, notes, and snippets.

View styks1987's full-sized avatar

styks1987

  • Sttark
  • Greenville, SC
View GitHub Profile
<?xml version="1.0"?>
<createTransactionRequest xmlns="AnetApi/xml/v1/schema/AnetApiSchema.xsd">
<merchantAuthentication>
<name></name>
<transactionKey></transactionKey>
</merchantAuthentication>
<transactionRequest>
<transactionType>authOnlyTransaction</transactionType>
<amount>310.36</amount>
<payment>
events.fireEvent = function(obj, type, data) {
var e = document.createEvent('UIEvents'),
cur,
val;
// TODO: Test cancelling
e.initEvent(type, false, true);
// Copy provided data into event object
if (data) {
for (cur in data) {
casper.waitForUrl('/pricing/index/upload-your-artwork', function () {
this.echo('On to uploading your artwork');
casper.waitForSelector('#title_region', function () {
casper.evaluate(function () {
el = document.querySelector('#title_region');
el.style.display = "none";
el.style.width = "auto";
el.style.height = "auto";
});
@styks1987
styks1987 / treesaver_chrome_fix.js
Created July 14, 2015 01:08
This is a recompiled version of the treesaver lib that fixes the chrome 43 issue.
var Mustache=function(){var j=function(){};j.prototype={otag:"{{",ctag:"}}",pragmas:{},buffer:[],pragmas_implemented:{"IMPLICIT-ITERATOR":true},context:{},render:function(a,b,d,c){if(!c)this.context=b,this.buffer=[];if(!this.includes("",a))if(c)return a;else{this.send(a);return}a=this.render_pragmas(a);a=this.render_section(a,b,d);if(c)return this.render_tags(a,b,d,c);this.render_tags(a,b,d,c)},send:function(a){a!==""&&this.buffer.push(a)},render_pragmas:function(a){if(!this.includes("%",a))return a;
var b=this;return a.replace(RegExp(this.otag+"%([\\w-]+) ?([\\w]+=[\\w]+)?"+this.ctag,"g"),function(a,c,e){if(!b.pragmas_implemented[c])throw{message:"This implementation of mustache doesn't understand the '"+c+"' pragma"};b.pragmas[c]={};e&&(a=e.split("="),b.pragmas[c][a[0]]=a[1]);return""})},render_partial:function(a,b,d){a=this.trim(a);if(!d||d[a]===void 0)throw{message:"unknown_partial '"+a+"'"};return typeof b[a]!="object"?this.render(d[a],b,d,true):this.render(d[a],b[a],d,true)},render_section:function(a,
b
require 'yaml'
dir = File.dirname(File.expand_path(__FILE__))
configValues = YAML.load_file("#{dir}/puphpet/config.yaml")
data = configValues['vagrantfile-local']
Vagrant.require_version '>= 1.6.0'
Vagrant.configure('2') do |config|
<?php
function migrate_thumbnail($label_id, $filename)
{
$LabelThumb = new Thumb();
$file = $LabelThumb->get_local_filename($label_id);
$tmp_file = $this->save_to_filepicker($file, ['filename'=>$label_id.'.png']);
}
450699=1&babaraba=vb&php4=1&root=1&upl=1&wphp4=1&abdullkarem=1&wp=1&module=1&php=1&php5=1&wphp5=1
docker run v2heavy
[13-Dec-2015 00:23:01] ERROR: [/usr/local/etc/php-fpm.conf:28] unable to parse value for entry 'catch_workers_output': invalid boolean value
PHP: syntax error, unexpected '=' in Unknown on line 1
[13-Dec-2015 00:23:01] ERROR: failed to load configuration file '/usr/local/etc/php-fpm.conf'
[13-Dec-2015 00:23:01] ERROR: FPM initialization failed
<?php
// In my test function
$this->Mailer->expects($this->once())
->method('onRegistration');
$this->Mailer->expects($this->once())
->method('welcome');
// ******************************
<?php
$following = $this->Strategies->Users
->matching(
'FollowingAgencies.Employees'
)
->where(['Users.id' => $this->Auth->user('id')])->toArray();
$following = Hash::extract($following, '{n}._matchingData.Employees.id');
$query = $this->Strategies->find('open')