diff --git a/app/library/Assets.php b/app/library/Assets.php index 9c30af00..41606751 100644 --- a/app/library/Assets.php +++ b/app/library/Assets.php @@ -60,6 +60,7 @@ new FileAsset('scripts/base/angular-ui-date.js'), new FileAsset('scripts/base/angular-ui-router.js'), new FileAsset('scripts/base/angularytics.js'), + new FileAsset('scripts/base/tumblr.js'), new AssetCollection([ new GlobAsset('scripts/shared/*.coffee'), ], [ diff --git a/app/library/Gravatar.php b/app/library/Gravatar.php index 93794ce6..32091437 100644 --- a/app/library/Gravatar.php +++ b/app/library/Gravatar.php @@ -12,7 +12,7 @@  * @source http://gravatar.com/site/implement/images/php/  */ public static function getUrl( $email, $s = 80, $d = 'mm', $r = 'g') { - $url = 'http://www.gravatar.com/avatar/'; + $url = 'https://www.gravatar.com/avatar/'; $url .= md5( strtolower( trim( $email ) ) ); $url .= "?s=$s&d=$d&r=$r"; return $url; diff --git a/app/views/shared/_app_layout.blade.php b/app/views/shared/_app_layout.blade.php index f64e27d5..974020a2 100644 --- a/app/views/shared/_app_layout.blade.php +++ b/app/views/shared/_app_layout.blade.php @@ -86,7 +86,7 @@ @endsection @section('styles') - + {{ Assets::styleIncludes() }} @endsection @@ -123,6 +123,4 @@ {{ Assets::scriptIncludes() }} - - @endsection \ No newline at end of file diff --git a/public/scripts/base/tumblr.js b/public/scripts/base/tumblr.js new file mode 100644 index 00000000..06438f5d --- /dev/null +++ b/public/scripts/base/tumblr.js @@ -0,0 +1,3 @@ +var Tumblr=window.Tumblr||{};(function(){Tumblr.share_on_tumblr=function(anchor){var advanced=anchor.href.match(/(www.)?tumblr(\.com)?(\:\d{2,4})?\/share(.+)?/i);advanced=(advanced[4]!==undefined&&advanced[4].length>1);var d=document,w=window,e=w.getSelection,k=d.getSelection,x=d.selection,s=(e?e():(k)?k():(x?x.createRange().text:0)),f="http://www.tumblr.com/share",l=d.location,e=encodeURIComponent,p="?v=3&u="+e(l.href)+"&t="+e(d.title)+"&s="+e(s),u=f+p;if(advanced){u=anchor.href}try{if(!/^(.*\.)?tumblr[^.]*$/.test(l.host)){throw (0)}tstbklt()}catch(z){a=function(){if(!w.open(u,"t","toolbar=0,resizable=0,status=1,width=450,height=430")){l.href=u}};if(/Firefox/.test(navigator.userAgent)){setTimeout(a,0)}else{a()}}void (0)};Tumblr.activate_share_on_tumblr_buttons=function(){var anchors=document.getElementsByTagName("a"),anchors_length=anchors.length,match=false,old_onclick;for(var i=0;i