This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
ini_set('error_reporting', E_ALL); | |
ini_set('display_errors', 1); | |
?> | |
<input type="hidden" id="sortBy" name="sortBy" /> | |
<input type="hidden" id="abc" name="abc" /> | |
<script> | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
ini_set('error_reporting', E_ALL); | |
ini_set('display_errors', 1); | |
$con = mysql_connect("localhost","student","password1236"); | |
if (!$con) | |
{ | |
die('Could not connect: ' . mysql_error()); | |
} | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<pre><?php | |
$stack = array(); | |
$stack[1] = array(); | |
$stack1first = "something"; | |
$stack1second = "something2"; | |
//$stack1both = "" . $stack1first . "||" . $stack1second; | |
$stack1array = array('title' => $stack1first, 'url' => $stack1second, 'content' => ""); | |
array_push($stack[1], $stack1array); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$('.EventsToggle td').append("<span>EXPAND</span>") | |
$('.EventsToggle') | |
.click(function() { | |
var $inSpan = $(this).find('span'); | |
$($inSpan).text($inSpan.text() == 'EXPAND' ? 'COLLAPSE' : 'EXPAND'); | |
$(this).next().slideToggle('normal'); | |
}) | |
.next() | |
.hide(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$(".events-table").each(function(index) { | |
$(this).waypoint(function(event, direction) { | |
if (index === 0) { | |
$("#events-table-0").toggle(); | |
} else if (index === 1) { | |
$("#events-table-0").toggle(); | |
$("#events-table-1").toggle(); | |
} | |
}); | |
}) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Options +FollowSymLinks | |
RewriteEngine on | |
RewriteRule (.*) http://brooklynletters.com/$1 [R=301,L] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
if(isset($_POST['submit'])) { | |
if(trim($_POST['name']) == '') { | |
$hasError = true; | |
} else { | |
$name = trim($_POST['name']); | |
} | |
if(trim($_POST['subject']) == '') { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// On http://imgur.com/a/EYCTw | |
// Open Console | |
var downloadString = ''; | |
$('.image-hover.download a').each(function(i){ | |
downloadString += 'echo "Downloading '+ (i+1) + '.jpg..."\n\r'; | |
downloadString += 'curl -L http://www.imgur.com' + $(this).attr('href') +' -o '+ (i+1) + '.jpg\n\r'; | |
downloadString += 'echo "Finished! Waiting 3 seconds before continuing..."\n\r'; | |
downloadString += 'echo \n\r'; | |
downloadString += 'sleep 3 \n\r'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function bitlyfi(url, func) { | |
// Put your own login and apiKey | |
var defaults = { | |
login: '', | |
apiKey: '', | |
longUrl: url | |
}; | |
// Build the URL to query | |
var bitly = "http://api.bit.ly/v3/shorten?" + "&login=" + defaults.login + "&apiKey=" + defaults.apiKey + "&longUrl=" + defaults.longUrl + "&format=json&callback=?"; |
OlderNewer