Skip to content

Instantly share code, notes, and snippets.


Victor Kareh vkareh

  • Red Hat
  • Quebec, Canada
View GitHub Profile
View gist:2721620
* Form submit...
function my_module_submit($form, $form_state) {
$email = $form_state['values']['email'];
$message_type = $form_state['values']['message_type'];
$params = array('form_values' => $form_state['values']);
drupal_mail('my_module', $message_type, $email, language_default(), $params);
vkareh / cradle.patch
Created Feb 28, 2012
patch for cradle
View cradle.patch
diff --git a/lib/cradle.js b/lib/cradle.js
index 7700ff6..db5e2a5 100644
--- a/lib/cradle.js
+++ b/lib/cradle.js
@@ -509,7 +509,9 @@ cradle.Connection.prototype.database = function (name) {
if (options && options.keys) {
- this.query('POST', path, {}, options, args.callback);
+ var keys = options.keys;
vkareh / .vimrc
Created Jan 26, 2012
Drupal-friendly .vimrc
View .vimrc
"Enable filetype detection
:filetype on
"General settings
set incsearch "Find as you type
set ignorecase "Ignore case in search
set scrolloff=2 "Number of lines to keep above/below cursor
set smartcase "Only ignore case when all letters are lowercase
set number "Show line numbers
set wildmode=longest,list "Complete longest string, then list alternatives