Changeset - 7ec91347b83f
[Not reviewed]
components/com_morfeoshow/gallery.swf
Show inline comments
 
new file 100644
 
binary diff not shown
components/com_morfeoshow/gallery.xml
Show inline comments
 
new file 100644
 
<gallery title="MorfeoShow Gallery" thumbDir="/hot67beta/images/morfeoshow/" imageDir="/hot67beta/images/morfeoshow/" random="true">
 
<category name="Test Gallery">
 
</category>
 
</gallery
components/com_morfeoshow/images/front.png
Show inline comments
 
new file 100644
 
binary diff not shown
Show images
components/com_morfeoshow/images/index.html
Show inline comments
 
new file 100644
 
<html><body bgcolor="#FFFFFF"></body></html>
 
\ No newline at end of file
components/com_morfeoshow/images/loading.gif
Show inline comments
 
new file 100644
 
binary diff not shown
Show images
components/com_morfeoshow/images/no.png
Show inline comments
 
new file 100644
 
binary diff not shown
Show images
components/com_morfeoshow/images/overlay-85.png
Show inline comments
 
new file 100644
 
binary diff not shown
Show images
components/com_morfeoshow/index.html
Show inline comments
 
new file 100644
 
<html><body bgcolor="#FFFFFF"></body></html>
 
\ No newline at end of file
components/com_morfeoshow/morfeoshow.html.php
Show inline comments
 
new file 100644
 
<?php
 
/**
 
* @package		Joomla
 
* @subpackage	com_morfeoshow
 
* @copyright	Copyright (C) Vamba & Matthew Thomson. All rights reserved.
 
* @license		GNU/GPL.
 
* @author 		Vamba (.joomlaitalia.com) & Matthew Thomson (ignitejoomlaextensions.com)
 
* @based on  	com_ignitiongallery
 
* @author 		Matthew Thomson (ignitejoomlaextensions.com)
 
* Joomla! and com_morfeoshow are free software. This version may have been modified pursuant
 
* to the GNU General Public License, and as distributed they include or
 
* are derivative of works licensed under the GNU General Public License or
 
* other free or open source software licenses.
 
*/
 
 
defined( '_JEXEC' ) or die( 'Restricted access' );
 
jimport( 'joomla.application.component.view');
 
