Santa Fe Institute Collaboration Platform

COMPLEX TIME: Adaptation, Aging, & Arrow of Time

Get Involved!
Contact: Caitlin Lorraine McShea, Program Manager, cmcshea@santafe.edu

Difference between revisions of "MediaWiki:Common.js"

From Complex Time
(Created page with "→‎Any JavaScript here will be loaded for all users on every page load.: if (/iPhone|iPod|iPad/.test(navigator.userAgent)) { $('iframe').wrap(function() { var $this =...")
 
Line 3: Line 3:
 
   $('iframe').wrap(function() {
 
   $('iframe').wrap(function() {
 
     var $this = $(this);
 
     var $this = $(this);
     return $('<div />').css({
+
     return $('<div></div>').css({
 
       width: $this.attr('width'),
 
       width: $this.attr('width'),
 
       height: $this.attr('height'),
 
       height: $this.attr('height'),

Revision as of 23:30, January 20, 2019

/* Any JavaScript here will be loaded for all users on every page load. */
if (/iPhone|iPod|iPad/.test(navigator.userAgent)) {
  $('iframe').wrap(function() {
    var $this = $(this);
    return $('<div></div>').css({
      width: $this.attr('width'),
      height: $this.attr('height'),
      overflow: 'auto',
      '-webkit-overflow-scrolling': 'touch'
    });
  });
}