Skip to content

Instantly share code, notes, and snippets.

span.aptureLink {
-moz-border-radius:4px 4px 4px 4px;
cursor:pointer !important;
display:block;
float:left;
margin-top:2px;
}
span.aptureLinkIcon, span.aptureLink, a.aptureLink {
border:0 none !important;
padding:0 !important;
--
-- Table structure for table `municipalities`
--
CREATE TABLE `municipalities` (
`id` int(2) NOT NULL auto_increment,
`name` varchar(40) NOT NULL default '',
`lat` float(8,6) default NULL,
`lng` float(9,6) default NULL,
PRIMARY KEY (`id`),
$message = "Acaban de darle la nota a un$professorSexWord profesor$professorSexWord.";
$post_data = array(
'message' => $message,
'picture' => "http://www.notaso.com/assets/img/notaso-small-fb.png",
'link' => site_url('professor/'.$id),
'name' => $professorName,
'caption' => $universityName.' - '.$universityCampus,
'description' => $departmentName,
'access_token' => $this->config->item('facebook_notaso_access_token')
);
function get_facebook_cookie() {
$app_id = $this->config->item('facebook_api_key');
$application_secret = $this->config->item('facebook_secret_key');
if(isset($_COOKIE['fbs_' . $app_id])){
$args = array();
parse_str(trim($_COOKIE['fbs_' . $app_id], '\\"'), $args);
ksort($args);
$payload = '';
foreach ($args as $key => $value) {
git filter-branch --commit-filter '
if [ "$GIT_COMMITTER_NAME" = "Old Name" ];
then
GIT_COMMITTER_NAME = "New Name";
GIT_AUTHOR_NAME = "New Name";
GIT_COMMITTER_EMAIL = "New Email";
GIT_AUTHOR_EMAIL = "New Email";
git commit-tree "$@";
else
git commit-tree "$@";
import mechanize
import cookielib
from BeautifulSoup import BeautifulSoup
# Browser
br = mechanize.Browser()
# Cookie Jar
cj = cookielib.LWPCookieJar()
p = Presentation.objects.all().select_related()
out = serializers.serialize("json", p)
return HttpResponse(out, mimetype='application/json')
//Presentations
function presentations()
{
$.ajax({
url: '/jsonapi/presentations/',
type: 'POST',
dataType: 'json',
complete: function(xhr, textStatus) {
setTimeout("presentations()", 5000);
},
<object width="220">
<param name="movie" value="http://www.ibizasonica.com/flash/player_live.swf">
<param name="play" value="false">
<embed base="http://www.ibizasonica.com/flash/" allowscriptaccess="never" allownetworking="internal" width="220" src="http://www.ibizasonica.com/flash/player_live.swf" wmode="transparent" type="application/x-shockwave-flash" />
</object>
<?php
$data = readFromDatabase();
printData($data);
doSomethingUnrelatedLikeFetchingSomethingElse();
?>