class HTML_morfeoshow{
 
 
function mostraFrontend($option, $rows, $pageNav, $limitstart, $limit, $total) {
 
	include_once(JPATH_SITE.DS.'administrator'.DS.'components'.DS.'com_morfeoshow'.DS.'settings.php' ); 
 
    global $mainframe;
 
    $params = &$mainframe->getParams();
 
	
 
	if ($params->get('show_page_title', 1)) : 
 
?>
 
<div class="componentheading<?php echo $params->get('pageclass_sfx'); ?>"><?php echo $params->get('page_title'); ?></div>
 
<?php endif; ?>
 
 
<table width="100%" cellpadding="0" cellspacing="0" border="0" align="center" class="contentpane<?php echo $params->get( 'pageclass_sfx' ); ?>">
 
 
<?php if ($params_morfeo['frontend'] == 1) { ?>
 
 
<table class="fltable<?php echo $params->get('pageclass_sfx'); ?>" border="0" cellpadding="0" cellspacing="0" width="100%">
 
 
<?php if ($params_morfeo['logo'] == 1) {	?>
 
		<div align="left">
 
			<img src="<?php echo JURI::root()?>components/com_morfeoshow/images/front.png">
 
		</div>
 
<?php }	else {} 
 
				JRequest::setVar('limit', (int) $limit);
 
				$link= JRoute::_('index.php?option=com_morfeoshow&Itemid='.JRequest::getVar('Itemid', NULL));
 
?>				
 
			<form action="<?php echo $link; ?>" method="post" name="Form">
 
			<table>
 
				<tr>
 
					<td align="right" width="100%" nowrap="nowrap">
 
					</td>
 
					<td align="right" width="100%" nowrap="nowrap">
 
					&nbsp;&nbsp;&nbsp; <?php echo JText::_( 'Display' ) ?> &nbsp;#&nbsp;
 
            
 
			<?php $link= JRoute::_('index.php?option=com_morfeoshow&Itemid='.JRequest::getVar('Itemid', NULL));
 
				echo $pageNav->getLimitBox($link);
 
?>					
 
					</td>
 
				</tr>
 
			</table>
 
			<input type="hidden" name="option" value="com_morfeoshow" />
 
		    </form>
 
<table>			
 
	<tr>
 
		<th width="40" align="left" class="toggler" nowrap="nowrap"></th>
 
		<th width="35%" align="left" class="toggler" nowrap="nowrap"><?php echo JText::_( 'Gallery' );?></th>	
 
		<th width="60%" align="left" class="toggler" nowrap="nowrap"><?php echo JText::_( 'Description' );?></th>	
 
	</tr>
 
	<?php	
 
		$tabclass = array("sectiontableentry1".$params->get( 'pageclass_sfx' )."", "sectiontableentry2".$params->get( 'pageclass_sfx' )."");
 
		$k =0;
 
		$j =1;	
 
		
 
		if (sizeof($rows)==0) { 
 
			} else {
 
		foreach ($rows as $row) { 
 
		echo "<tr class='". $tabclass[$k] ."'>";
 
		if ($row->shortcut_filename) {
 
		?>		
 
			<td>
 
				<a href="index.php?option=<?php echo $option; ?>&task=view&gallery=<?php echo $row->id; ?>">
 
				<img width="40" border="0" src="images/morfeoshow/<?php echo $row->folder; ?>/<?php echo $row->shortcut_filename; ?>"/></a>
 
			</td>
 
	<?php } else {	?>
 
			<td>
 
				<a href="index.php?option=<?php echo $option; ?>&task=view&gallery=<?php echo $row->id; ?>">
 
				<img width="40" border="0" src="<?php JURI::root()?>components/com_morfeoshow/images/no.png"/></a>
 
			</td>
 
	<?php }	?>			
 
			<td>
 
				<a href="index.php?option=<?php echo $option; ?>&task=view&gallery=<?php echo $row->id; ?>">
 
				<?php echo $row->name; ?></a>
 
	<?php	
 
			echo '</td>';
 
 
			echo '<td>';
 
			$row->description = stripslashes($row->description);			
 
			echo substr($row->description,0,120); 
 
				if (strlen($row->description)>120) 
 
				echo '...';
 
 
			echo '</td>';
 
			echo '</tr>';
 
				$k = 1 - $k; }}
 
		
 
	
 
			echo '<tr>';
 
			echo '<td colspan=\"4\">&nbsp;</td>';
 
			echo '</tr>';
 
			echo '<tr>';
 
			echo '<td align="center" colspan="4" class="sectiontablefooter'.$params->get( 'pageclass_sfx' ).'">';
 
				$link= JRoute::_('index.php?option=com_morfeoshow&Itemid='.JRequest::getVar('Itemid', NULL));
 
				echo $pageNav->getPagesLinks($link);
 
 
				echo '</td>';
 
			echo '</tr>';
 
			echo '<tr>';
 
			echo '<td colspan="4" align="right">';
 
 
			echo $pageNav->getPagesCounter();
 
				echo '</td>';
 
			echo '<tr>';
 
			
 
			
 
 
}if ($params_morfeo['frontend'] == 0) {
 
?>
 
 
	<tr>
 
		<td>
 
		<div id="flashcontent" align="middle">
 
			<a href="http://www.macromedia.com/go/getflashplayer">
 
				<?php echo JText::_( 'Get the Flash Player' );?></a> 
 
				<?php echo JText::_( 'to see this gallery.' );?>
 
		</div>
 
 
				<script type="text/javascript">
 
					var so = new SWFObject("<?php echo JURI::root()?>components/com_morfeoshow/gallery.swf", "gallery", "745", "700", "8", "#ffffff");
 
					so.addVariable("xmlURL","'.JURI::root().'components/com_morfeoshow/gallery.xml");			
 
					so.addParam("quality", "high");
 
					so.addParam("wmode", "transparent");
 
					so.write("flashcontent");
 
				</script>
 
			</td>
 
		</tr>
 
	
 
<?php
 
	}if ($params_morfeo['frontend'] == 2) {
 
	
 
$result = $total;	
 
if($result > 0) {
 
$x=0;
 
?>
 
<style>
 
a img, img 	{ border: none; text-decoration: none; }
 
.colonne	{padding: 5px;margin: 5px;border: 1px solid #999;display: block;width: <?php echo $params_morfeo['larfront']?>px;text-align:center;font-size:9px;text-decoration: none;}
 
.colonne:hover{border-color: white;text-decoration: none;}
 
</style>
 
<script src="<?php echo JURI::root(true)?>/components/com_morfeoshow/tpl/resources/boxover/boxover.js" type="text/javascript"></script>
 
<tr>
 
<?php
 
foreach ($rows as $row){
 
 
{
 
$x=$x+1;
 
 
if ($x % $params_morfeo['colonnefront'] == 0) { 
 
 
		if ($row->shortcut_filename) {
 
		?>		
 
			<td align="center">
 
				<a  class="colonne" href="index.php?option=<?php echo $option; ?>&task=view&gallery=<?php echo $row->id; ?>">
 
				<img width="<?php echo $params_morfeo['larfront']?>" border="0" src="images/morfeoshow/<?php echo $row->folder; ?>/<?php echo $row->shortcut_filename; ?>" title="header=[<?php echo $row->name?>] body=[<?php echo $row->description ?>]" /></a>
 
			</td></tr><tr>
 
	<?php } else {	?>
 
			<td align="center">
 
				<a  class="colonne" href="index.php?option=<?php echo $option; ?>&task=view&gallery=<?php echo $row->id; ?>">
 
				<img width="<?php echo $params_morfeo['larfront']?>" border="0" src="<?php JURI::root()?>components/com_morfeoshow/images/no.png" title="header=[<?php echo $row->name?>] body=[<?php echo $row->description ?>]"/></a>
 
			</td></tr><tr>
 
	<?php }	?>	
 
<?php				
 
}else{ 		
 
if ($row->shortcut_filename) {
 
		?>		
 
			<td align="center">
 
				<a  class="colonne" href="index.php?option=<?php echo $option; ?>&task=view&gallery=<?php echo $row->id; ?>">
 
				<img width="<?php echo $params_morfeo['larfront']?>" border="0" src="images/morfeoshow/<?php echo $row->folder; ?>/<?php echo $row->shortcut_filename; ?>" title="header=[<?php echo $row->name?>] body=[<?php echo $row->description ?>]"/></a>
 
			</td>
 
	<?php } else {	?>
 
			<td align="center">
 
				<a  class="colonne" href="index.php?option=<?php echo $option; ?>&task=view&gallery=<?php echo $row->id; ?>">
 
				<img width="<?php echo $params_morfeo['larfront']?>" border="0" src="<?php JURI::root()?>components/com_morfeoshow/images/no.png" title="header=[<?php echo $row->name?>] body=[<?php echo $row->description ?>]"/></a>
 
			</td>
 
	<?php }	?>	
 
<?php			
 
}
 
 
}
 
}
 
echo '<tr></tr><tr><br /></tr>';	
 
} 	
 
 }//end else
 
echo '</table>'; 
 
}//end frontend function
 
 
 
function elencafiles($dirname,$row){
 
	$arrayfiles=Array();
 
	if(file_exists($dirname)){
 
		$handle = opendir($dirname);
 
		while (false !== ($file = readdir($handle))) { 
 
			if(is_file($dirname.$file)){
 
				array_push($arrayfiles,$file);
 
			}
 
		}
 
		$handle = closedir($handle);
 
	}
 
	sort($arrayfiles);
 
	return $arrayfiles;
 
}
 
 
	
 
function mostraGalleria($option, $row) {	
 
	jimport('joomla.environment.uri' );
 
	global $params_morfeo, $mainframe;
 
	$db =& JFactory::getDBO();
 
    $param = &$mainframe->getParams();
 
		
 
			$query = 'SELECT COUNT(id)'
 
			. ' FROM #__morfeoshow_img'
 
			. ' WHERE gallery_id ='. (int) @$row->id 			
 
			;
 
			$db->setQuery( $query );
 
			$count 	= $db->loadResult();			
 
			$query = 'SELECT *'
 
			. ' FROM #__morfeoshow_img'
 
			. ' WHERE gallery_id ='. (int) @$row->id 
 
			. ' ORDER BY '. @$row->orderfront 			
 
			;
 
			$db->setQuery($query);
 
			$items = $db->loadObjectList();
 
			
 
	        
 
			//flash gallery params
 
			$params["flashgallery"]		= @$row->flashgallery;
 
			$params["height"]			= @$row->height;
 
			$params["width"]			= @$row->width;
 
			$params["height"]			= @$row->height;
 
			$params["widthsw"]			= @$row->widthsw;
 
			$params["heightsw"]			= @$row->heightsw;
 
			$params["widthpc"]			= @$row->widthpc;
 
			$params["heightpc"]			= @$row->heightpc;
 
			$params["widthpl"]			= @$row->widthpl;
 
			$params["heightpl"]			= @$row->heightpl;
 
			$params["width"]			= @$row->width;
 
			$params["trans"]			= @$row->trans;
 
			$params["navigation"]		= @$row->navigation;
 
			$params["movimento"]		= @$row->movimento;			
 
			$params["tempo"]			= @$row->tempo;
 
			$params["bkgnd"] 			= @$row->bkgnd;
 
			$params["bkgnd1"] 			= @$row->bkgnd1;
 
			$params["bkgnd2"] 			= @$row->bkgnd2;
 
			$params["bkgnd3"] 			= @$row->bkgnd3;
 
			$params["user_id"] 			= @$row->user_id;
 
			$params["group_id"] 		= @$row->group_id; 
 
			$params["text"] 			= @$row->text;
 
			$params["tags"] 			= @$row->tags; 
 
			$params["set_id"] 			= @$row->set_id; 
 
			$params["sort"] 			= @$row->sort;
 
			$params["user"] 			= @$row->pusername;
 
			$params["psingle"] 			= @$row->psingle;
 
			$params["pback"] 			= @$row->pback;
 
			$params["ph"] 				= @$row->paltezza;
 
			$params["pw"] 				= @$row->plarghezza;
 
			$params["overstretch"] 		= @$row->overstretch;
 
			$params["shuffle"] 			= @$row->shuffle;
 
			$params["template"] 		= @$row->tclassic;
 
			$params["colonne"] 			= @$row->tcol;	
 
 
 
echo '<table width="100%" cellpadding="0" cellspacing="0" border="0" align="center"><tr><td>';			
 
 
	if ($params_morfeo['description'] == 1) {			
 
	if (@$row->description1) {
 
	?>
 
	<fieldset class="morfeo">
 
	<table cellpadding="0" cellspacing="0" border="0" class="desctable">
 
		<tr>
 
			<td>
 
				<?php echo @$row->description1; ?>
 
			</td>
 
		</tr>
 
	</table>
 
	</fieldset>
 
<?php		
 
	}else{ }	
 
	}else{ }	
 
 
 
switch ($params["flashgallery"]) {
 
//case 0 Shadowboxgallery
 
case '0':
 
	$image_dir  = JPATH_SITE.DS.'images'.DS.'morfeoshow'.DS. $row->folder .DS.'big';
 
	$path1 		= JURI::root().'images/morfeoshow/'. $row->folder .'/big/';
 
	$path2 		= JURI::root().'images/morfeoshow/'. $row->folder.'/thumbs/';	
 
 
	switch ($params["template"]) {
 
			case '0':
 
			require_once( JPATH_COMPONENT.DS.'tpl'.DS.'classic/shadowbox1.php' );
 
			break;
 
			
 
			case '1':
 
			require_once( JPATH_COMPONENT.DS.'tpl'.DS.'classic/shadowbox2.php' );
 
			break;
 
 
			case '2':
 
			require_once( JPATH_COMPONENT.DS.'tpl'.DS.'classic/shadowbox3.php' );
 
			break;
 
			
 
			case '3':
 
			require_once( JPATH_COMPONENT.DS.'tpl'.DS.'classic/shadowbox4.php' );
 
			break;	
 
 
			case '4':
 
			//fancybox first style
 
			require_once( JPATH_COMPONENT.DS.'tpl'.DS.'classic/fancybox1.php' );
 
			break;	
 
 
			case '5':
 
			//fancybox second style
 
			require_once( JPATH_COMPONENT.DS.'tpl'.DS.'classic/fancybox2.php' );
 
			break;
 
			
 
			case '6':
 
			//fancybox first style
 
			require_once( JPATH_COMPONENT.DS.'tpl'.DS.'classic/fancybox3.php' );
 
			break;	
 
 
			case '7':
 
			//fancybox second style
 
			require_once( JPATH_COMPONENT.DS.'tpl'.DS.'classic/fancybox4.php' );
 
			break;			
 
	
 
		}	
 
	
 
break;
 
//case 1 Imagerotatorgallery
 
case '1':	
 
	
 
				if	 ( $params["trans"] == 0 ) {	$trans = "random";
 
			} elseif ( $params["trans"] == 1 ) {	$trans = "fade"; 
 
			} elseif ( $params["trans"] == 2 ) {	$trans = "blocks"; 
 
			} elseif ( $params["trans"] == 3 ) { 	$trans = "circles"; 
 
			} elseif ( $params["trans"] == 4 ) {	$trans = "bubbles"; 
 
			} elseif ( $params["trans"] == 5 ) {	$trans = "lines"; 
 
			} elseif ( $params["trans"] == 6 ) {	$trans = "slowfade";
 
			} elseif ( $params["trans"] == 7 ) {	$trans = "fluids"; 
 
			} elseif ( $params["trans"] == 8 ) {	$trans = "flash"; 
 
			} elseif ( $params["trans"] == 9 ) {	$trans = "bgfade";			
 
				}
 
 
				if    ( $params['navigation'] == 1 ) { 	$nav = "true";	
 
			} else if ( $params['navigation'] == 0 ) {	$nav = "false"; 
 
				}
 
				
 
				if    ( $params['overstretch'] == 1 ) { $overstretch = "true";	
 
			} else if ( $params['overstretch'] == 0 ) {	$overstretch = "false"; 
 
				}	
 
 
				if    ( $params['shuffle'] == 1 ) { $shuffle = "true";	
 
			} else if ( $params['shuffle'] == 0 ) {	$shuffle = "false"; 
 
				}					
 
 
				if	  ( $params['movimento'] == 1 ) {	$mov = "true";	
 
			} else if ( $params['movimento'] == 0 ) {	$mov = "false"; 		
 
				}	
 
			require_once( JPATH_COMPONENT.DS.'tpl'.DS.'imagerotator/imagerotator.php' );	
 
break;
 
//case 2 Imageviwergallery		
 
case '2':
 
			require_once( JPATH_COMPONENT.DS.'tpl'.DS.'imageviewer/imageviewer.php' );
 
break;
 
//case3 Postcardgallery
 
case '3':
 
			require_once( JPATH_COMPONENT.DS.'tpl'.DS.'postcard/postcard.php' );
 
 
break;
 
//case4 Polaroidgallery
 
case '4':
 
			require_once( JPATH_COMPONENT.DS.'tpl'.DS.'polaroid/polaroid.php' );
 
break;
 
//case5 Flickr
 
case '5':
 
 
					if    ( $params['sort'] == 1 ) { 	$sort = "sort=relevance";	
 
				} else if ( $params["sort"] == 0 ) {	$sort = "sort="; 
 
				} 
 
 
				
 
echo '
 
				<table class="fltable" border="0" cellpadding="0" cellspacing="0" width="100%">
 
					<tr>
 
						<td align="center">
 
							<iframe align="center" src="http://www.flickr.com/slideShow/index.gne?user_id='.$params["user_id"].'&group_id='.$params["group_id"].'&text='.$params["text"].'&tags='.$params["tags"].'&set_id='.$params["set_id"].'&'.$sort.'" frameBorder="0" width="500" scrolling="no" height="500"></iframe>	
 
							</iframe>
 
						</td>
 
					</tr>
 
				</table>
 
';				
 
 
break;
 
//case6 Flickr 2
 
case '6':
 
 
			  		if    ( $params['user_id'] == '' ) { 	$user = "";	
 
						} else {							$user = $params["user_id"]."/"; 
 
				} 
 
			 		if    ( $params['tags'] ) { 			$tags = "tags/".$params["tags"];	
 
						} else {							$tags = ""; 
 
				} 
 
			 		if    ( $params['set_id'] == '') { 		$set = "";	
 
						} else {							$set = "/sets/".$params["set_id"];
 
				} 
 
			 		if    ( $params['sort'] == 1 ) { 		$int = "/interesting";	
 
						} else {							$int = ""; 
 
				} 		
 
			 
 
echo '
 
				<table class="fltable" border="0" cellpadding="0" cellspacing="0" width="100%">
 
					<tr>
 
						<td align="center">
 
							<iframe align="center" src="http://www.flickr.com/photos/'.$user . $tags . $set .$int . '/show" frameBorder="0" width="730" scrolling="no" height="560">
 
							</iframe>
 
						</td>
 
					</tr>
 
				</table>
 
';	
 
 
break;
 
//case7 Flickr Map
 
case '7':
 
			echo '
 
				<table class="fltable" border="0" cellpadding="0" cellspacing="0" width="100%">
 
					<tr>
 
						<td align="center">
 
							<iframe align="center" src="http://flickr.com/map/?&fLat='.$row->glat.'&fLon='.$row->glng.'&zl=5&map_type=hyb&order_by=interestingness" frameBorder="0" width="700" scrolling="no" height="550"></iframe>
 
							</iframe>
 
						</td>
 
					</tr>
 
				</table>
 
			';	
 
break;
 
//case8 Google Map
 
case '8':
 
?>
 
	<table border="0" cellpadding="0" cellspacing="0" width="100%">
 
		<tr>
 
			<td align="center">
 
<?php
 
			//Recupera dati
 
			$latitudine 	= $row->glat;
 
			$longitudine 	= $row->glng;
 
			$zoom 			= $row->gzoom;
 
			$name 			= $row->name;
 
			$name 			= $row->luogo;
 
			$descrizione 	= $row->description;
 
			$gmapkey 		= $row->gmapkey;
 
?>	
 
<meta name="gmapkey" content="<?php echo $gmapkey ;?>" />
 
    <script
 
	  src="<?php echo JURI::root()?>components/com_morfeoshow/src/js/gmapez-2.js"
 
      type="text/javascript"></script>
 
<div id="contenuto" style="padding-left:10px;padding-right:10px;padding-top:10px;">	  
 
<div class="GMapEZ GLargeMapControl GMapTypeControl GScaleControl GOverviewMapControl" style="width: 600px; height: 480px;">
 
  <?php 
 
echo '<a href="' . ('http://maps.google.com/maps?ll=' . $latitudine . ',' . $longitudine . '&amp;spn=0.006130,0.239795&amp;') . '">';
 
	echo 'EXTENT';
 
	echo 'A OPEN';
 
		echo '</a>';
 
		echo '<div title="'.$name.'">';
 
			echo '<table>';		
 
			echo '<tr>';
 
		    echo '<td valign="top">';
 
		    echo '<span style="font-size:14px;font-weight:bold;color:#004080;">';
 
			echo $name;
 
		    echo '</span><br />';
 
			echo $descrizione;
 
		    echo '</tr>';
 
		    echo '</table>';			
 
	echo '</div>';
 
 
?>
 
</div>
 
</div>		
 
		</td>
 
		</tr>
 
		</table>
 
<?php
 
break;
 
//case9 Picasa
 
case '9':
 
	global $mainframe, $params_morfeo;
 
			require_once( JPATH_COMPONENT.DS.'tpl'.DS.'picasa/picasa.php' );
 
break;
 
 
//case10 flickr single gallery
 
case '10':
 
	global $mainframe, $params_morfeo;
 
 
	require_once(JPATH_COMPONENT.DS.'tpl'.DS.'resources'.DS.'phpFlickr'.DS.'phpFlickr.php');
 
	
 
	$f 				= new phpFlickr($params_morfeo['flickrkey']); 
 
	$photoset_id 	= $params['set_id'];
 
	$photos 		= $f->photosets_getPhotos($photoset_id);	
 
	
 
	require_once( JPATH_COMPONENT.DS.'tpl'.DS.'flickrsingle/flickrsingle.php' );
 
break;
 
 
//case10 picasa single gallery
 
case '11':
 
	global $mainframe, $params_morfeo;
 
 
	$userid		 	=  $params['user'];
 
	$gallery 		=  $params['psingle'];
 
	$background		=  $params['pback'];	
 
	$ph				=  $params['ph'];
 
	$pw				=  $params['pw'];
 
?>
 
				<table class="fltable" border="0" cellpadding="0" cellspacing="0" width="100%">
 
					<tr>
 
						<td align="center">
 
<embed pluginspage = "http://www.macromedia.com/go/getflashplayer" src="http://picasaweb.google.com/s/c/bin/slideshow.swf" flashvars="host=picasaweb.google.com&amp;RGB=0x<?php echo $background ?>&amp;feed=http%3A%2F%2Fpicasaweb.google.com%2Fdata%2Ffeed%2Fapi%2Fuser%2F<?php echo $userid ?>%2Falbumid%2F<?php echo $gallery ?>%3Fkind%3Dphoto%26alt%3Drss" wmode="transparent" type ="application/x-shockwave-flash" height ="<?php echo $ph ?>" width="<?php echo $pw ?>"></embed>
 
						</td>
 
					</tr>
 
				</table>
 
<?php	
 
break;
 
					
 
	}
 
	if ($params_morfeo['description'] == 0) {	
 
	if (@$row->description1) {
 
	?>
 
	<fieldset class="morfeo">
 
	<table cellpadding="0" cellspacing="0" border="0" class="desctable">
 
		<tr>
 
			<td>
 
				<?php echo @$row->description1; ?>
 
			</td>
 
		</tr>
 
	</table>
 
	</fieldset>
 
<?php	}else{ } 
 
		}else{ }  ?>
 
<?php
 
		if ($params_morfeo['back'] == 0) { ?>	
 
			<div class="back_button" align="center">
 
			<a href="index.php?option=com_morfeoshow&Itemid=<?php echo JRequest::getVar('Itemid', NULL); ?>">	
 
				<?php echo JText::_( 'Back' ); ?></a>
 
			</div>
 
<?php			
 
		echo '</td></tr></table>';		
 
		} else {
 
		echo '</td></tr></table>';
 
		}		
 
	}
 
}
 
?>
 
\ No newline at end of file
components/com_morfeoshow/morfeoshow.php
Show inline comments
 
new file 100644
 
<?php
 
/**
 
* @package		Joomla
 
* @subpackage	com_morfeoshow
 
* @copyright	Copyright (C) Vamba & Matthew Thomson. All rights reserved.
 
* @license		GNU/GPL.
 
* @author 		Vamba (.joomlaitalia.com) & Matthew Thomson (ignitejoomlaextensions.com)
 
* @based on  	com_ignitiongallery
 
* @author 		Matthew Thomson (ignitejoomlaextensions.com)
 
* Joomla! and com_morfeoshow are free software. This version may have been modified pursuant
 
* to the GNU General Public License, and as distributed they include or
 
* are derivative of works licensed under the GNU General Public License or
 
* other free or open source software licenses.
 
*/
 

	
 
defined( '_JEXEC' ) or die( 'Restricted access' );
 

	
 
require_once( JApplicationHelper::getPath( 'html' ) );
 
$task 		= JRequest::getString('task', '');
 
$gallery 	= JRequest::getInt('gallery', 0);
 
// cache activation
 
$cache =& JFactory::getCache( 'com_morfeoshow' );
 

	
 
switch($task) {
 
	case 'view': 	mostraGalleria($option, $gallery);			break;
 
		default:	mostraFrontend($option);					break;
 
}
 

	
 
function mostraFrontend($option){
 
global $mainframe, $header, $params_morfeo;
 
	$db 		=& JFactory::getDBO();	
 
	$result		= JRequest::getVar('result', 0, '', 'int');
 
	$default_limit = '20';
 
	$limit = $mainframe->getUserStateFromRequest('com_morfeoshow', 'limit', $default_limit, 'int');	
 
	$limitstart	= JRequest::getVar('limitstart', 0, '', 'int');	
 
	JRequest::setVar('limit', (int) $limit);
 
	static $HeaderAdded;
 
		if(!$HeaderAdded) {
 
		$HeaderAdded=1;	
 
		$header .= '
 
		<script type="text/javascript" src="'.JURI::root(true).'/components/com_morfeoshow/src/js/swfobject.js"></script>			
 
		<style type="text/css" media="all">	
 
	@import "'.JURI::root(true).'/components/com_morfeoshow/style/style.css"; 	
 
		</style>
 
	';	
 
 
	$mainframe->addCustomHeadTag($header);
 
}
 

	
 
	// get the total number of records
 
	$query = 'SELECT COUNT(id)'
 
	. ' FROM #__morfeoshow'
 
	. ' WHERE published = 1'	
 
	;
 
	$db->setQuery( $query );
 
	$total 	= $db->loadResult();
 
	jimport('joomla.html.pagination');
 
	$pageNav = new JPagination( $total, $limitstart, $limit );
 
	
 
	$query 	= "SELECT * FROM #__morfeoshow WHERE published = 1 ORDER by ordering"
 
	;
 
	$db->setQuery( $query, $pageNav->limitstart, $pageNav->limit );	
 
	$rows = $db->loadObjectList();
 
 
	if ($db->getErrorNum()) {
 
		echo $db->stderr();
 
		return false;
 
	}
 
	
 
	HTML_morfeoshow::mostraFrontend($option, $rows, $pageNav, $limitstart, $limit, $total);
 
}
 

	
 
function mostraGalleria($option, $gallery){
 
	
 
	global $mainframe, $params_morfeo;
 
	$db 		=& JFactory::getDBO();
 
	$task 		= JRequest::getString('task', '');
 
	include_once(JPATH_SITE.DS.'administrator'.DS.'components'.DS.'com_morfeoshow'.DS.'settings.php' ); 
 
	
 
	$query = "SELECT * FROM #__morfeoshow WHERE id =" .(int)$gallery;
 
	$db->setQuery($query);
 
	$row = $db->loadObject();
 
    $skin ="classic";
 
	$lang =$params_morfeo['shulang'];
 
	$pla ="img";
 
	$params['template'] = @$row->tclassic;	
 
	
 
	static $HeaderAdded;
 
		if(!$HeaderAdded) {
 
		$HeaderAdded=1;
 
		$header='';		
 
		if (@$row->flashgallery == 0) {
 
 
		if ($params['template'] == 4 || $params['template'] == 5 || $params['template'] == 6|| $params['template'] == 7) 
 
		{	
 
 
	if ($params_morfeo['gapi'] == 0) 
 
	{	
 
		$header .= '
 
	<script src="'.JURI::root(true).'/components/com_morfeoshow/src/js/jquery-1.2.3.pack.js" type="text/javascript"></script>		
 
		';
 
		} else {
 
		$header .= '
 
	<script src="http://www.google.com/jsapi"></script>
 
	<script>
 
	google.load("jquery", "1.2.6");
 
	</script>	
 
		';
 
	}
 
 
		$header .= '
 
		<script src="'.JURI::root(true).'/components/com_morfeoshow/tpl/resources/fancy/jquery.fancybox-1.0.0.js" type="text/javascript"></script>
 
		<script src="'.JURI::root(true).'/components/com_morfeoshow/tpl/resources/fancy/jquery.pngFix.pack.js" type="text/javascript"></script>	
 
		<link rel="stylesheet" href="'.JURI::root(true).'/components/com_morfeoshow/style/style.css" />
 
		<link rel="stylesheet" href="'.JURI::root(true).'/components/com_morfeoshow/tpl/resources/fancy/fancy.css" />
 
	<script type="text/javascript">
 
		$(document).ready(function() {
 
			$(".photo-link").fancybox({ "zoomSpeedIn": 500, "zoomSpeedOut": 500, "overlayShow": true }); 
 
		});
 
	</script>		
 
';
 
	} 
 
	else
 
	{
 
 
	switch ($params_morfeo['shuadat']) {
 
		case 'shadowbox-jquery.js':	
 
	if ($params_morfeo['gapi'] == 0) 
 
	{	
 
		$header .= '
 
	<script src="'.JURI::root(true).'/components/com_morfeoshow/src/js/jquery-1.2.3.pack.js" type="text/javascript"></script>		
 
		';
 
		} else {
 
		$header .= '
 
	<script src="http://www.google.com/jsapi"></script>
 
	<script>
 
	google.load("jquery", "1.2.6");
 
	</script>	
 
		';
 
	}		
 
break;
 
		case 'shadowbox-mootools.js':
 
	if ($params_morfeo['gapi'] == 0) 
 
	{			
 
		$header .= '
 
	<script src="'.JURI::root(true).'/components/com_morfeoshow/src/js/mootools.js" type="text/javascript"></script>		
 
		';
 
		} else {
 
		$header .= '
 
	<script src="http://www.google.com/jsapi"></script>
 
	<script>
 
	google.load("mootools", "1.11");
 
	</script>	
 
		';
 
	}			
 
break;	
 
		case 'shadowbox-prototype.js':
 
	if ($params_morfeo['gapi'] == 0) 
 
	{			
 
		$header .= '
 
	<script src="'.JURI::root(true).'/components/com_morfeoshow/src/js/prototype.js" type="text/javascript"></script>		
 
		';
 
		} else {
 
		$header .= '
 
	<script src="http://www.google.com/jsapi"></script>
 
	<script>
 
	google.load("prototype", "1.6");
 
	</script>	
 
		';
 
	}		
 
break;
 
		case 'shadowbox-yui.js':	
 
		$header .= '
 
	<script src="'.JURI::root(true).'/components/com_morfeoshow/src/js/yui-utilities.js" type="text/javascript"></script>		
 
		';
 
 
break;
 
		case 'shadowbox-dojo.js':
 
	if ($params_morfeo['gapi'] == 0) 
 
	{			
 
		$header .= '
 
	<script src="'.JURI::root(true).'/components/com_morfeoshow/src/js/dojo.js" type="text/javascript"></script>		
 
		';
 
		} else {
 
		$header .= '
 
	<script src="http://www.google.com/jsapi"></script>
 
	<script>
 
	google.load("dojo", "1.1.1");
 
	</script>	
 
		';
 
	}		
 
break;	
 
 
}	
 
		
 
		$header .= '
 
	<script type="text/javascript" src="'.JURI::root(true).'/components/com_morfeoshow/src/adapter/'.$params_morfeo['shuadat'].'"></script>
 
	<script type="text/javascript" src="'.JURI::root(true).'/components/com_morfeoshow/src/shadowbox.js"></script>
 
		<link rel="stylesheet" href="'.JURI::root(true).'/components/com_morfeoshow/style/style.css" />
 
	<script type="text/javascript">
 
Shadowbox.loadSkin("'.$skin.'", "'.JURI::root(true).'/components/com_morfeoshow/src/skin");
 
Shadowbox.loadLanguage("'.$lang.'", "'.JURI::root(true).'/components/com_morfeoshow/src/lang");
 
Shadowbox.loadPlayer(["'.$pla.'"], "'.JURI::root(true).'/components/com_morfeoshow/src/player");
 
window.onload = function(){
 
    Shadowbox.init();
 
};
 

	
 
</script>
 
	';
 
	}	
 
	} else if ($row->flashgallery == 9) {
 
	
 
	if ($params_morfeo['gapi'] == 0) 
 
	{			
 
		$header .= '
 
	<script src="'.JURI::root(true).'/components/com_morfeoshow/src/js/jquery-1.2.3.pack.js" type="text/javascript"></script>		
 
		';
 
		} else {
 
		$header .= '
 
	<script src="http://www.google.com/jsapi"></script>
 
	<script>
 
	google.load("jquery", "1.2.6");
 
	</script>	
 
		';
 
	}		
 
		$header .= '
 
		<script src="'.JURI::root(true).'/components/com_morfeoshow/src/js/jquery.blockUI-1.33.pack.js" type="text/javascript"></script>
 
		<script src="'.JURI::root(true).'/components/com_morfeoshow/src/js/jquery.history.pack.js" type="text/javascript"></script>
 
		<script src="'.JURI::root(true).'/components/com_morfeoshow/tpl/resources/lightbox/lb.js" type="text/javascript"></script>			
 
		<script src="'.JURI::root(true).'/components/com_morfeoshow/src/js/picas.js" type="text/javascript"></script>
 
		<link rel="stylesheet" href="'.JURI::root(true).'/components/com_morfeoshow/style/style.css" />
 
		<link rel="stylesheet" href="'.JURI::root(true).'/components/com_morfeoshow/src/js/css/pic.css" />
 
		<link rel="stylesheet" href="'.JURI::root(true).'/components/com_morfeoshow/tpl/resources/lightbox/lb.css" />		
 
 
';	
 
 
	} else if ($row->flashgallery == 10) {
 
	
 
	if ($params_morfeo['gapi'] == 0) 
 
	{			
 
		$header .= '
 
	<script src="'.JURI::root(true).'/components/com_morfeoshow/src/js/jquery-1.2.3.pack.js" type="text/javascript"></script>		
 
		';
 
		} else {
 
		$header .= '
 
	<script src="http://www.google.com/jsapi"></script>
 
	<script>
 
	google.load("jquery", "1.2.6");
 
	</script>	
 
		';
 
	}		
 
		$header .= '
 
		<script src="'.JURI::root(true).'/components/com_morfeoshow/tpl/resources/fancy/jquery.fancybox-1.0.0.js" type="text/javascript"></script>
 
		<script src="'.JURI::root(true).'/components/com_morfeoshow/tpl/resources/fancy/jquery.pngFix.pack.js" type="text/javascript"></script>	
 
		<link rel="stylesheet" href="'.JURI::root(true).'/components/com_morfeoshow/style/style.css" />
 
		<link rel="stylesheet" href="'.JURI::root(true).'/components/com_morfeoshow/tpl/resources/fancy/fancy.css" />		
 
	<script type="text/javascript">
 
		$(document).ready(function() {
 
			$(".gallflickr").fancybox({ "zoomSpeedIn": 500, "zoomSpeedOut": 500, "overlayShow": true }); 
 
		});
 
	</script>	
 
';	
 
	
 
	}
 
	else
 
	{
 
 
		$header .= '
 
		<script type="text/javascript" src="'.JURI::root(true).'/components/com_morfeoshow/src/js/swfobject.js"></script>		
 
		<link rel="stylesheet" href="'.JURI::root(true).'/components/com_morfeoshow/style/style.css" />
 
	';	
 
	}//end else
 
	
 
	$mainframe->addCustomHeadTag($header);
 
	
 
	}//end of header		
 
	
 
	$mainframe->setPageTitle( stripslashes(@$row->name) );
 
	if (@$row->metadesc == ''){}else{
 
	$mainframe->prependMetaTag('description',$row->metadesc);
 
	}
 
	if (@$row->metakey == ''){}else{
 
	$mainframe->prependMetaTag('keywords',$row->metakey.", ");
 
	}	
 
	jimport('joomla.environment.uri' );
 
	$host = JURI::root();
 
	
 
	HTML_morfeoshow::mostraGalleria($option, $row, $task);
 
}
 
?>
 
\ No newline at end of file
components/com_morfeoshow/myphoto/index.html
Show inline comments
 
new file 100644
 
<html><body bgcolor="#FFFFFF"></body></html>
 
\ No newline at end of file
components/com_morfeoshow/router.php
Show inline comments
 
new file 100644
 
<?php
 
/**
 
* @package		Joomla
 
* @subpackage	com_morfeoshow
 
* @copyright	Copyright (C) Vamba & Matthew Thomson. All rights reserved.
 
* @license		GNU/GPL.
 
* @author 		Vamba (.joomlaitalia.com) & Matthew Thomson (ignitejoomlaextensions.com)
 
* @based on  	com_ignitiongallery
 
* @author 		Matthew Thomson (ignitejoomlaextensions.com)
 
* Joomla! and com_morfeoshow are free software. This version may have been modified pursuant
 
* to the GNU General Public License, and as distributed they include or
 
* are derivative of works licensed under the GNU General Public License or
 
* other free or open source software licenses.
 
*/
 
 
defined( '_JEXEC' ) or die( 'Restricted access' );
 
 
function morfeoshowBuildRoute(&$query) {
 
	$segments = array();
 
	if (isset($query['task']))	{
 
		$segments[] = $query['task'];
 
		unset($query['task']);
 
	}
 
	if(isset($query['gallery']))	{
 
		$segments[] = $query['gallery'];
 
		unset($query['gallery']);
 
	}
 
	return $segments;
 
}
 
 
function morfeoshowParseRoute($segments) {
 
	$vars = array();
 
	$vars['task'] 		= $segments[0];
 
	$vars['gallery'] 	= $segments[1];
 
	return $vars;
 
}
 
 
?>
 
\ No newline at end of file
components/com_morfeoshow/src/adapter/index.html
Show inline comments
 
new file 100644
 
<html>
 
<body bgcolor="#FFFFFF">
 
</body>
 
</html>
 
\ No newline at end of file
components/com_morfeoshow/src/adapter/shadowbox-base.js
Show inline comments
 
new file 100644
 
/**
 
 * A base library for Shadowbox used as a standalone (without another base
 
 * library/adapter combination).
 
 *
 
 * This file is part of Shadowbox.
 
 *
 
 * Shadowbox is an online media viewer application that supports all of the
 
 * web's most popular media publishing formats. Shadowbox is written entirely
 
 * in JavaScript and CSS and is highly customizable. Using Shadowbox, website
 
 * authors can showcase a wide assortment of media in all major browsers without
 
 * navigating users away from the linking page.
 
 *
 
 * Shadowbox is released under version 3.0 of the Creative Commons Attribution-
 
 * Noncommercial-Share Alike license. This means that it is absolutely free
 
 * for personal, noncommercial use provided that you 1) make attribution to the
 
 * author and 2) release any derivative work under the same or a similar
 
 * license.
 
 *
 
 * If you wish to use Shadowbox for commercial purposes, licensing information
 
 * can be found at http://mjijackson.com/shadowbox/.
 
 *
 
 * @author      Michael J. I. Jackson <mjijackson@gmail.com>
 
 * @copyright   2007-2008 Michael J. I. Jackson
 
 * @license     http://creativecommons.org/licenses/by-nc-sa/3.0/
 
 * @version     SVN: $Id: shadowbox-base.js 103 2008-06-27 06:19:21Z mjijackson $
 
 */
 

	
 
// create the Shadowbox object first
 
var Shadowbox = {};
 

	
 
Shadowbox.lib = function(){
 

	
 
    // local style camelizing for speed
 
    var styleCache = {};
 
    var camelRe = /(-[a-z])/gi;
 
    var camelFn = function(m, a){
 
        return a.charAt(1).toUpperCase();
 
    };
 
    var toCamel = function(style){
 
        var camel;
 
        if(!(camel = styleCache[style])){
 
            camel = styleCache[style] = style.replace(camelRe, camelFn);
 
        }
 
        return camel;
 
    };
 

	
 
    var view = document.defaultView;
 
    var alphaRe = /alpha\([^\)]*\)/gi;
 

	
 
