Extension:MailChimpForms/Code

 'MailChimpForms',	'version'      => '1.0',	'author'       => 'Andrew Mahr', 	'url'          => 'http://www.mediawiki.org/wiki/Extension:MailChimpForms',	'description'  => 'Allows easy insertion of mailchimp forms via a special tag. Eep eep!' ); function efMailChimpFormsSetup { global $wgParser; $wgParser->setHook( 'mailchimpforms', 'efMailChimpForms' ); return true; } function efMailChimpForms( $input, $args, $parser ) { /* The following lines can be used to get the variable values directly: $to = $args['to'] ; $email = $args['email'] ;

$account_id = 	$args['account']; $list_id = 		$args['list']; $type = 		$args['type']; $border_css =	$args['bordercss']; $close_link = 	$args['closelink']; $prefix	=		$args['prefix']; if($close_link == 'true') $insert_close_link = 'Close'; else $insert_close_link = ''; if($border_css == 'none' || !isset($border_css)) $border_style = "style='border: 0'"; else $border_style = "style=\"border: {$border_css}\"";

if($type == 'subscribe') { $form_code = << // delete this script tag and use a "div.mc_inline_error{ XXX !important}" selector // or fill this in and it will be inlined when errors are generated var mc_custom_error_style = '';        Email Address   {$insert_close_link}

FORM; } else { continue; }	return $form_code;

}