Here's what I've got in codebase.php
<?php
// ----------------------------------------------------------
// TagBlitz.com Plugin 1.0 for Coppermine Photo Gallery 1.4.6
// Copyright 2006 Jake Russell, All Rights Reserved
// ----------------------------------------------------------
//
// ----------------------------------------------------------
// Title: TagBlitz Plugin
// Version: 1.0 (stable)
// Author: Jake Russell - http://www.tagblitz.com
// Official Plugin Page: http://www.tagblitz.com/getcode.php
// Official Support Thread:
// Live environment test: CPG 1.4.6
// Tested with IE 6 and FF 1.5
// ----------------------------------------------------------
//
// ----------------------------------------------------------
// AVAILABLE CUSTOMIZATIONS (Available, but not required!)
// If you prefer a text link instead of the TagBlitz button,
// simply change {$buttoncode} to {$linkcode}
// (Near line 154)
// ----------------------------------------------------------
//
// ----------------------------------------------------------
// THIS PLUGIN IS OFFERED "AS-IS" IN THE HOPE THAT IT WILL BE
// USEFUL. NO WARRANTY OR GUARANTEE WHATSOEVER IS STATED OR
// IMPLIED.
//
// You may freely distribute this plugin.
// ----------------------------------------------------------
//
// ----------------------------------------------------------
// What does this plugin actually do?
//
// This plugin provides two valuable services for your CPG:
//
// First, it gives your users the ability to easily share
// your CPG pages with over 50 different social bookmarking
// websites and services, including del.icio.us, Technorati,
// digg.com, Myspace, AIM, furl, and Blogger, just to name a
// few.
//
// Second, it gives your CPG the ability to produce cut and
// paste linking codes so your visitors can post thumbnail
// and text links to your pages all over the web.
//
// All the links are permanent URLs, of course.
//
// Frankly, this is the best promotional plugin in the world.
// ----------------------------------------------------------
?>
<script language="javascript" type="text/javascript">
<!--
var win=null;
function NewWindow(mypage,myname,w,h,scroll,pos){
if(pos=="random"){LeftPosition=(screen.width)?Math.floor(Math.random()*(screen.width-w)):100;TopPosition=(screen.height)?Math.floor(Math.random()*((screen.height-h)-75)):100;}
if(pos=="center"){LeftPosition=(screen.width)?(screen.width-w)/2:100;TopPosition=(screen.height)?(screen.height-h)/2:100;}
else if((pos!="center" && pos!="random") || pos==null){LeftPosition=0;TopPosition=20}
settings='width='+w+',height='+h+',top='+TopPosition+',left='+LeftPosition+',scrollbars='+scroll+',location=no,directories=no,status=yes,menubar=no,toolbar=no,resizable=no';
win=window.open(mypage,myname,settings);}
// -->
</script>
<?php
if (!defined('IN_COPPERMINE')) die('Not in Coppermine...');
include ("{$CONFIG['ecards_more_pic_target']}/include/functions.inc.php");
// Create the BBcode with link to thumbnail
$bbcodethumb_url = get_pic_url($CURRENT_PIC_DATA, 'thumb');
// Add a filter
$thisplugin->add_filter('file_data','bbcode_add_data');
function bbcode_add_moredata($pic_data){ //$pic_data
$thumb_url = get_pic_url($pic_data, 'thumb');
$fullsized_url = get_pic_url($pic_data);
$normal_url = get_pic_url($pic_data, 'normal');
$pic_data['html'] = $thumb_url.'<br>'.$fullsized_url.'<br>'.$normal_url.'<br>'.$pic_data['html'];
return $pic_data; //return $pic_data
}
function bbcode_add_data($pic_data){
include ("{$CONFIG['ecards_more_pic_target']}/include/functions.inc.php");
// Set up variables to grab the picture title and absolute URL information
// Automatically grab and encode the Title
$title = "{$pic_data['title']}";
$title = urlencode($title);
// Automatically grab and encode the absolute URL
$url = "http://{$_SERVER['HTTP_HOST']}{$_SERVER['REQUEST_URI']}";
$url = preg_replace('/\?(.*)/','',$url);
$linkingurl = $url; // Set a separate unencoder URL for use in the Linking Codes section
$url = urlencode($url);
// Remove displayimage.php from $linkingurl for use in thumb url
$linkingurl2 = $linkingurl;
$linkingurl2 = preg_replace('/displayimage(.*)/','',$linkingurl2);
// Automatically grab and encode keywords, as defined in File Information section
$keys = "{$pic_data['keywords']}";
$keys = urlencode($keys);
//Define image URLs for linking codes
//Figure out whether to use the normal_ or fullsize image location depending on size
if($CONFIG['thumb_use']=='ht' && $pic_data['pheight'] > $CONFIG['picture_width'] ){ // The wierd comparision is because only picture_width is stored
$condition = true;
}elseif($CONFIG['thumb_use']=='wd' && $pic_data['pwidth'] > $CONFIG['picture_width']){
$condition = true;
}elseif($CONFIG['thumb_use']=='any' && max($pic_data['pwidth'], $pic_data['pheight']) > $CONFIG['picture_width']){
$condition = true;
}else{
$condition = false;
}
if ($CONFIG['make_intermediate'] && $condition ) {
$thumb_url = get_pic_url($pic_data, 'normal');
} else {
$thumb_url = get_pic_url($pic_data, 'fullsize');
}
$fullsized_url = get_pic_url($pic_data);
$downloadlink = get_pic_url($pic_data, 'normal');
$normal_url = get_pic_url($pic_data, 'normal');
// Set up the HTML template for the displayed data
$display_data = <<<EOT
<strong>Forum Linking Code</strong><br>
<textarea style="background-image:url(http://www.eclecticdaydreams.com/talk/templates/Chronicles/images/gen_background.jpg)" onFocus="this.select()" name="bbt" cols="50" rows="1">[url={$linkingurl}?pos=-{$pic_data['pid']}][img]{$linkingurl2}{$thumb_url}[/img][/url]</textarea><br/>
EOT;
$pic_data['html'] = $display_data.$pic_data['html'];
return $pic_data;
}
?>
<?
// Additional notes
//
// v 1.0.1 - Fixed issue with incorrect thumb URL in inking codes.
?>
Kevin