    /**
 
     * Sets the opacity of the given element to the specified level.
 
     *
 
     * @param   {HTMLElement}   el          The element
 
     * @param   {Number}        opacity     The opacity to use
 
     * @return  void
 
     * @private
 
     * @static
 
     */
 
    var setOpacity = function(el, opacity){
 
        var s = el.style;
 
        if(window.ActiveXObject){ // IE
 
            s.zoom = 1; // give "layout"
 
            s.filter = (s.filter || '').replace(alphaRe, '') +
 
                (opacity == 1 ? '' : ' alpha(opacity=' + (opacity * 100) + ')');
 
        }else{
 
            s.opacity = opacity;
 
        }
 
    };
 

	
 
    return {
 

	
 
        adapter: 'standalone',
 

	
 
        /**
 
         * Gets the value of the style on the given element. This function
 
         * adapted from Ext.Element.getStyle().
 
         *
 
         * @param   {HTMLElement}   el      The DOM element
 
         * @param   {String}        style   The name of the style (e.g. margin-top)
 
         * @return  {mixed}                 The value of the given style
 
         * @public
 
         * @static
 
         */
 
        getStyle: function(){
 
            return view && view.getComputedStyle
 
                ? function(el, style){
 
                    var v, cs, camel;
 
                    if(style == 'float') style = 'cssFloat';
 
                    if(v = el.style[style]) return v;
 
                    if(cs = view.getComputedStyle(el, '')){
 
                        return cs[toCamel(style)];
 
                    }
 
                    return null;
 
                }
 
                : function(el, style){
 
                    var v, cs, camel;
 
                    if(style == 'opacity'){
 
                        if(typeof el.style.filter == 'string'){
 
                            var m = el.style.filter.match(/alpha\(opacity=(.+)\)/i);
 
                            if(m){
 
                                var fv = parseFloat(m[1]);
 
                                if(!isNaN(fv)) return (fv ? fv / 100 : 0);
 
                            }
 
                        }
 
                        return 1;
 
                    }else if(style == 'float'){
 
                        style = 'styleFloat';
 
                    }
 
                    var camel = toCamel(style);
 
                    if(v = el.style[camel]) return v;
 
                    if(cs = el.currentStyle) return cs[camel];
 
                    return null;
 
                };
 
        }(),
 

	
 
        /**
 
         * Sets the style on the given element to the given value. May be an
 
         * object to specify multiple values. This function adapted from
 
         * Ext.Element.setStyle().
 
         *
 
         * @param   {HTMLElement}   el      The DOM element
 
         * @param   {String/Object} style   The name of the style to set if a
 
         *                                  string, or an object of name =>
 
         *                                  value pairs
 
         * @param   {String}        value   The value to set the given style to
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        setStyle: function(el, style, value){
 
            if(typeof style == 'string'){
 
                var camel = toCamel(style);
 
                if(camel == 'opacity'){
 
                    setOpacity(el, value);
 
                }else{
 
                    el.style[camel] = value;
 
                }
 
            }else{
 
                for(var s in style){
 
                    this.setStyle(el, s, style[s]);
 
                }
 
            }
 
        },
 

	
 
        /**
 
         * Gets a reference to the given element.
 
         *
 
         * @param   {String/HTMLElement}    el      The element to fetch
 
         * @return  {HTMLElement}                   A reference to the element
 
         * @public
 
         * @static
 
         */
 
        get: function(el){
 
            return typeof el == 'string' ? document.getElementById(el) : el;
 
        },
 

	
 
        /**
 
         * Removes an element from the DOM.
 
         *
 
         * @param   {HTMLElement}       el      The element to remove
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        remove: function(el){
 
            el.parentNode.removeChild(el);
 
        },
 

	
 
        /**
 
         * Gets the target of the given event. The event object passed will be
 
         * the same object that is passed to listeners registered with
 
         * addEvent().
 
         *
 
         * @param   {mixed}             e       The event object
 
         * @return  {HTMLElement}               The event's target element
 
         * @public
 
         * @static
 
         */
 
        getTarget: function(e){
 
            var t = e.target ? e.target : e.srcElement;
 
            return t.nodeType == 3 ? t.parentNode : t;
 
        },
 

	
 
        /**
 
         * Gets the page X/Y coordinates of the mouse event in an [x, y] array.
 
         * The page coordinates should be relative to the document, and not the
 
         * viewport. The event object provided here will be the same object that
 
         * is passed to listeners registered with addEvent().
 
         *
 
         * @param   {mixed}         e       The event object
 
         * @return  {Array}                 The page X/Y coordinates
 
         * @public
 
         * @static
 
         */
 
        getPageXY: function(e){
 
            var x = e.pageX || (e.clientX +
 
                (document.documentElement.scrollLeft || document.body.scrollLeft));
 
            var y = e.pageY || (e.clientY +
 
                (document.documentElement.scrollTop || document.body.scrollTop));
 
            return [x, y];
 
        },
 

	
 
        /**
 
         * Prevents the event's default behavior. The event object here will
 
         * be the same object that is passed to listeners registered with
 
         * addEvent().
 
         *
 
         * @param   {mixed}             e       The event object
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        preventDefault: function(e){
 
            if(e.preventDefault){
 
                e.preventDefault();
 
            }else{
 
                e.returnValue = false;
 
            }
 
        },
 

	
 
        /**
 
         * Gets the key code of the given event object (keydown). The event
 
         * object here will be the same object that is passed to listeners
 
         * registered with addEvent().
 
         *
 
         * @param   {mixed}         e       The event object
 
         * @return  {Number}                The key code of the event
 
         * @public
 
         * @static
 
         */
 
        keyCode: function(e){
 
            return e.which ? e.which : e.keyCode;
 
        },
 

	
 
        /**
 
         * Adds an event listener to the given element. It is expected that this
 
         * function will be passed the event as its first argument.
 
         *
 
         * @param   {HTMLElement}   el          The DOM element to listen to
 
         * @param   {String}        name        The name of the event to register
 
         *                                      (i.e. 'click', 'scroll', etc.)
 
         * @param   {Function}      handler     The event handler function
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        addEvent: function(el, name, handler){
 
            if(el.addEventListener){
 
                el.addEventListener(name, handler, false);
 
            }else if(el.attachEvent){
 
                el.attachEvent('on' + name, handler);
 
            }
 
        },
 

	
 
        /**
 
         * Removes an event listener from the given element.
 
         *
 
         * @param   {HTMLElement}   el          The DOM element to stop listening to
 
         * @param   {String}        name        The name of the event to stop
 
         *                                      listening for (i.e. 'click')
 
         * @param   {Function}      handler     The event handler function
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        removeEvent: function(el, name, handler){
 
            if(el.removeEventListener){
 
                el.removeEventListener(name, handler, false);
 
            }else if(el.detachEvent){
 
                el.detachEvent('on' + name, handler);
 
            }
 
        },
 

	
 
        /**
 
         * Appends an HTML fragment to the given element.
 
         *
 
         * @param   {HTMLElement}       el      The element to append to
 
         * @param   {String}            html    The HTML fragment to use
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        append: function(el, html){
 
            if(el.insertAdjacentHTML){
 
                el.insertAdjacentHTML('BeforeEnd', html);
 
            }else if(el.lastChild){
 
                var range = el.ownerDocument.createRange();
 
                range.setStartAfter(el.lastChild);
 
                var frag = range.createContextualFragment(html);
 
                el.appendChild(frag);
 
            }else{
 
                el.innerHTML = html;
 
            }
 
        }
 

	
 
    };
 

	
 
}();
components/com_morfeoshow/src/adapter/shadowbox-dojo.js
Show inline comments
 
new file 100644
 
/**
 
 * An adapter for Shadowbox and the Dojo Toolkit.
 
 *
 
 * This file is part of Shadowbox.
 
 *
 
 * Shadowbox is an online media viewer application that supports all of the
 
 * web's most popular media publishing formats. Shadowbox is written entirely
 
 * in JavaScript and CSS and is highly customizable. Using Shadowbox, website
 
 * authors can showcase a wide assortment of media in all major browsers without
 
 * navigating users away from the linking page.
 
 *
 
 * Shadowbox is released under version 3.0 of the Creative Commons Attribution-
 
 * Noncommercial-Share Alike license. This means that it is absolutely free
 
 * for personal, noncommercial use provided that you 1) make attribution to the
 
 * author and 2) release any derivative work under the same or a similar
 
 * license.
 
 *
 
 * If you wish to use Shadowbox for commercial purposes, licensing information
 
 * can be found at http://mjijackson.com/shadowbox/.
 
 *
 
 * @author      Peter Higgins <dante@dojotoolkit.org>
 
 * @copyright   2008 Peter Higgins
 
 * @license     AFL/BSD
 
 * @version     SVN: $Id: shadowbox-dojo.js 103 2008-06-27 06:19:21Z mjijackson $
 
 */
 

	
 
if(typeof dojo == 'undefined'){
 
    throw 'Unable to load Shadowbox, Dojo Toolkit not found';
 
}
 

	
 
// create the Shadowbox object first
 
var Shadowbox = {};
 

	
 
Shadowbox.lib = function(){
 

	
 
    /**
 
     * Holds all registered event handlers.
 
     *
 
     * @property    {Array}     events
 
     * @private
 
     */
 
    var events = [];
 

	
 
    // local style camelizing for speed
 
    var styleCache = {};
 
    var camelRe = /(-[a-z])/gi;
 
    var camelFn = function(m, a){
 
        return a.charAt(1).toUpperCase();
 
    };
 
    var toCamel = function(style){
 
        var camel;
 
        if(!(camel = styleCache[style])){
 
            camel = styleCache[style] = style.replace(camelRe, camelFn);
 
        }
 
        return camel;
 
    };
 

	
 
    return {
 

	
 
        adapter: 'dojo',
 

	
 
        /**
 
         * Gets the value of the style on the given element.
 
         *
 
         * @param   {HTMLElement}   el      The DOM element
 
         * @param   {String}        style   The name of the style (e.g. margin-top)
 
         * @return  {mixed}                 The value of the given style
 
         * @public
 
         * @static
 
         */
 
        getStyle: function(el, style){
 
            return dojo.style(el, toCamel(style));
 
        },
 

	
 
        /**
 
         * Sets the style on the given element to the given value. May be an
 
         * object to specify multiple values.
 
         *
 
         * @param   {HTMLElement}   el      The DOM element
 
         * @param   {String/Object} style   The name of the style to set if a
 
         *                                  string, or an object of name =>
 
         *                                  value pairs
 
         * @param   {String}        value   The value to set the given style to
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        setStyle: function(el, style, value){
 
            if(typeof style == 'string'){
 
                dojo.style(el, toCamel(style), value);
 
            }else{
 
                for(var i in style){
 
                    dojo.style(el, i, style[i]);
 
                }
 
            }
 
        },
 

	
 
        /**
 
         * Gets a reference to the given element.
 
         *
 
         * @param   {String/HTMLElement}    el      The element to fetch
 
         * @return  {HTMLElement}                   A reference to the element
 
         * @public
 
         * @static
 
         */
 
        get: function(el){
 
            return dojo.byId(el);
 
        },
 

	
 
        /**
 
         * Removes an element from the DOM.
 
         *
 
         * @param   {HTMLElement}           el      The element to remove
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        remove: function(el){
 
            dojo._destroyElement(el);
 
        },
 

	
 
        /**
 
         * Gets the target of the given event. The event object passed will be
 
         * the same object that is passed to listeners registered with
 
         * addEvent().
 
         *
 
         * @param   {mixed}                 e       The event object
 
         * @return  {HTMLElement}                   The event's target element
 
         * @public
 
         * @static
 
         */
 
        getTarget: function(e){
 
            return e.target;
 
        },
 

	
 
        /**
 
         * Gets the client X/Y coordinates of the mouse event. The event object
 
         * provided here will be the same object that is passed to listeners
 
         * registered with addEvent(). The return array will contain the [x, y]
 
         * coordinates.
 
         *
 
         * @param   {mixed}         e       The event object
 
         * @return  {Array}                 The client X/Y coordinates
 
         * @public
 
         * @static
 
         */
 
        getPageXY: function(e){
 
            return [e.pageX, e.pageY];
 
        },
 

	
 
        /**
 
         * Prevents the event's default behavior. The event object passed will
 
         * be the same object that is passed to listeners registered with
 
         * addEvent().
 
         *
 
         * @param   {mixed}                 e       The event object
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        preventDefault: function(e){
 
            e.preventDefault();
 
        },
 

	
 
        /**
 
         * Gets the key code of the given event object (keydown). The event
 
         * object here will be the same object that is passed to listeners
 
         * registered with addEvent().
 
         *
 
         * @param   {mixed}         e       The event object
 
         * @return  {Number}                The key code of the event
 
         * @public
 
         * @static
 
         */
 
        keyCode: function(e){
 
            return e.keyCode;
 
        },
 

	
 
        /**
 
         * Adds an event listener to the given element. It is expected that this
 
         * function will be passed the event as its first argument.
 
         *
 
         * @param   {HTMLElement}   el          The DOM element to listen to
 
         * @param   {String}        name        The name of the event to register
 
         *                                      (i.e. 'click', 'scroll', etc.)
 
         * @param   {Function}      handler     The event handler function
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        addEvent: function(el, name, handler){
 
            var t = dojo.connect(el, name, handler);
 
            // we need to store a handle to later disconnect
 
            events.push({
 
                el: el,
 
                name: name,
 
                handle: t
 
            });
 
        },
 

	
 
        /**
 
         * Removes an event listener from the given element.
 
         *
 
         * @param   {HTMLElement}   el          The DOM element to stop listening to
 
         * @param   {String}        name        The name of the event to stop
 
         *                                      listening for (i.e. 'click')
 
         * @param   {Function}      handler     The event handler function
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        removeEvent: function(el, name, handler){
 
            // probably a quicker way to match this
 
            dojo.forEach(events, function(ev, idx){
 
                if(ev && ev.el == el && ev.name == name){
 
                    dojo.disconnect(ev.handle);
 
                    events[idx] = null;
 
                }
 
            });
 
        },
 

	
 
        /**
 
         * Appends an HTML fragment to the given element.
 
         *
 
         * @param   {HTMLElement}       el      The element to append to
 
         * @param   {String}            html    The HTML fragment to use
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        append: function(el, html){
 
            if(el.insertAdjacentHTML){
 
                el.insertAdjacentHTML('BeforeEnd', html);
 
            }else if(el.lastChild){
 
                var range = el.ownerDocument.createRange();
 
                range.setStartAfter(el.lastChild);
 
                var frag = range.createContextualFragment(html);
 
                el.appendChild(frag);
 
            }else{
 
                el.innerHTML = html;
 
            }
 
        }
 

	
 
    };
 

	
 
}();
components/com_morfeoshow/src/adapter/shadowbox-jquery.js
Show inline comments
 
new file 100644
 
/**
 
 * An adapter for Shadowbox and the jQuery JavaScript library.
 
 *
 
 * This file is part of Shadowbox.
 
 *
 
 * Shadowbox is an online media viewer application that supports all of the
 
 * web's most popular media publishing formats. Shadowbox is written entirely
 
 * in JavaScript and CSS and is highly customizable. Using Shadowbox, website
 
 * authors can showcase a wide assortment of media in all major browsers without
 
 * navigating users away from the linking page.
 
 *
 
 * Shadowbox is released under version 3.0 of the Creative Commons Attribution-
 
 * Noncommercial-Share Alike license. This means that it is absolutely free
 
 * for personal, noncommercial use provided that you 1) make attribution to the
 
 * author and 2) release any derivative work under the same or a similar
 
 * license.
 
 *
 
 * If you wish to use Shadowbox for commercial purposes, licensing information
 
 * can be found at http://mjijackson.com/shadowbox/.
 
 *
 
 * @author      Michael J. I. Jackson <mjijackson@gmail.com>
 
 * @copyright   2007-2008 Michael J. I. Jackson
 
 * @license     http://creativecommons.org/licenses/by-nc-sa/3.0/
 
 * @version     SVN: $Id: shadowbox-jquery.js 103 2008-06-27 06:19:21Z mjijackson $
 
 */
 

	
 
if(typeof jQuery == 'undefined'){
 
    throw 'Unable to load Shadowbox, jQuery library not found';
 
}
 

	
 
// create the Shadowbox object first
 
var Shadowbox = {};
 

	
 
Shadowbox.lib = {
 

	
 
    adapter: 'jquery',
 

	
 
    /**
 
     * Gets the value of the style on the given element.
 
     *
 
     * @param   {HTMLElement}   el      The DOM element
 
     * @param   {String}        style   The name of the style (e.g. margin-top)
 
     * @return  {mixed}                 The value of the given style
 
     * @public
 
     */
 
    getStyle: function(el, style){
 
        return jQuery(el).css(style);
 
    },
 

	
 
    /**
 
     * Sets the style on the given element to the given value. May be an
 
     * object to specify multiple values.
 
     *
 
     * @param   {HTMLElement}   el      The DOM element
 
     * @param   {String/Object} style   The name of the style to set if a
 
     *                                  string, or an object of name =>
 
     *                                  value pairs
 
     * @param   {String}        value   The value to set the given style to
 
     * @return  void
 
     * @public
 
     */
 
    setStyle: function(el, style, value){
 
        if(typeof style != 'object'){
 
            var temp = {};
 
            temp[style] = value;
 
            style = temp;
 
        }
 
        jQuery(el).css(style);
 
    },
 

	
 
    /**
 
     * Gets a reference to the given element.
 
     *
 
     * @param   {String/HTMLElement}    el      The element to fetch
 
     * @return  {HTMLElement}                   A reference to the element
 
     * @public
 
     */
 
    get: function(el){
 
        return (typeof el == 'string') ? document.getElementById(el) : el;
 
    },
 

	
 
    /**
 
     * Removes an element from the DOM.
 
     *
 
     * @param   {HTMLElement}           el      The element to remove
 
     * @return  void
 
     * @public
 
     */
 
    remove: function(el){
 
        jQuery(el).remove();
 
    },
 

	
 
    /**
 
     * Gets the target of the given event. The event object passed will be
 
     * the same object that is passed to listeners registered with
 
     * addEvent().
 
     *
 
     * @param   {mixed}                 e       The event object
 
     * @return  {HTMLElement}                   The event's target element
 
     * @public
 
     */
 
    getTarget: function(e){
 
        return e.target;
 
    },
 

	
 
    /**
 
     * Gets the page X/Y coordinates of the mouse event in an [x, y] array.
 
     * The page coordinates should be relative to the document, and not the
 
     * viewport. The event object provided here will be the same object that
 
     * is passed to listeners registered with addEvent().
 
     *
 
     * @param   {mixed}         e       The event object
 
     * @return  {Array}                 The page X/Y coordinates
 
     * @public
 
     * @static
 
     */
 
    getPageXY: function(e){
 
        return [e.pageX, e.pageY];
 
    },
 

	
 
    /**
 
     * Prevents the event's default behavior. The event object passed will
 
     * be the same object that is passed to listeners registered with
 
     * addEvent().
 
     *
 
     * @param   {mixed}                 e       The event object
 
     * @return  void
 
     * @public
 
     */
 
    preventDefault: function(e){
 
        e.preventDefault();
 
    },
 

	
 
    /**
 
     * Gets the key code of the given event object (keydown). The event
 
     * object here will be the same object that is passed to listeners
 
     * registered with addEvent().
 
     *
 
     * @param   {mixed}         e       The event object
 
     * @return  {Number}                The key code of the event
 
     * @public
 
     * @static
 
     */
 
    keyCode: function(e){
 
        return e.keyCode;
 
    },
 

	
 
    /**
 
     * Adds an event listener to the given element. It is expected that this
 
     * function will be passed the event as its first argument.
 
     *
 
     * @param   {HTMLElement}   el          The DOM element to listen to
 
     * @param   {String}        name        The name of the event to register
 
     *                                      (i.e. 'click', 'scroll', etc.)
 
     * @param   {Function}      handler     The event handler function
 
     * @return  void
 
     * @public
 
     */
 
    addEvent: function(el, name, handler){
 
        jQuery(el).bind(name, handler);
 
    },
 

	
 
    /**
 
     * Removes an event listener from the given element.
 
     *
 
     * @param   {HTMLElement}   el          The DOM element to stop listening to
 
     * @param   {String}        name        The name of the event to stop
 
     *                                      listening for (i.e. 'click')
 
     * @param   {Function}      handler     The event handler function
 
     * @return  void
 
     * @public
 
     */
 
    removeEvent: function(el, name, handler){
 
        jQuery(el).unbind(name, handler);
 
    },
 

	
 
    /**
 
     * Appends an HTML fragment to the given element.
 
     *
 
     * @param   {HTMLElement}       el      The element to append to
 
     * @param   {String}            html    The HTML fragment to use
 
     * @return  void
 
     * @public
 
     */
 
    append: function(el, html){
 
        jQuery(el).append(html);
 
    }
 

	
 
};
 

	
 
/**
 
 * Passes the selected elements to the Shadowbox.setup() function. Supports
 
 * embedded height and width attributes within the class attribute.
 
 *
 
 * @param   {Object}    options     The options to pass to setup() for all
 
 *                                  selected elements
 
 * @public
 
 * @author  Mike Alsup
 
 * @author  Roger Barrett
 
 */
 
(function($){
 
$.fn.shadowbox = function(options){
 
    return this.each(function(){
 
        var $this = $(this);
 
        // support jQuery metadata plugin
 
        var opts = $.extend({}, options || {}, $.metadata ? $this.metadata() : $.meta ? $this.data() : {});
 
        // support embedded opts (for w/h) within the class attr
 
        var cls = this.className || '';
 
        opts.width  = parseInt((cls.match(/w:(\d+)/)||[])[1]) || opts.width;
 
        opts.height = parseInt((cls.match(/h:(\d+)/)||[])[1]) || opts.height;
 
        Shadowbox.setup($this, opts);
 
    });
 
};
 
})(jQuery);
components/com_morfeoshow/src/adapter/shadowbox-mootools.js
Show inline comments
 
new file 100644
 
/**
 
 * An adapter for Shadowbox and the MooTools JavaScript framework.
 
 *
 
 * This file is part of Shadowbox.
 
 *
 
 * Shadowbox is an online media viewer application that supports all of the
 
 * web's most popular media publishing formats. Shadowbox is written entirely
 
 * in JavaScript and CSS and is highly customizable. Using Shadowbox, website
 
 * authors can showcase a wide assortment of media in all major browsers without
 
 * navigating users away from the linking page.
 
 *
 
 * Shadowbox is released under version 3.0 of the Creative Commons Attribution-
 
 * Noncommercial-Share Alike license. This means that it is absolutely free
 
 * for personal, noncommercial use provided that you 1) make attribution to the
 
 * author and 2) release any derivative work under the same or a similar
 
 * license.
 
 *
 
 * If you wish to use Shadowbox for commercial purposes, licensing information
 
 * can be found at http://mjijackson.com/shadowbox/.
 
 *
 
 * @author      Michael J. I. Jackson <mjijackson@gmail.com>
 
 * @copyright   2007-2008 Michael J. I. Jackson
 
 * @license     http://creativecommons.org/licenses/by-nc-sa/3.0/
 
 * @version     SVN: $Id: shadowbox-mootools.js 110 2008-07-11 04:42:10Z mjijackson $
 
 */
 

	
 
if(typeof MooTools == 'undefined'){
 
    // Note: requires MooTools 1.2 Core
 
    throw 'Unable to load Shadowbox, MooTools library not found';
 
}
 

	
 
// create the Shadowbox object first
 
var Shadowbox = {};
 

	
 
Shadowbox.lib = function(){
 

	
 
    var alphaRe = /alpha\([^\)]*\)/gi;
 

	
 
    /**
 
     * Sets the opacity of the given element to the specified level. Necessary
 
     * in the MooTools adapter to prevent MooTools from messing with the
 
     * element's visibility.
 
     *
 
     * @param   {HTMLElement}   el          The element
 
     * @param   {Number}        opacity     The opacity to use
 
     * @return  void
 
     * @private
 
     * @static
 
     */
 
    var setOpacity = function(el, opacity){
 
        var s = el.style;
 
        if(window.ActiveXObject){ // IE
 
            s.zoom = 1;
 
            s.filter = (s.filter || '').replace(alphaRe, '') +
 
                       (opacity == 1 ? '' : ' alpha(opacity=' + opacity * 100 + ')');
 
        }else{
 
            s.opacity = opacity;
 
        }
 
    };
 

	
 
    return {
 

	
 
        adapter: 'mootools',
 

	
 
        /**
 
         * Gets the value of the style on the given element.
 
         *
 
         * @param   {HTMLElement}   el      The DOM element
 
         * @param   {String}        style   The name of the style (e.g. margin-top)
 
         * @return  {mixed}                 The value of the given style
 
         * @public
 
         * @static
 
         */
 
        getStyle: function(el, style){
 
            return $(el).getStyle(style);
 
        },
 

	
 
        /**
 
         * Sets the style on the given element to the given value. May be an
 
         * object to specify multiple values.
 
         *
 
         * @param   {HTMLElement}   el      The DOM element
 
         * @param   {String/Object} style   The name of the style to set if a
 
         *                                  string, or an object of name =>
 
         *                                  value pairs
 
         * @param   {String}        value   The value to set the given style to
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        setStyle: function(el, style, value){
 
            el = $(el);
 
            if(typeof style != 'object'){
 
                var o = {};
 
                o[style] = value;
 
                style = o;
 
            }
 
            for(var s in style){
 
                if(s == 'opacity'){
 
                    setOpacity(el, style[s]);
 
                }else{
 
                    el.setStyle(s, style[s]);
 
                }
 
            }
 
        },
 

	
 
        /**
 
         * Gets a reference to the given element.
 
         *
 
         * @param   {String/HTMLElement}    el      The element to fetch
 
         * @return  {HTMLElement}                   A reference to the element
 
         * @public
 
         * @static
 
         */
 
        get: function(el){
 
            return $(el);
 
        },
 

	
 
        /**
 
         * Removes an element from the DOM.
 
         *
 
         * @param   {HTMLElement}           el      The element to remove
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        remove: function(el){
 
            el.parentNode.removeChild(el);
 
        },
 

	
 
        /**
 
         * Gets the target of the given event. The event object passed will be
 
         * the same object that is passed to listeners registered with
 
         * addEvent().
 
         *
 
         * @param   {mixed}         e       The event object
 
         * @return  {HTMLElement}           The event's target element
 
         * @public
 
         * @static
 
         */
 
        getTarget: function(e){
 
            return e.target;
 
        },
 

	
 
        /**
 
         * Gets the page X/Y coordinates of the mouse event in an [x, y] array.
 
         * The page coordinates should be relative to the document, and not the
 
         * viewport. The event object provided here will be the same object that
 
         * is passed to listeners registered with addEvent().
 
         *
 
         * @param   {mixed}         e       The event object
 
         * @return  {Array}                 The page X/Y coordinates
 
         * @public
 
         * @static
 
         */
 
        getPageXY: function(e){
 
            return [e.page.x, e.page.y];
 
        },
 

	
 
        /**
 
         * Prevents the event's default behavior. The event object passed will
 
         * be the same object that is passed to listeners registered with
 
         * addEvent().
 
         *
 
         * @param   {mixed}         e       The event object
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        preventDefault: function(e){
 
            e.preventDefault();
 
        },
 

	
 
        /**
 
         * Gets the key code of the given event object (keydown). The event
 
         * object here will be the same object that is passed to listeners
 
         * registered with addEvent().
 
         *
 
         * @param   {mixed}         e       The event object
 
         * @return  {Number}                The key code of the event
 
         * @public
 
         * @static
 
         */
 
        keyCode: function(e){
 
            return e.code;
 
        },
 

	
 
        /**
 
         * Adds an event listener to the given element. It is expected that this
 
         * function will be passed the event as its first argument.
 
         *
 
         * @param   {HTMLElement}   el          The DOM element to listen to
 
         * @param   {String}        name        The name of the event to register
 
         *                                      (i.e. 'click', 'scroll', etc.)
 
         * @param   {Function}      handler     The event handler function
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        addEvent: function(el, name, handler){
 
            $(el).addEvent(name, handler);
 
        },
 

	
 
        /**
 
         * Removes an event listener from the given element.
 
         *
 
         * @param   {HTMLElement}   el          The DOM element to stop listening to
 
         * @param   {String}        name        The name of the event to stop
 
         *                                      listening for (i.e. 'click')
 
         * @param   {Function}      handler     The event handler function
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        removeEvent: function(el, name, handler){
 
            $(el).removeEvent(name, handler);
 
        },
 

	
 
        /**
 
         * Appends an HTML fragment to the given element.
 
         *
 
         * @param   {HTMLElement}       el      The element to append to
 
         * @param   {String}            html    The HTML fragment to use
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        append: function(el, html){
 
            if(el.insertAdjacentHTML){
 
                el.insertAdjacentHTML('BeforeEnd', html);
 
            }else if(el.lastChild){
 
                var range = el.ownerDocument.createRange();
 
                range.setStartAfter(el.lastChild);
 
                var frag = range.createContextualFragment(html);
 
                el.appendChild(frag);
 
            }else{
 
                el.innerHTML = html;
 
            }
 
        }
 

	
 
    };
 

	
 
}();
components/com_morfeoshow/src/adapter/shadowbox-prototype.js
Show inline comments
 
new file 100644
 
/**
 
 * An adapter for Shadowbox and the Prototpe JavaScript library.
 
 *
 
 * This file is part of Shadowbox.
 
 *
 
 * Shadowbox is an online media viewer application that supports all of the
 
 * web's most popular media publishing formats. Shadowbox is written entirely
 
 * in JavaScript and CSS and is highly customizable. Using Shadowbox, website
 
 * authors can showcase a wide assortment of media in all major browsers without
 
 * navigating users away from the linking page.
 
 *
 
 * Shadowbox is released under version 3.0 of the Creative Commons Attribution-
 
 * Noncommercial-Share Alike license. This means that it is absolutely free
 
 * for personal, noncommercial use provided that you 1) make attribution to the
 
 * author and 2) release any derivative work under the same or a similar
 
 * license.
 
 *
 
 * If you wish to use Shadowbox for commercial purposes, licensing information
 
 * can be found at http://mjijackson.com/shadowbox/.
 
 *
 
 * @author      Michael J. I. Jackson <mjijackson@gmail.com>
 
 * @copyright   2007-2008 Michael J. I. Jackson
 
 * @license     http://creativecommons.org/licenses/by-nc-sa/3.0/
 
 * @version     SVN: $Id: shadowbox-prototype.js 103 2008-06-27 06:19:21Z mjijackson $
 
 */
 

	
 
if(typeof Prototype == 'undefined'){
 
    throw 'Unable to load Shadowbox, Prototype framework not found';
 
}
 

	
 
// create the Shadowbox object first
 
var Shadowbox = {};
 

	
 
Shadowbox.lib = function(){
 

	
 
    // local style camelizing for speed
 
    var styleCache = {};
 
    var camelRe = /(-[a-z])/gi;
 
    var camelFn = function(m, a){
 
        return a.charAt(1).toUpperCase();
 
    };
 
    var toCamel = function(style){
 
        var camel;
 
        if(!(camel = styleCache[style])){
 
            camel = styleCache[style] = style.replace(camelRe, camelFn);
 
        }
 
        return camel;
 
    };
 

	
 
    return {
 

	
 
        adapter: 'prototype',
 

	
 
        /**
 
         * Gets the value of the style on the given element.
 
         *
 
         * @param   {HTMLElement}   el      The DOM element
 
         * @param   {String}        style   The name of the style (e.g. margin-top)
 
         * @return  {mixed}                 The value of the given style
 
         * @public
 
         */
 
        getStyle: function(el, style){
 
            return Element.getStyle(el, style);
 
        },
 

	
 
        /**
 
         * Sets the style on the given element to the given value. May be an
 
         * object to specify multiple values.
 
         *
 
         * @param   {HTMLElement}   el      The DOM element
 
         * @param   {String/Object} style   The name of the style to set if a
 
         *                                  string, or an object of name =>
 
         *                                  value pairs
 
         * @param   {String}        value   The value to set the given style to
 
         * @return  void
 
         * @public
 
         */
 
        setStyle: function(el, style, value){
 
            if(typeof style == 'string'){
 
                var temp = {};
 
                temp[toCamel(style)] = value;
 
                style = temp;
 
            }
 
            Element.setStyle(el, style);
 
        },
 

	
 
        /**
 
         * Gets a reference to the given element.
 
         *
 
         * @param   {String/HTMLElement}    el      The element to fetch
 
         * @return  {HTMLElement}                   A reference to the element
 
         * @public
 
         */
 
        get: function(el){
 
            return $(el);
 
        },
 

	
 
        /**
 
         * Removes an element from the DOM.
 
         *
 
         * @param   {HTMLElement}           el      The element to remove
 
         * @return  void
 
         * @public
 
         */
 
        remove: function(el){
 
            Element.remove(el);
 
        },
 

	
 
        /**
 
         * Gets the target of the given event. The event object passed will be
 
         * the same object that is passed to listeners registered with
 
         * addEvent().
 
         *
 
         * @param   {mixed}                 e       The event object
 
         * @return  {HTMLElement}                   The event's target element
 
         * @public
 
         */
 
        getTarget: function(e){
 
            return Event.element(e);
 
        },
 

	
 
        /**
 
         * Prevents the event's default behavior. The event object passed will
 
         * be the same object that is passed to listeners registered with
 
         * addEvent().
 
         *
 
         * @param   {mixed}                 e       The event object
 
         * @return  void
 
         * @public
 
         */
 
        preventDefault: function(e){
 
            Event.stop(e);
 
        },
 

	
 
        /**
 
         * Gets the page X/Y coordinates of the mouse event in an [x, y] array.
 
         * The page coordinates should be relative to the document, and not the
 
         * viewport. The event object provided here will be the same object that
 
         * is passed to listeners registered with addEvent().
 
         *
 
         * @param   {mixed}         e       The event object
 
         * @return  {Array}                 The page X/Y coordinates
 
         * @public
 
         * @static
 
         */
 
        getPageXY: function(e){
 
            var p = Event.pointer(e);
 
            return [p.x, p.y];
 
        },
 

	
 
        /**
 
         * Gets the key code of the given event object (keydown). The event
 
         * object here will be the same object that is passed to listeners
 
         * registered with addEvent().
 
         *
 
         * @param   {mixed}         e       The event object
 
         * @return  {Number}                The key code of the event
 
         * @public
 
         * @static
 
         */
 
        keyCode: function(e){
 
            return e.keyCode;
 
        },
 

	
 
        /**
 
         * Adds an event listener to the given element. It is expected that this
 
         * function will be passed the event as its first argument.
 
         *
 
         * @param   {HTMLElement}   el          The DOM element to listen to
 
         * @param   {String}        name        The name of the event to register
 
         *                                      (i.e. 'click', 'scroll', etc.)
 
         * @param   {Function}      handler     The event handler function
 
         * @return  void
 
         * @public
 
         */
 
        addEvent: function(el, name, handler){
 
            Event.observe(el, name, handler);
 
        },
 

	
 
        /**
 
         * Removes an event listener from the given element.
 
         *
 
         * @param   {HTMLElement}   el          The DOM element to stop listening to
 
         * @param   {String}        name        The name of the event to stop
 
         *                                      listening for (i.e. 'click')
 
         * @param   {Function}      handler     The event handler function
 
         * @return  void
 
         * @public
 
         */
 
        removeEvent: function(el, name, handler){
 
            Event.stopObserving(el, name, handler);
 
        },
 

	
 
        /**
 
         * Appends an HTML fragment to the given element.
 
         *
 
         * @param   {HTMLElement}       el      The element to append to
 
         * @param   {String}            html    The HTML fragment to use
 
         * @return  void
 
         * @public
 
         */
 
        append: function(el, html){
 
            Element.insert(el, html);
 
        }
 

	
 
    };
 

	
 
}();
components/com_morfeoshow/src/adapter/shadowbox-yui.js
Show inline comments
 
new file 100644
 
/**
 
 * An adapter for Shadowbox and the Yahoo! User Interface (YUI) library.
 
 *
 
 * This file is part of Shadowbox.
 
 *
 
 * Shadowbox is an online media viewer application that supports all of the
 
 * web's most popular media publishing formats. Shadowbox is written entirely
 
 * in JavaScript and CSS and is highly customizable. Using Shadowbox, website
 
 * authors can showcase a wide assortment of media in all major browsers without
 
 * navigating users away from the linking page.
 
 *
 
 * Shadowbox is released under version 3.0 of the Creative Commons Attribution-
 
 * Noncommercial-Share Alike license. This means that it is absolutely free
 
 * for personal, noncommercial use provided that you 1) make attribution to the
 
 * author and 2) release any derivative work under the same or a similar
 
 * license.
 
 *
 
 * If you wish to use Shadowbox for commercial purposes, licensing information
 
 * can be found at http://mjijackson.com/shadowbox/.
 
 *
 
 * @author      Michael J. I. Jackson <mjijackson@gmail.com>
 
 * @copyright   2007-2008 Michael J. I. Jackson
 
 * @license     http://creativecommons.org/licenses/by-nc-sa/3.0/
 
 * @version     SVN: $Id: shadowbox-yui.js 103 2008-06-27 06:19:21Z mjijackson $
 
 */
 

	
 
if(typeof YAHOO == 'undefined'){
 
    // Note: requires yahoo-dom-event.js
 
    throw 'Unable to load Shadowbox, core YUI utilities (yahoo, dom, event) not found';
 
}
 

	
 
// create the Shadowbox object first
 
var Shadowbox = {};
 

	
 
Shadowbox.lib = function(){
 

	
 
    // shorthand
 
    var E = YAHOO.util.Event;
 
    var D = YAHOO.util.Dom;
 

	
 
    return {
 

	
 
        adapter: 'yui',
 

	
 
        /**
 
         * Gets the value of the style on the given element.
 
         *
 
         * @param   {HTMLElement}   el      The DOM element
 
         * @param   {String}        style   The name of the style (e.g. margin-top)
 
         * @return  {mixed}                 The value of the given style
 
         * @public
 
         * @static
 
         */
 
        getStyle: function(el, style){
 
            return D.getStyle(el, style);
 
        },
 

	
 
        /**
 
         * Sets the style on the given element to the given value. May be an
 
         * object to specify multiple values.
 
         *
 
         * @param   {HTMLElement}   el      The DOM element
 
         * @param   {String/Object} style   The name of the style to set if a
 
         *                                  string, or an object of name =>
 
         *                                  value pairs
 
         * @param   {String}        value   The value to set the given style to
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        setStyle: function(el, style, value){
 
            if(typeof style != 'object'){
 
                var temp = {};
 
                temp[style] = value;
 
                style = temp;
 
            }
 
            for(var s in style){
 
                D.setStyle(el, s, style[s]);
 
            }
 
        },
 

	
 
        /**
 
         * Gets a reference to the given element.
 
         *
 
         * @param   {String/HTMLElement}    el      The element to fetch
 
         * @return  {HTMLElement}                   A reference to the element
 
         * @public
 
         * @static
 
         */
 
        get: function(el){
 
            return D.get(el);
 
        },
 

	
 
        /**
 
         * Removes an element from the DOM.
 
         *
 
         * @param   {HTMLElement}           el      The element to remove
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        remove: function(el){
 
            el.parentNode.removeChild(el);
 
        },
 

	
 
        /**
 
         * Gets the target of the given event. The event object passed will be
 
         * the same object that is passed to listeners registered with
 
         * addEvent().
 
         *
 
         * @param   {mixed}                 e       The event object
 
         * @return  {HTMLElement}                   The event's target element
 
         * @public
 
         * @static
 
         */
 
        getTarget: function(e){
 
            return E.getTarget(e);
 
        },
 

	
 
        /**
 
         * Gets the page X/Y coordinates of the mouse event in an [x, y] array.
 
         * The page coordinates should be relative to the document, and not the
 
         * viewport. The event object provided here will be the same object that
 
         * is passed to listeners registered with addEvent().
 
         *
 
         * @param   {mixed}         e       The event object
 
         * @return  {Array}                 The page X/Y coordinates
 
         * @public
 
         * @static
 
         */
 
        getPageXY: function(e){
 
            return [E.getPageX(e), E.getPageY(e)];
 
        },
 

	
 
        /**
 
         * Prevents the event's default behavior. The event object passed will
 
         * be the same object that is passed to listeners registered with
 
         * addEvent().
 
         *
 
         * @param   {mixed}                 e       The event object
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        preventDefault: function(e){
 
            E.preventDefault(e);
 
        },
 

	
 
        /**
 
         * Gets the key code of the given event object (keydown). The event
 
         * object here will be the same object that is passed to listeners
 
         * registered with addEvent().
 
         *
 
         * @param   {mixed}         e       The event object
 
         * @return  {Number}                The key code of the event
 
         * @public
 
         * @static
 
         */
 
        keyCode: function(e){
 
            return e.keyCode;
 
        },
 

	
 
        /**
 
         * Adds an event listener to the given element. It is expected that this
 
         * function will be passed the event as its first argument.
 
         *
 
         * @param   {HTMLElement}   el          The DOM element to listen to
 
         * @param   {String}        name        The name of the event to register
 
         *                                      (i.e. 'click', 'scroll', etc.)
 
         * @param   {Function}      handler     The event handler function
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        addEvent: function(el, name, handler){
 
            E.addListener(el, name, handler);
 
        },
 

	
 
        /**
 
         * Removes an event listener from the given element.
 
         *
 
         * @param   {HTMLElement}   el          The DOM element to stop listening to
 
         * @param   {String}        name        The name of the event to stop
 
         *                                      listening for (i.e. 'click')
 
         * @param   {Function}      handler     The event handler function
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        removeEvent: function(el, name, handler){
 
            E.removeListener(el, name, handler);
 
        },
 

	
 
        /**
 
         * Appends an HTML fragment to the given element.
 
         *
 
         * @param   {HTMLElement}       el      The element to append to
 
         * @param   {String}            html    The HTML fragment to use
 
         * @return  void
 
         * @public
 
         * @static
 
         */
 
        append: function(el, html){
 
            if(el.insertAdjacentHTML){
 
                el.insertAdjacentHTML('BeforeEnd', html);
 
            }else if(el.lastChild){
 
                var range = el.ownerDocument.createRange();
 
                range.setStartAfter(el.lastChild);
 
                var frag = range.createContextualFragment(html);
 
                el.appendChild(frag);
 
            }else{
 
                el.innerHTML = html;
 
            }
 
        }
 

	
 
    };
 

	
 
}();
components/com_morfeoshow/src/imagerotator.swf
Show inline comments
 
new file 100644
 
binary diff not shown
components/com_morfeoshow/src/index.html
Show inline comments
 
new file 100644
 
<html>
 
<body bgcolor="#FFFFFF">
 
</body>
 
</html>
 
\ No newline at end of file
components/com_morfeoshow/src/js/css/index.html
Show inline comments
 
new file 100644
 
<html>
 
<body bgcolor="#FFFFFF">
 
</body>
 
</html>
 
\ No newline at end of file
components/com_morfeoshow/src/js/css/pic.css
Show inline comments
 
new file 100644
 
#maintable{
 
	border: 1px solid #CCCCCC;
 
}
 
 
 
#headerpic{}
 
 
#maincontent
 
{
 
	margin: 0;
 
	padding: 20px;
 
}
 
 
#piccontainer
 
{
 
}
 
 
h1, h2, h3, h4, h5, h6{
 
 
}
 
 
h1{	font-size: 20px;
 
font-weight: bold;
 
}
 
h2{	font-size: 18px;}
 
h3{	font-size: 16px;}
 
h4{	font-size: 14px;}
 
h5{	font-size: 12px;}
 
h6{	font-size: 10px;}
 
 
blockquote {
 
	font-style: italic;
 
	font-size: 100%;
 
	line-height: 150%;
 
	width: auto;
 
	padding: 0px 0px 5px 30px;
 
	margin: 15px 0;
 
}
 
 
 
img{}
 
 
img.pwimages{
 
	border: solid 2px #ccc;
 
	margin: 3px;
 
}
 
 
.standard   {
 
}
 
 
.pwalbums{
 
	border: 1px solid #ccc;
 
}
 
 
#img_float_left
 
{
 
	/* Used in the [img] tag when float=left */
 
	float: left;
 
	margin: 2px 8px 4px 2px;
 
}
 
 
#img_float_right
 
{
 
	/* Used in the [img] tag when float=right */
 
	float: right;
 
	margin: 2px 2px 4px 8px;
 
}
 
 
#footerpic{clear: both;}
 
 
.divider { margin: 20px 0px 15px 0px; }
 
\ No newline at end of file

Changeset was too big and was cut off... Show full diff anyway

0 comments (0 inline, 0 general)