Saturday, 20 October 2012

PicasaWEB Portfolio in Blogger

Let me start by thanking Louis van Rensburg and Tim Haak for helping me on this one.

The original start information came from Blogger Xpertise -

You want to start by ensuring you have the JQuery Java code in your Blogger instance.

Now, editing the HTML part of a Blogger template can make everything break, so be sure to keep copies of the code somewhere save. It is also not totally dangerous as you can restore the template version anytime.

Edit the Blogger template: -> Template -> Edit HTML -> Read the warning -> Proceed -> and tick the "Expand Widget Templates"

Part 1:


<script src='' type='text/javascript'/>
<script src='' type='text/javascript'/>

Part 2:


<body expr:class='&quot;loading&quot; + data:blog.mobileClass'>

<!-- Thumbsnails from Picasa -->
<script type='text/javascript'>//<![CDATA[
function goThumbs(imageDestination, picasaEmail, picasaAlbum, picasaResults, picasaDimension){
 var url = '' + picasaEmail + '/album/' + picasaAlbum + '?kind=photo&imgmax=' + picasaDimension + '&max-results=' + picasaResults + '&alt=json';
    ($.getJSON(url, 'callback=?')).success(function(data){
  var slides   = new Array();
  var thumbs  = new Array();
  var captions  = new Array();
  var heights  = new Array();
  var widths  = new Array();
  var htmlthing = '';
  $(data.feed.entry).each(function(i, entry){
   slides[i]  = entry.content.src;
   thumbs[i] =$$thumbnail[0].url;
   if(i!='undefined') {
    htmlthing = htmlthing + '<a class="group1 cboxElement" href="' + slides[i] + '" rel="colorbox">';
    htmlthing = htmlthing + '<img src="'+thumbs[i]+'" /></a>';

<!-- End -->

Part 3:
<div>Here are some of my favourite photographs I've taken over the years. <br>

<script type="text/javascript">




<div class="separator" style="clear: both; text-align: center;" id="goThumbs" ></div>


Note: I'm calling a different LightBox than the default in Blogger, and I will share that information when I have it all.

ProxMox Unprivileged LXC containers USB Drive

Some quick notes on bind mounting under ProxMox and getting the permissions right. Reference -