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 | |
require_once(TOOLKIT . '/class.event.php'); | |
Class eventimport_links_from_delicious extends Event{ | |
const ROOTELEMENT = 'import-links-from-delicious'; | |
public $eParamFILTERS = array( | |
'xss-fail', |
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
$config['uri_protocol'] = "PATH_INFO"; | |
$config['enable_query_strings'] = TRUE; | |
$config['permitted_uri_chars'] = 'a-z 0-9~%.:_-?=+&;'; |
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
public static String stripTags(String input) { | |
return input.replaceAll("\\<.*?>",""); | |
} |
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 randstr($len = 8) { | |
$src = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890"; | |
$src = $src.$src.$src.$src.$src; | |
return substr(str_shuffle($src), 0, $len); | |
} |
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
def md5(str): | |
import md5 | |
hasher = md5.new() | |
hasher.update(str) | |
return hasher.hexdigest() |
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
def SomeDecorator(next): | |
def getFunction(fn): | |
def doStuff(req, *args): | |
return fn(req, *args) | |
return doStuff | |
return getFunction |
NewerOlder