Skip to content

Instantly share code, notes, and snippets.

View ericlbarnes's full-sized avatar
🎵
git push it, git push it real good

Eric Barnes ericlbarnes

🎵
git push it, git push it real good
View GitHub Profile
<?php
use Illuminate\Support\Collection;
class Feed {
public function fetch($url = 'http://site.com/feed')
{
$feed = implode(file($url));
$xml = simplexml_load_string($feed);
<script>
@if (App::environment('local'))
var $el = $("#card-number");
window.stripeData = {
valid: function() {
$el.val('4242424242424242');
},
successAddressFail: function() {
$el.val('4000000000000028');
},

Artisan Files

I am currently in the process of creating a free e-book of all the Artisan Files interviews and in the opening I would include a few quotes.

If you enjoy the series would mind commenting with a short testimonial that I could include? Or email directly: eric@ericlbarnes.com

@ericlbarnes
ericlbarnes / bower.json
Last active January 8, 2024 01:52
Gulp, Bower, Bootstrap Sass, FontAwesome
{
"name": "project",
"version": "0.0.0",
"authors": [
"Eric Barnes <me@example.org>"
],
"license": "MIT",
"private": true,
"ignore": [
"**/.*",
@ericlbarnes
ericlbarnes / example.html
Created April 17, 2014 12:35
Snappy Widget
<html>
<head></head>
<body>
<a href="#" class="help" data-id="3">Help</a>
<script>
var snappyReady = function(){
$(".help").click(function(){
SnappyWidget.open({
<?php
return array(
'faqs' => 'FAQs', // Main faq sections.
'permalink' => 'Direkt hierher verlinken', // Permalink title text for the section
'top' => 'Nach oben', // Back to top link
'search_results' => 'Ergebnisse durchsuchen', // Search results heading
'search_placeholder' => "Fragen durchsuchen", // Search form placeholder text
'noresults' => 'Keine Ergebnisse', // Message shown when the search did not return any results
0 info it worked if it ends with ok
1 verbose cli [ '/usr/local/bin/node',
1 verbose cli '/usr/local/bin/npm',
1 verbose cli 'install',
1 verbose cli 'grunt-contrib-uglify' ]
2 info using npm@1.4.3
3 info using node@v0.10.26
4 verbose cache add [ 'grunt-contrib-uglify', null ]
5 verbose cache add name=undefined spec="grunt-contrib-uglify" args=["grunt-contrib-uglify",null]
6 verbose parsed url { protocol: null,
@ericlbarnes
ericlbarnes / foreman-tpl.json
Created February 25, 2014 04:10
Foreman Assets
{
"structure": {
"copy": [
{
"from": "/Users/eric/Code/Shared/wardrobe/core/bower.json",
"to": "bower.json"
},
{
"from": "/Users/eric/Code/Shared/wardrobe/core/package.json",
"to": "package.json"
@ericlbarnes
ericlbarnes / postInterface.php
Created January 22, 2014 16:22
Which one is better?
interface PostRepositoryInterface {
public function create($title, $content, $slug, array $meta, array $tags, $active, $user_id, Carbon $publish_date);
}
interface PostRepositoryInterface {
public function create(array $data);
}
@ericlbarnes
ericlbarnes / vhost
Last active January 2, 2016 02:29
Statamic nginx
server {
access_log /home/webroots/default/logs/access.log;
error_log /home/webroots/default/logs/error.log;
root /home/webroots/default/public_html;
index index.php;
# Make site accessible from http://localhost/
server_name localhost;