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
<img src="<?= $this->Thumb->clip_thumb('ImageFilename','300x300'); ?>" alt="" /> |
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
<IfModule mod_expires.c> | |
ExpiresActive On | |
ExpiresDefault "access plus 1 seconds" | |
ExpiresByType image/x-icon "access plus 2692000 seconds" | |
ExpiresByType image/jpeg "access plus 2692000 seconds" | |
ExpiresByType image/png "access plus 2692000 seconds" | |
ExpiresByType image/gif "access plus 2692000 seconds" | |
ExpiresByType application/x-shockwave-flash "access plus 2692000 seconds" | |
ExpiresByType text/css "access plus 2692000 seconds" | |
ExpiresByType text/javascript "access plus 2692000 seconds" |
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
sudo chmod 777 -R PATH |
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
function doc_append ( obj ){ | |
if( document.getElementsByTagName("head").length > 0 ){ | |
document.getElementsByTagName("head")[0].appendChild( obj ); | |
} | |
else{ | |
document.getElementsByTagName("body")[0].appendChild( obj ); | |
} | |
} | |
var url_css = 'http://example.com/css/file.css'; |
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
javascript:(function(){document.body.appendChild(document.createElement('script')).src='http://example.com/js/bookmarklet.min.js?r='+(Math.random()*99999999);})(); |
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
/* | |
AI, Auto Select an item from select dropdown, based on url | |
* @author fedmich | |
* @version 1.0 | |
*/ | |
function ai_autoselect ( css_select , url ){ | |
if( ! url ){ return; } | |
var obj_sel = $( css_select ) | |
if(obj_sel.val()){ | |
return true; //user already picked something, just skip |
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
=hyperlink("http://www.google.com/search?q=site:fedmich.com inurl:/works/";"site:fedmich.com inurl:/works/") |
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
import httplib, urllib | |
params = urllib.urlencode({ | |
'param': 'value', | |
'param2': 'value2' | |
}) | |
headers = { | |
"Content-type": "application/x-www-form-urlencoded", | |
"Accept": "text/plain" |
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
/* | |
Hides iframe from youtube, embedded objects | |
*/ | |
function hide_other_elements(){ | |
var iframes = document.getElementsByTagName('iframe'); | |
jQuery(iframes).each(function(){ | |
if( (this.src + '').match('http://www.youtube.com/embed/') ){ | |
jQuery( this ).parent().addClass('hidden_elements'); | |
} | |
}); |
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> | |
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.js" type="text/javascript"></script> | |
<script type="text/javascript"> | |
$(function() { | |
var obj_h2 = $('h2'); | |
var h2_title = obj_h2.html(); | |
var words = h2_title.split(' '); | |
words[0] = '<span>' + words[0] + '</span>' |
OlderNewer