This file contains hidden or 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
<?php | |
ini_set('memory_limit', '256M'); | |
ini_set('max_execution_time', '600'); | |
class Housekeeping extends BuildTask | |
{ | |
/** | |
* @var string | |
*/ |
This file contains hidden or 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
<?php | |
use SilverStripe\Core\Extension; | |
use SilverStripe\Forms\Form; | |
class CMSMainExtension extends Extension | |
{ | |
/** | |
* Removes the CMS preview by removing the literal field which | |
* renders the page. This needs to be attached to `CMSMain`: |
This file contains hidden or 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
<?php | |
$subsites = DataObject::get(Subsite::class)->map('ID', 'Title'); | |
$fields->insertBefore('internal_linkID', | |
DropdownField::create('internal_linkID_SubsiteID', 'Subsite') | |
->setSource($subsites->map('ID', 'Title')) | |
->addExtraClass('subsitestreedropdownfield-chooser no-change-track') | |
); | |
$internalLinkField = SubsitesTreeDropdownField::create( |
This file contains hidden or 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
// Credit to https://stackoverflow.com/a/9851769 | |
(function () { | |
// Opera 8.0+ | |
var isOpera = (!!window.opr && !!opr.addons) || !!window.opera || navigator.userAgent.indexOf(' OPR/') >= 0; | |
// Firefox 1.0+ | |
var isFirefox = typeof InstallTrigger !== 'undefined'; | |
// Safari 3.0+ "[object HTMLElementConstructor]" | |
var isSafari = (!!navigator.userAgent.match(/iPad/i) || !!navigator.userAgent.match(/iPhone/i) && !!navigator.userAgent.match(/WebKit/i) && !navigator.userAgent.match(/CriOS/i)) || /constructor/i.test(window.HTMLElement) || (function (p) { return p.toString() === "[object SafariRemoteNotification]"; })(!window['safari'] || (typeof safari !== 'undefined' && safari.pushNotification)); | |
// Internet Explorer 6-11 |
This file contains hidden or 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
/** | |
* Hangar 18 Website | |
*/ | |
/* html5doctor.com Reset v1.6.1 (http://html5doctor.com/html-5-reset-stylesheet/) - http://cssreset.com */ | |
html,body,div,span,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,abbr,address,cite,code,del,dfn,em,img,ins,kbd,q,samp,small,strong,sub,sup,var,b,i,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,figcaption,figure,footer,header,hgroup,menu,nav,section,summary,time,mark,audio,video{margin:0;padding:0;border:0;outline:0;font-size:100%;vertical-align:baseline;background:transparent} | |
body{line-height:1} | |
article,aside,details,figcaption,figure,footer,header,hgroup,menu,nav,section{display:block} | |
nav ul{list-style:none} | |
blockquote,q{quotes:none} | |
blockquote:before,blockquote:after,q:before,q:after{content:none} |