This file contains 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
if($.browser.msie && parseInt($.browser.version) < 7) { ... } |
This file contains 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
var img = new Image(); | |
$(img) | |
// set the src attribute of the new image to our image | |
.attr('src', '/path/to/image.jpg') | |
// once the image has loaded, execute this code | |
.one('load', function () { | |
// remember to place into DOM first if you need access to width & height | |
// access width & height with this.width and this.height |
This file contains 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
// once folders are selected to delete, terminal into the folder and run these two commands: | |
svn update | |
svn resolve --accept working -R . |
This file contains 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
// Found within the guts of Stash: https://github.com/croxton/Stash | |
// set default value in 2nd param passed to TMPL::fetch_param() | |
$my_param = (bool) preg_match('/1|on|yes|y/i', $this->EE->TMPL->fetch_param('my_param', 'yes')); |
This file contains 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
// Taken from the guts of Stash: https://github.com/croxton/Stash | |
// is this method being called statically from PHP? | |
if (func_num_args() > 0 && !(isset($this) && get_class($this) == __CLASS__)) | |
{ | |
$this->EE->TMPL->tagparams['name'] = $name; | |
$this->EE->TMPL->tagparams['type'] = $type; | |
$this->EE->TMPL->tagparams['scope'] = $scope; | |
// as this function is called statically, | |
// we need to get an instance of this object and run get() |
This file contains 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 | |
// place this snippet at line 61 of system/expressionengine/views/content/publish.php | |
if(! array_key_exists('field_visibility', $field)) { | |
var_dump($name); | |
var_dump($field); | |
die; | |
} | |
?> |
This file contains 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 | |
$default_settings = array( | |
'setting1' => '', | |
'setting2' => '' | |
); | |
// assuming $settings has been passed | |
// interset & merge with defaults | |
$settings = array_merge($default_settings, array_intersect_key($settings, $default_settings)); |
This file contains 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
# OS Files | |
###################### | |
.DS_Store | |
# Files that change depending on server | |
###################### | |
.htaccess | |
.htpasswd | |
wp-config.php |
This file contains 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
# OS generated files # | |
###################### | |
.DS_Store | |
# Change depending on server | |
###################### | |
.htaccess | |
.htpasswd | |
# Backups, caches and logs # |
This file contains 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
<html><head><title></title><meta http-equiv="Content-Type" content="text/html; charset=utf-8"> | |
<style type="text/css"> | |
/* | |
* ======================================================================== | |
* Some cross-device, client-specific styles, courtesy of CampaignMonitor | |
* ======================================================================== | |
*/ | |
#outlook a { padding: 0; } /* Force Outlook to provide a "view in browser" button. */ | |
body { width: 100% !important; } |
OlderNewer