Skip to content

Instantly share code, notes, and snippets.

View karloscarweber's full-sized avatar
📱
Building

Karl Weber karloscarweber

📱
Building
View GitHub Profile
@karloscarweber
karloscarweber / shuffle.php
Created April 10, 2012 21:43
A slide Shuffler.
<?php // PHP
// Shuffle some html, then echo them to the screen.
// why? because It's flipping easy!
$slides = array(
'<img src="/img/pic1.jpg" />',
'<img src="/img/pic2.jpg" />',
'<img src="/img/pic3.jpg" />',
@karloscarweber
karloscarweber / kowLinkMaker.js
Created March 14, 2012 16:53
This Snippet basicly finds an 'a' element inside another element, then redirects to it's HREF
// This Snippet basicly finds an 'a' element inside another element, then redirects to it's HREF
// useful for faking link behaviour on block level elements, without having to make them a tags.
// be careful to have a fallback for when javascript is disabled.
$(document).ready(function(){
// onclick obviously
$('element').click(function(){
// $(this) refers to jquery object passed inot he method. it would be of 'element' in this case.
@karloscarweber
karloscarweber / Uploader.php
Created August 25, 2011 16:49 — forked from JunaidQadirB/Uploader.php
The Uploader class is a simple php script that makes file uploads a bit easier.
<?php /* The Uploader class is a simple php script that makes file
* uploads a bit easier.
* @author Junaid Qadir Baloch (shekhanzai.baloch@gmail.com)
* @version 0.1 10:18 PM 7/30/2011
*/
class Uploader
{
private $allowedFileTypes;
private $maxFileSize = 1048576;
private $fileInputBoxName;