Skip to content

Instantly share code, notes, and snippets.

View rukshn's full-sized avatar
🖥️
Working

Rukshan Ranatunge rukshn

🖥️
Working
View GitHub Profile
@rukshn
rukshn / Space Aids
Last active August 29, 2015 14:05
No one likes an Ad filled website, but what happens when that is one the most visited news websites, it sucks. This is a small browser bookmarklet that helps you to get rid of most of the ads at Daily Mirror, FT.lk, Lankadeepa and Mirror Sports. Bookmark this bookmarklet (I think you know how) and when you are reading news at any of those websit…
javascript:(function(){
if (!($ = window.jQuery)) {
var jq = document.createElement('script');
jq.src = "//ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js";
document.body.appendChild(script);
}
else {
releasetheKraken();
}
@rukshn
rukshn / gist:7061578
Created October 19, 2013 21:08
Unfortunate Facebooking. Post
We talk about Facebook, online privacy and bullying online, but we don't realize the gravity of it until it happens to someone we know. This is an incident that's currently happening to a friend of mine and I'm blogging about it to let people know and get attention of someone that can help.
This friend of mine who I won't tell the name is a student of a government university, and recently she had a request for a date by a person from the navy which she has refused, and because of this this person has created a fake Facebook profile of her using her photos but with a different name and has started posting bad things that are ruining her real life.
Also making things worse the person who created this fake profile is adding her real life friends to the fake Facebook profile, because the fake Facebook profile is using her real photos people that she know are accepting the requests and thins are getting worse and worse. And making things extra worse the people who's behind all this is telling that he would stop
@rukshn
rukshn / sreader.php
Created August 19, 2012 04:33
A simple Facebook social reader app. This can be improved a lot
<?php
$app_id = "xxxxxxx"; //facebook app id
$redirect_url = "xxxxxx"; //url to redirct after getting the token, should be in the same domain of the canvas url
$app_secret = "xxxxxxx"; //facebook app secret
session_start();
$code = $_REQUEST['code'];
@rukshn
rukshn / twitpic.php
Created August 18, 2012 04:37
Using this code one can easily upload pictures to TwitPic using TwitPic API and Abraham Willium's Twitter OAuth Library and OAuth Echo
<?php
//using this code one can easily upload pictures to TwitPic using TwitPic API and Abraham Willium's Twitter OAuth class
/**
* @file
* User has successfully authenticated with Twitter. Access tokens saved to session and DB.
*/
/* Load required lib files. */
session_start();
require_once('twitteroauth/twitteroauth.php');