Difference between revisions of "MediaWiki:Common.js"

From Wikimedia District of Columbia
Jump to navigation Jump to search
(rv)
(add calendar)
Line 2: Line 2:
 
if ( ( mw.config.get('wgPageName') == 'Membership' ) && ( wgNamespaceNumber == 0 ) ) {
 
if ( ( mw.config.get('wgPageName') == 'Membership' ) && ( wgNamespaceNumber == 0 ) ) {
 
$('#membershipbutton').html('<form action="https://www.paypal.com/cgi-bin/webscr" method="post"><input type="hidden" name="cmd" value="_s-xclick"><input type="hidden" name="hosted_button_id" value="QTRS8N8RD8WNL"><input type="image" src="https://www.paypalobjects.com/en_US/i/btn/btn_buynowCC_LG.gif" border="0" name="submit" alt="PayPal - The safer, easier way to pay online!"><img alt="" border="0" src="https://www.paypalobjects.com/en_US/i/scr/pixel.gif" width="1" height="1"></form>');
 
$('#membershipbutton').html('<form action="https://www.paypal.com/cgi-bin/webscr" method="post"><input type="hidden" name="cmd" value="_s-xclick"><input type="hidden" name="hosted_button_id" value="QTRS8N8RD8WNL"><input type="image" src="https://www.paypalobjects.com/en_US/i/btn/btn_buynowCC_LG.gif" border="0" name="submit" alt="PayPal - The safer, easier way to pay online!"><img alt="" border="0" src="https://www.paypalobjects.com/en_US/i/scr/pixel.gif" width="1" height="1"></form>');
  +
}
  +
  +
/* add calendar */
  +
if ( ( mw.config.get('wgPageName') == 'Calendar' ) && ( wgNamespaceNumber == 0 ) ) {
  +
$('#calendarwidget').html('<iframe src="http://www.google.com/calendar/embed?src=wikidc.org_svr4b3s6n6rs8mt189kbc4uegg%40group.calendar.google.com&ctz=America/New_York" style="border: 0" width="800" height="600" frameborder="0" scrolling="no"></iframe>');
 
}
 
}

Revision as of 18:06, 24 September 2011

/* add membership payment button */
if ( ( mw.config.get('wgPageName') == 'Membership' ) && ( wgNamespaceNumber == 0 ) ) {
  $('#membershipbutton').html('<form action="https://www.paypal.com/cgi-bin/webscr" method="post"><input type="hidden" name="cmd" value="_s-xclick"><input type="hidden" name="hosted_button_id" value="QTRS8N8RD8WNL"><input type="image" src="https://www.paypalobjects.com/en_US/i/btn/btn_buynowCC_LG.gif" border="0" name="submit" alt="PayPal - The safer, easier way to pay online!"><img alt="" border="0" src="https://www.paypalobjects.com/en_US/i/scr/pixel.gif" width="1" height="1"></form>');
}

/* add calendar */
if ( ( mw.config.get('wgPageName') == 'Calendar' ) && ( wgNamespaceNumber == 0 ) ) {
  $('#calendarwidget').html('<iframe src="http://www.google.com/calendar/embed?src=wikidc.org_svr4b3s6n6rs8mt189kbc4uegg%40group.calendar.google.com&ctz=America/New_York" style="border: 0" width="800" height="600" frameborder="0" scrolling="no"></iframe>');
}