Here are a few common tasks you might do in your templates, as they would be written in ExpressionEngine vs. Craft CMS.
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
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <title>LESS PAD</title> | |
| <script src="https://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script> | |
| <script src="http://lesscss.googlecode.com/files/less-1.1.5.min.js"></script> | |
| <script> | |
| $( function () { | |
| var parser = new window.less.Parser(); | |
| var parse = function () { |
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
| // Add to 'Default (OSX).sublime-keymap' | |
| // Reverse selected lines. | |
| [ | |
| { "keys": ["super+shift+r"], "command": "permute_lines", "args": {"operation": "reverse"} } | |
| ] |
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
| /* @author 14islands.com | |
| * SASS mixins for future proof resolution media query | |
| */ | |
| @mixin if-min-resolution($dppx) { | |
| @include if-resolution(min, $dppx) { | |
| @content; | |
| } | |
| } |
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
| // Just before switching jobs: | |
| // Add one of these. | |
| // Preferably into the same commit where you do a large merge. | |
| // | |
| // This started as a tweet with a joke of "C++ pro-tip: #define private public", | |
| // and then it quickly escalated into more and more evil suggestions. | |
| // I've tried to capture interesting suggestions here. | |
| // | |
| // Contributors: @r2d2rigo, @joeldevahl, @msinilo, @_Humus_, | |
| // @YuriyODonnell, @rygorous, @cmuratori, @mike_acton, @grumpygiant, |
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
| $my-icons-spacing: 10px; // give some space to avoid little pixel size issues on resize | |
| @import "my-icons/*.png"; | |
| $my-icons-sprite-dimensions: true; | |
| @include all-my-icons-sprites; | |
| // the fun part |
This gist contains multiple files. Each file contains a specific type of Apex or Visualforce comment header.
When code is no longer used, but can not be deleted from your org, add the @deprecated annotation to the File or Method Header.
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
| /** | |
| * VH and VW units can cause issues on iOS devices: http://caniuse.com/#feat=viewport-units | |
| * | |
| * To overcome this, create media queries that target the width, height, and orientation of iOS devices. | |
| * It isn't optimal, but there is really no other way to solve the problem. In this example, I am fixing | |
| * the height of element `.foo` —which is a full width and height cover image. | |
| * | |
| * iOS Resolution Quick Reference: http://www.iosres.com/ | |
| */ | |
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
| This is now part of craft-scripts: | |
| https://github.com/nystudio107/craft-scripts |
This is a quick (rough) guide on how to protect a Serverpilot pilot app with auth basic
OlderNewer