For information of how to install and set up git to work with GitHub, please visit the following link.
This file contains 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
Video demo at http://screencast.com/t/WcjpL2lc. | |
By default it uses a title field ending in [title] or [name] as the source field, and a field ending in [slug] as the destination. This matches the naming conventions for a framework like CakePHP, i.e. <?php echo $form->input('title'); ?> outputs an input with a name of data[Model][title]. | |
You can override the default source and destination fields by setting document.slugField and document.titleField in JavaScript beforehand: | |
<script> | |
document.titleField = "input[name$='[heading]']"; | |
document.slugField = "input[name$='[url_safe_heading]']"; | |
</script> |
This file contains 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
if: (self -> 'lockfield') != ''; | |
(self -> 'lockvalue')=(field: (self -> 'lockfield')); | |
(self -> 'lockvalue_encrypted')=(encrypt_blowfish: (field: (self -> 'lockfield')), -seed=(self -> 'lock_seed')); | |
/if; |
This file contains 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
from wsgiref.simple_server import make_server | |
from pyramid.config import Configurator | |
from pyramid.response import Response | |
def hello_world(request): | |
return Response('<h1>Hello World!</h1>') | |
if __name__ == '__main__': |
This file contains 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
local(d) = ds(::mysqlds,'localhost',::database.table,'username','password') | |
local(sql) = ` | |
SELECT * | |
FROM table | |
WHERE id > 0; | |
` | |
local(rs) = #d->sql(#sql)->results | |
if(#rs->size > 0) => { | |
if (#rs->get(1)->found_count) => {^ | |
'at least 1 record' |
This file contains 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
[ | |
/* | |
2014-10-08 JC Added to Gist | |
*/ | |
/**! | |
ical_encodebreak | |
Method to ensure that the given string complies to the icalendar requirements that no row inside an icalendar object is longer than 75 octets (bytes) |
This file contains 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
[ | |
// [Email_Send2] | |
// | |
// This tag is a drop-in replacement for [Email_Send]. It uses [Email_Compose] on the back-end in order | |
// to create the message to be sent. | |
// | |
/* PATCH | |
* Replaces subject line that is encoded word by word with a subject line that is encoded as a whole. |
This file contains 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
[ | |
/**! | |
wrp | |
Quick way to grap a web_request param | |
2014-10-08 JC Added to Gist | |
2014-10-08 JC Added separate methods for queryparams and postparams | |
2014-08-24 JC Rewrite of the wrp method once again. This time with code suggested by Brad Lindsay in a lassotalk thread. Introduces the param -all | |
2014-08-22 JC Complete rewrite to produce leaner and more reliable code. Arrays are now returned as staticarrays |
This file contains 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
[ | |
/**! | |
jc_session | |
Lasso 9 type to handle cookie based sessions | |
Requires that Ke Carltons DS is installed | |
https://github.com/zeroloop/ds | |
Before first use create the needed table and set the proper values for |
OlderNewer