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 | |
/** | |
* Generate a random password | |
* @param $length The length of the password | |
* @return string The password | |
*/ | |
private function generatePassword($length) | |
{ | |
$str = array(); | |
$str[] = 'abcdefghjklmnpqrtvwxyz'; |
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
<xsl:variable name="event" select="{eventnaam}" /> | |
<xsl:choose> | |
<xsl:when test="$event/@result = 'success'"> | |
<!-- Melding gelukt! --> | |
</xsl:when> | |
<xsl:otherwise> | |
<!-- Laat het formulier zien: --> | |
<xsl:choose> |
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
/* | |
Kleine plugin om formulieren te valideren in jQuery | |
--------------------------------------------------- | |
Usage: | |
$("form").validate(); | |
Als het formulier nu verzonden wordt, worden: | |
- alle elementen met class 'required' gecontroleerd of ze niet leeg zijn. | |
- alle input-elementen met class 'e-mail' gecontroleerd of ze geldig zijn. |
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 | |
Class extension_[name] extends Extension | |
{ | |
/** | |
* About this extension | |
* @return array | |
*/ | |
public function about() | |
{ |
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
<xsl:comment><![CDATA[[if IE]><link rel="stylesheet" type="text/css" href="/workspace/assets/css/ie.css" /><![endif]]]></xsl:comment> |
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
<!-- Addition to the ninja XSL utility --> | |
<xsl:template match="a[@target='_blank']" mode="html"> | |
<a> | |
<xsl:attribute name="rel">external</xsl:attribute> | |
<xsl:apply-templates select="* | @*[not(name()='target')] | text()" mode="html"/> | |
</a> | |
</xsl:template> | |
<!-- Provide an alt-tag for images with no alt-tag: --> | |
<xsl:template match="img[not(@alt) or @alt = '']" mode="html"> |
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 | |
$ret = preg_replace("#(^|[\n ])@([A-Za-z0-9_]+)#ise", "'\\1<a target=\"_blank\" href=\"http://www.twitter.com/\\2\" >@\\2</a>'", $text); | |
$ret = preg_replace("#(^|[\n ])\#([A-Za-z0-9_]+)#ise", "'\\1<a target=\"_blank\" href=\"http://twitter.com/#!/search/%23\\2\" >#\\2</a>'", $ret); | |
$ret = preg_replace("#(^|[\n ])([\w]+?://[\w]+[^ \"\n\r\t<]*)#ise", "'\\1<a target=\"_blank\" href=\"\\2\" >\\2</a>'", $ret); | |
$text = preg_replace("#(^|[\n ])((www|ftp)\.[^ \"\t\n\r<]*)#ise", "'\\1<a target=\"_blank\" href=\"http://\\2\" >\\2</a>'", $ret); | |
?> |
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
// External links: | |
$("a.external, a[rel=external]").click(function(){ | |
window.open($(this).attr("href")); | |
return false; | |
}); |
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
<!-- AddThis Button BEGIN --> | |
<div class="addthis_toolbox addthis_default_style"> | |
<xsl:value-of disable-output-escaping="yes" select="'<a class="addthis_button_facebook_like" fb:like:layout="button_count"></a>'" /> | |
<a class="addthis_button_tweet"></a> | |
<a class="addthis_counter addthis_pill_style"></a> | |
</div> | |
<script type="text/javascript">var addthis_config = {"data_track_clickback":true};</script> | |
<script type="text/javascript" src="http://s7.addthis.com/js/250/addthis_widget.js#pubid=twisted"></script> | |
<!-- AddThis Button END --> |
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 | |
/** | |
* Simple database class | |
* (c) 2012 | |
* Author: Giel Berkers | |
* Date: 5-3-12 | |
* Time: 14:24 | |
*/ | |
class Db |
OlderNewer