Skip to content

Instantly share code, notes, and snippets.

View pkarl's full-sized avatar
🍕
pk2 is typing...

Pete Karl II pkarl

🍕
pk2 is typing...
View GitHub Profile
~: sudo /etc/init.d/apache2 start
* Starting web server apache2
(98)Address already in use: make_sock: could not bind to address 0.0.0.0:8080
no listening sockets available, shutting down
Unable to open logs
...fail!
# try to start apache, receive error
~: sudo /etc/init.d/apache2 start
* Starting web server apache2
(98)Address already in use: make_sock: could not bind to address 0.0.0.0:8080
no listening sockets available, shutting down
Unable to open logs
...fail!
# see what's using the port (note that I'm searching for :80, I could also use :8080)
Listen 8080
#<IfModule mod_ssl.c>
# Listen 443
#</IfModule>
<div class='some-inline-input'>
<p>Please enter some text in this box, then submit it!</p>
<textarea id="posted_text"></textarea>
<a class="post-text" href="/post/to/this/url">submit text with a POST request</a>
</div>
<script>
$('.post-text').click(function() {
var target = $(this)
// js
$('div#dragme').draggable()
// html
<div id="dragme">
Drag me! I'm a div
</div>
<form id="playform">
<fieldset>
<legend>Contact Info:</legend>
Name: <input type="text" size="30" /><br />
Email: <input type="text" size="30" /><br />
Date of birth: <input type="text" size="10" />
</fieldset>
<fieldset>
var ProgressForm = {
_currentStep: 1,
_totalSteps: 0,
_prevButton: false,
_nextButton: false,
_progressbar: false,
// this would be _init() for jQuery UI versions < 1.8
$.get('https://api.twitter.com/1/statuses/mentions.json?include_entities=true', {'since_id':'1234'}, function(data){
// parse that shit
// insert that shit
});
@pkarl
pkarl / sadpanda.md
Created September 21, 2012 18:13
AT&T Screwed up the iPhone 5 Launch (mirror) @NickWoodhams

AT&T Screwed up the iPhone 5 Launch

September 21, 2012

I was invited into the AT&T store this morning, after a long wait, to purchase my iPhone 5. I avoided looking at the display model iPhones on the way in, and averted my gaze from everyone elses iPhones. I wanted to enrich the experience of opening my own iPhone 5, and make it more special than it already would be. The sales rep retrieved the iPhone I requested…

Then he then proceeded to open the iPhone himself, with his back to me.

My stomach sank. Opening an Apple product is a religious experience. It’s one of the best things about the first day with your shiny new device. He took that from me. I felt like this sales rep had stolen from me. They were stealing from everyone. No one was opening their new iPhone. Is it not supposed to be special anymore? Then why does Apple continue to spend 3, 5, or 10 times as much on packaging and presentation as other companies?

@pkarl
pkarl / Vagrantfile.rb
Created November 29, 2012 17:50
vagrant-ETIMEDOUT-stacktrace
# -*- mode: ruby -*-
# vi: set ft=ruby :
Vagrant::Config.run do |config|
config.vm.box = "lucid32"
# config.vm.box_url = "http://files.vagrantup.com/lucid32.box"
config.vm.forward_port 80, 8080
config.vm.network :hostonly, "192.168.10.10"