Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1] 2 3 4

Author Topic: [Mod]Integrating ZenPhoto in sNews 1.6 WIP  (Read 25246 times)

centered

  • Guest
[Mod]Integrating ZenPhoto in sNews 1.6 WIP
« on: August 23, 2007, 10:53:18 PM »

This MOD is too add ZenPhoto functions in sNews

This is for sNews 1.6 with fixes from this thread: http://snewscms.com/forum/index.php?topic=2854.0

0. Backup or start fresh (recommended!!! I will do this on a fresh install)

1. Install sNews normally
2. Add a gallery folder and install ZenPhoto normally (http://www.zenphoto.org/files/zenphoto-1.0.8.2.zip)
3. In sNews index replace the first line:
Code: [Select]
<?php session_start(); include('snews.php'); ?>
With
Code: [Select]
<?php session_start(); include('snews.php'); define('WEBPATH''gallery'); require_once("gallery/zen/template-functions.php"); ?>
4.  In snews.php:
(Thank Patric for this)
Find these occurances inside the snews.php:
Quote
1. .strip($title).
2. .strip($text).
3. function strip($text)
And change them into eg:
Quote
1. .snews_strip($title).
2. .snews_strip($text).
3. function snews_strip($text)
5. In the themes folder of ZenPhoto, make a duplicate copy of the default theme and name it snews
6.  In themes/snews, Change index.php to this: (referencing the default sNews 1.6 template)
Code: [Select]
<? session_start();
include ('../snews.php'); ?>
<?php if (!defined('WEBPATH')) die(); ?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">

<head>

<?php title(); ?>

<meta name="Robots" content="index,follow" />

<meta name="Generator" content="sNews 1.6" />

<style type='text/css' title='currentStyle' media='screen'>
@import 'style.css';
</style>
<link rel="stylesheet" href="<?php echo  $_zp_themeroot ?>/zen.css" type="text/css" />
<?php zenJavascript(); ?>
<link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="rss-articles/" />

<link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="rss-pages/" />

<link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="rss-comments/" />

</head>

<body>

<div class="wrap">

<div id="logo">

<h1><?php echo s('website_title'); ?></h1>

</div>



<ul id="menu">

<?php pages(); ?>

</ul>



<div id="subheader">

<div id="breadcrumbs">

<?php breadcrumbs(); ?>

</div>



<div id="search">

<?php searchform(); ?>

</div>

</div>



<div id="left">

<h3>Categories:</h3>

<ul>

<?php categories(); ?>

</ul>



<h3>New Articles:</h3>

<ul>

<?php menu_articles(0,3); ?>

</ul>



<h3>New comments:</h3>

<ul>

<?php new_comments(530); ?>

</ul>

<h3>New images:</h3>
<ul>
<?php show_latest_images(4); ?>

<ul>

<h3>Random image:</h3>
<?php $randomImage getRandomImages(); $randomImageURL getURL($randomImage); print "<a href='".getURL($randomImage)."' title='Random Picture...'><img src='".$randomImage->getCustomImage(85620180620180300300)."' alt='".$randomImage->getTitle()."' /></a>"?>


<?php extra(); ?>

</div>



<div id="right">

<div id="gallerytitle">

<h2><?php echo getGalleryTitle(); ?></h2>

</div>



<div id="albums">

<?php while (next_album()): ?>

<div class="album">

<a href="<?php echo getAlbumLinkURL();?>" title="View album: <?php echo getAlbumTitle();?>">

<?php printAlbumThumbImage(getAlbumTitle()); ?>

</a>

<div class="albumdesc">

        <small><?php printAlbumDate("Date Taken: "); ?></small>

<h3><a href="<?php echo getAlbumLinkURL();?>" title="View album: <?php echo getAlbumTitle();?>">
<?php printAlbumTitle(); ?></a>
</h3>

<p><?php printAlbumDesc(); ?></p>

</div>

<p style="clear: both; "></p>

</div>

<?php endwhile; ?>

</div>



<?php printPageListWithNav("&laquo; prev""next &raquo;"); ?>



<div id="enableSorting">

  <?php printSortableGalleryLink('Click to sort gallery''Manual sorting'NULL'credit'); ?>

  </div>

</div>



<div id="footer">

<ul id="rss">

<?php rss_links(); ?>

</ul>

<p>Barbecued by <a href="http://snews.solucija.com/" title="Single file CMS">sNews</a>
&middot; <?php login_link(); ?></p>

</div>

</div>

</body>

</html>
7. In themes/snews, Change album.php to this: (again, referencing the default sNews 1.6 template)
Code: [Select]
<? session_start();
include ('../snews.php'); ?>
<?php if (!defined('WEBPATH')) die(); ?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">

<head>

<?php title(); ?>

<meta name="Robots" content="index,follow" />

<meta name="Generator" content="sNews 1.6" />

<style type='text/css' title='currentStyle' media='screen'>
@import 'style.css';
</style>
<link rel="stylesheet" href="<?php echo  $_zp_themeroot ?>/zen.css" type="text/css" />
<?php zenJavascript(); ?>
<link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="rss-articles/" />

<link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="rss-pages/" />

<link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="rss-comments/" />

</head>

<body>

<div class="wrap">

<div id="logo">

<h1><?php echo s('website_title'); ?></h1>

</div>



<ul id="menu">

<?php pages(); ?>

</ul>



<div id="subheader">

<div id="breadcrumbs">

<?php breadcrumbs(); ?>

</div>



<div id="search">

<?php searchform(); ?>

</div>

</div>



<div id="left">

<h3>Categories:</h3>

<ul>

<?php categories(); ?>

</ul>



<h3>New Articles:</h3>

<ul>

<?php menu_articles(0,3); ?>

</ul>



<h3>New comments:</h3>

<ul>

<?php new_comments(530); ?>

</ul>

<h3>New images:</h3>
<ul>
<?php show_latest_images(4); ?>

<ul>

<h3>Random image:</h3>
<?php $randomImage getRandomImages(); $randomImageURL getURL($randomImage); print "<a href='".getURL($randomImage)."' title='Random Picture...'><img src='".$randomImage->getCustomImage(85620180620180300300)."' alt='".$randomImage->getTitle()."' /></a>"?>



<?php extra(); ?>

</div>



<div id="right">

<div id="gallerytitle">

<h2><span><a href="<?php echo getGalleryIndexURL();?>" title="Gallery Index">
<?php echo getGalleryTitle();?></a> | </span> <?php printAlbumTitle(true);?></h2>

</div>

<?php printAlbumDesc(true); ?>

<div id="images">

<?php while (next_image()): ?>

<div class="image">

<div class="imagethumb">
<a href="<?php echo getImageLinkURL();?>" title="<?php echo getImageTitle();?>">
<?php printImageThumb(getImageTitle()); ?></a>
</div>

</div>

<?php endwhile; ?>

</div>

<?php printPageListWithNav("&laquo; prev""next &raquo;"); ?>

<div id="enableSorting">

  <?php printSortableAlbumLink('Click to sort album''Manual sorting'NULL'sort'); ?>

  </div>
</div>
<div id="footer">

<ul id="rss">

<?php rss_links(); ?>

</ul>

<p>Barbecued by <a href="http://snews.solucija.com/" title="Single file CMS">sNews</a>
&middot; <?php login_link(); ?></p>

</div>

</div>

</body>

</html>

8.  In themes/snews, Change image.php to this: (Again, referencing the default sNews 1.6 template)
Code: [Select]
<? session_start();
include ('../snews.php'); ?>
<?php if (!defined('WEBPATH')) die(); ?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">

<head>

<?php title(); ?>

<meta name="Robots" content="index,follow" />

<meta name="Generator" content="sNews 1.6" />

<style type='text/css' title='currentStyle' media='screen'>
@import 'style.css';
</style>
<link rel="stylesheet" href="<?php echo  $_zp_themeroot ?>/zen.css" type="text/css" />
<script type="text/javascript">

function toggleComments() {

      var commentDiv = document.getElementById("comments");

      if (commentDiv.style.display == "block") {

        commentDiv.style.display = "none";

      } else {

        commentDiv.style.display = "block";

      }

}

</script>

<?php zenJavascript(); ?>
<link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="rss-articles/" />

<link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="rss-pages/" />

<link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="rss-comments/" />

</head>

<body>

<div class="wrap">

<div id="logo">

<h1><?php echo s('website_title'); ?></h1>

</div>



<ul id="menu">

<?php pages(); ?>

</ul>



<div id="subheader">

<div id="breadcrumbs">

<?php breadcrumbs(); ?>

</div>



<div id="search">

<?php searchform(); ?>

</div>

</div>



<div id="left">

<h3>Categories:</h3>

<ul>

<?php categories(); ?>

</ul>



<h3>New Articles:</h3>

<ul>

<?php menu_articles(0,3); ?>

</ul>



<h3>New comments:</h3>

<ul>

<?php new_comments(530); ?>

</ul>

<h3>New images:</h3>
<ul>
<?php show_latest_images(4); ?>

<ul>

<h3>Random image:</h3>
<?php $randomImage getRandomImages(); $randomImageURL getURL($randomImage); print "<a href='".getURL($randomImage)."' title='Random Picture...'><img src='".$randomImage->getCustomImage(85620180620180300300)."' alt='".$randomImage->getTitle()."' /></a>"?>



<?php extra(); ?>

</div>



<div id="right">

<div class="imgnav">

<?php if (hasPrevImage()) { ?>

<div class="imgprevious">
<a href="<?php echo getPrevImageURL();?>" title="Previous Image">
&laquo; prev</a>
</div>

<?php } if (hasNextImage()) { ?>

<div class="imgnext">
<a href="<?php echo getNextImageURL();?>" title="Next Image">
next &raquo;</a>
</div>

<?php ?>

</div>



<div id="gallerytitle">

<h2><span><a href="<?php echo getGalleryIndexURL();?>" title="Gallery Index">
<?php echo getGalleryTitle();?></a>
| <a href="<?php echo getAlbumLinkURL();?>" title="Gallery Index">
<?php echo getAlbumTitle();?></a>
| </span> <?php printImageTitle(true); ?></h2>

</div>



<div id="image">

<a href="<?php echo getFullImageURL();?>" title="<?php echo getImageTitle();?>">
<?php printDefaultSizedImage(getImageTitle()); ?></a>

</div>



<div id="narrow">

<?php printImageDesc(true); ?>

<div id="comments">

<?php $num getCommentCount(); echo ($num == 0) ? "" : ("<h3>Comments ($num)</h3>"); ?>

<?php while (next_comment()):  ?>

<div class="comment">

<div class="commentmeta">

<span class="commentauthor"><?php printCommentAuthorLink(); ?></span> says:

</div>

<div class="commentbody">

<?php echo getCommentBody();?>

</div>

<div class="commentdate">

<?php echo getCommentDate();?>

,

<?php echo getCommentTime();?>

          <?php printEditCommentLink('Edit'' | '''); ?>

</div>

</div>

<?php endwhile; ?>

<div class="imgcommentform">

<!-- If comments are on for this image AND album... -->

<h3>Add a comment:</h3>

<form id="commentform" action="#" method="post">

<div><input type="hidden" name="comment" value="1" />

          <input type="hidden" name="remember" value="1" />

          <?php if (isset($error)) { 
?>
<tr><td><div class="error">
There was an error submitting your comment. Name, a valid e-mail address, and a comment are required.
</div></td></tr>
<?php ?>

<table border="0">

<tr>

<td><label for="name">Name:</label></td>

<td><input type="text" id="name" name="name" size="20" value="<?php echo $stored[0];?>" class="inputbox" />

</td>

</tr>

<tr>

<td><label for="email">E-Mail:</label></td>

<td><input type="text" id="email" name="email" size="20" value="<?php echo $stored[1];?>" class="inputbox" />

</td>

</tr>

<tr>

<td><label for="website">Site:</label></td>

<td><input type="text" id="website" name="website" size="40" value="<?php echo $stored[2];?>" class="inputbox" /></td>

</tr>

</table>

<textarea name="comment" rows="6" cols="40"></textarea>

<br />

<input type="submit" value="Add Comment" class="pushbutton" /></div>

</form>

</div>

</div>

</div>

</div>

<div id="footer">

<ul id="rss">

<?php rss_links(); ?>

</ul>

<p>Barbecued by <a href="http://snews.solucija.com/" title="Single file CMS">sNews</a>
&middot; <?php login_link(); ?></p>

</div>

</div>

</body>

</html>

9. If you want Recent Images and Random Images, then go to functions.php found in the zen folder and add this:
Code: [Select]
/////////**********MODS**********/////////////////
/* Show Latest Images */
/* http://anton.gektoras.lt/zenphoto/zenphoto-latest-images */
function show_latest_images($number) {
$images = query_full_array("SELECT images.albumid, images.filename AS filename, images.title AS title, albums.folder AS folder FROM ".prefix('images')." AS images, ".prefix('albums')." AS albums WHERE images.albumid = albums.id AND images.show = 1 ORDER BY images.id DESC LIMIT $number");
        $size = '_'.zp_conf('thumb_size').'_cw'.zp_conf('thumb_crop_width').'_ch'.zp_conf('thumb_crop_height');
        foreach ($images as $image) {
        $filename = $image['filename'];
        $album = $image['folder'];
              $desc = $image['title'];
              echo '<li>';
                if (zp_conf('mod_rewrite') == false) {
                echo '<a href="'.WEBPATH.'/index.php?album='.$album.'&image='.$filename.'" title="'.$desc.'">';
                } else {
                      echo '<a href="'.WEBPATH.'/'.$album.'/'.$filename.'" title="'.$desc.'">';
                }
// echo '<img src="'.WEBPATH.'/cache/'.$album.'/'.$filename.$size.'.jpg"></a>';
              echo '<img src="'.WEBPATH.'/zen/i.php?a='.$album.'&i='.$filename.'&s=thumb"></a>';
              echo '</li>';
}
}

// Get Random Images
function getRandomImages() {
$result = query_single_row('SELECT '.prefix("images").'.filename,'.prefix("images").'.title, '.prefix("albums").'.folder FROM '.prefix("images").' INNER JOIN '.prefix("albums").' ON '.prefix("images").'.albumid = '.prefix("albums").'.id ORDER BY RAND() LIMIT 1');
$image = new Image(new Album(new Gallery(), $result['folder']), $result['filename']);
return $image;
}

function getURL($image) {
if (zp_conf('mod_rewrite')) {
return WEBPATH . "/" . pathurlencode($image->getAlbumName()) . "/" . urlencode($image->name);
} else {
return WEBPATH . "/index.php?album=" . pathurlencode($image->getAlbumName()) . "&image=" . urlencode($image->name);
}
}
10.  Back to sNews index.php add these in the sidebar for Recent Images and Random image:
Code: [Select]
<h3>New images:</h3>
<ul>
<?php show_latest_images(4); ?>

<ul>

<h3>Random image:</h3>
<?php $randomImage getRandomImages(); $randomImageURL getURL($randomImage); print "<a href='".getURL($randomImage)."' title='Random Picture...'><img src='".$randomImage->getCustomImage(85620180620180300300)."' alt='".$randomImage->getTitle()."' /></a>"?>
10a. The numbers under getCustomImage are defined in zen/i.php:
Code: [Select]
*   s  - size (logical): Based on config, makes an image of "size s."
 *   h  - height (explicit): Image is always h pixels high, w is calculated.
 *   w  - width (explicit): Image is always w pixels wide, h is calculated.
 *   cw - crop width: crops the image to cw pixels wide.
 *   ch - crop height: crops the image to ch pixels high.
 *   cx - crop x position: the x (horizontal) position of the crop area.
 *   cy - crop y position: the y (vertical) position of the crop area.
 *   q  - JPEG quality (1-100): sets the quality of the resulting image.
11.  Referencing sNews default, add in the css:
Code: [Select]
img { border: none; }
12.  Hard link your gallery in Display Pages in snews.php:
Code: [Select]
echo '<li><a href="'.db('website').'gallery/" title="Gallery">Gallery</a></li>';13.  Add a link to the ZenPhoto admin in function administration() (in snews.php of course)
Change
Code: [Select]
echo '<p><a href="files/" title="'.l('files').'">'.l('files').'</a></p></fieldset>';To
Code: [Select]
echo '<p><a href="files/" title="'.l('files').'">'.l('files').'</a></p>';
echo '<p><a href="gallery/zen/admin.php" title="ZenPhoto Admin">Gallery Admin</a></p></fieldset>';

Your done. You should have something similar to the picture below.

I packaged this all for you to use here:
http://www.apadmedia.com/publicfolder/index.php?action=downloadfile&filename=sNews16-zenphoto.zip&directory=sNews%20Mods&

There are fixes that were not applied yet so add these below to the package:
*BUG FIX* - snews index.php should be:
<?php session_start(); include('snews.php'); define('WEBPATH', 'gallery'); require_once("gallery/zen/template-functions.php"); ?>

gallery WEBPATH should not have the '/'. URLs will work otherwise on my machine but for clarity and proper urls, then get rid of the slash

FIX - Add to function administration()
change
Code: [Select]
echo '<p><a href="files/" title="'.l('files').'">'.l('files').'</a></p></fieldset>';to
Code: [Select]
echo '<p><a href="files/" title="'.l('files').'">'.l('files').'</a></p>';
echo '<p><a href="gallery/zen/admin.php" title="ZenPhoto Admin">Gallery Admin</a></p></fieldset>';

Known issue - Gallery does not have current state in Display Pages, tried to follow the previous lines but it wouldn't work...

Let me know if everything else works!!


EDIT***************************
Someone asked about this:


All I did was download this package http://cow.neondragon.net/stuff/reflection/reflection.zip
and add the reflection.js (5kb not bad...)  to where I will be applying the recent images call
I put mine in sNews index.php for now..
Code: [Select]
<script type="text/javascript" src="reflection.js"></script>
Now in the gallery/zen/functions.php replace this line in recent images BEFORE THE CLOSING LI
Code: [Select]
echo '<img src="'.WEBPATH.'/zen/i.php?a='.$album.'&i='.$filename.'&s=thumb" class="reflect rheight33"></a>';All we are adding is the class.  Other uses a reflections are in the zip, so you can add accordingly

Now all your recent images will have a reflection!
« Last Edit: August 29, 2007, 11:55:00 PM by centered effect »
Logged

centered

  • Guest
Re: [Mod]Integrating ZenPhoto in sNews 1.6 WIP
« Reply #1 on: August 23, 2007, 11:17:44 PM »

If you need more functionality, check the ZenPhoto Trac: http://www.zenphoto.org/trac/wiki/ZenphotoHacks

These are untested by me, just to note.

Additionally, one may want:
Passowrd Protected Albums: http://www.zenphoto.org/trac/wiki/ZenphotoHacks#PasswordProtectedAlbums (for ZP only I assume)
Captcha for Comments: http://gregoryb.dyndns.org/public/scripts/zenphoto_comment_protection.zip (ZP only)
Watermarks: http://www.zenphoto.org/trac/wiki/ZenphotoHacks#WatermarkingHack (ZP only)
Recent Comments: http://www.zenphoto.org/trac/wiki/ZenphotoHacks#RecentCommentsCustomFunction
       Add to sNews theme in ZP themes and in sNews index.php <?php show_latest_comments(3); ?>



Logged

piXelatedEmpire

  • MIA
  • ULTIMATE member
  • ******
  • Karma: 37
  • Posts: 1401
  • currently MIA
Re: [Mod]Integrating ZenPhoto in sNews 1.6 WIP
« Reply #2 on: August 24, 2007, 04:32:02 AM »

It looks like the ZenPhoto development is up in the air at the moment - the main developer has been very quiet in the forums etc and not many updates.  I hope the project continues in its devlopment as it has a lot of potential.  I noticed Plogger has been updated to 3.0beta as well.

Thanks for these instructions centered, worth considering as an option for a gallery.
Logged
my apologies to the sNews crew, but I will be MIA for the forseeable future

centered

  • Guest
Re: [Mod]Integrating ZenPhoto in sNews 1.6 WIP
« Reply #3 on: August 24, 2007, 04:40:27 AM »

Hey no problem Pixelated.  Even if the main developer stops, I am sure someone else will pick up where he left off.  ZenPhoto is a great software for displaying a gallery and I hope my instructions will help include this gallery in thier site with the new functions (well old really but new to another step towards full sNews intregation).
Logged

Patric Ahlqvist

  • Nobodys perfect, but Im pretty effing close
  • ULTIMATE member
  • ******
  • Karma: 65
  • Posts: 4867
  • “I'm a self-made man and worships my creator.”
    • p-ahlqvist.com
Re: [Mod]Integrating ZenPhoto in sNews 1.6 WIP
« Reply #4 on: August 24, 2007, 09:14:10 AM »

...I noticed Plogger has been updated to 3.0beta as well...

Only hope thath they've manage to solve the issue of "no validation what so freaking ever" in that gallery, then ;)
Logged
"It's only dead fish that goes with the flow... "
Updated

centered

  • Guest
Re: [Mod]Integrating ZenPhoto in sNews 1.6 WIP
« Reply #5 on: August 24, 2007, 12:15:02 PM »

I can't seem to access the Plogger site at the moment, and the demo at opensourcecms doesn't let me upload pictures.... I think I would stick with ZenPhoto myself for the time being.  Plus they are working on bugs and fixes at ZenPhoto anyway, just very slowly atm.

http://www.zenphoto.org/support/topic.php?id=1612
Logged

Patric Ahlqvist

  • Nobodys perfect, but Im pretty effing close
  • ULTIMATE member
  • ******
  • Karma: 65
  • Posts: 4867
  • “I'm a self-made man and worships my creator.”
    • p-ahlqvist.com
Re: [Mod]Integrating ZenPhoto in sNews 1.6 WIP
« Reply #6 on: August 24, 2007, 12:20:28 PM »

You're doing the right thing, CE. I tried out Plogger sometime ago, and phuiii, there was validation issues I can tell you that. I didn't even start trying to adjust them, but swapped for ZP instead. Never failed me once ;)
Logged
"It's only dead fish that goes with the flow... "
Updated

centered

  • Guest
Re: [Mod]Integrating ZenPhoto in sNews 1.6 WIP
« Reply #7 on: August 24, 2007, 12:32:30 PM »

Thanks! Hey Patric, did you get a chance to test the mod, I remember someone wanted this mod as well.... :)
Logged

Patric Ahlqvist

  • Nobodys perfect, but Im pretty effing close
  • ULTIMATE member
  • ******
  • Karma: 65
  • Posts: 4867
  • “I'm a self-made man and worships my creator.”
    • p-ahlqvist.com
Re: [Mod]Integrating ZenPhoto in sNews 1.6 WIP
« Reply #8 on: August 24, 2007, 01:00:30 PM »

No, mate not yet... but I sure will... I like where this is headed, for sure, and I'm most certainly gonna try it out, and most certainly use it on my next site...  One Q, though... is this random only ? If I wanted it just to display newest pics... Is that possible ? Or even better (sorry if I'm troublesome here ;)) some sort of enable/disable randomness, like having it default set to newest pics, and then by either checking a checkbox or by a minor change in snews.php enableing the randomness feature... Just thoughts ;)
« Last Edit: August 24, 2007, 01:02:35 PM by Patric Ahlqvist »
Logged
"It's only dead fish that goes with the flow... "
Updated

centered

  • Guest
Re: [Mod]Integrating ZenPhoto in sNews 1.6 WIP
« Reply #9 on: August 24, 2007, 01:03:22 PM »

Bot functions are there, check out the screenshot.  The mod also works in 1.6, 1.5, and 1.4 (shown below)

Responded too quiclkly,

You can add or take away these functions in the Snews index.php if you want
Code: [Select]
<h3>New images:</h3>
<ul>
<?php show_latest_images(4); ?>

<ul>

<h3>Random image:</h3>
<?php $randomImage getRandomImages(); $randomImageURL getURL($randomImage); print "<a href='".getURL($randomImage)."' title='Random Picture...'><img src='".$randomImage->getCustomImage(85620180620180300300)."' alt='".$randomImage->getTitle()."' /></a>"?>
« Last Edit: August 24, 2007, 01:08:46 PM by centered effect »
Logged

Patric Ahlqvist

  • Nobodys perfect, but Im pretty effing close
  • ULTIMATE member
  • ******
  • Karma: 65
  • Posts: 4867
  • “I'm a self-made man and worships my creator.”
    • p-ahlqvist.com
Re: [Mod]Integrating ZenPhoto in sNews 1.6 WIP
« Reply #10 on: August 24, 2007, 01:09:47 PM »

Goodie, good, good... ;) Will most def. try it out, but at a later date, I'm afraid. Have too much on my "private" hands just now. Thanks for this awsome contribution, CE. Most valuable.
Logged
"It's only dead fish that goes with the flow... "
Updated

centered

  • Guest
Re: [Mod]Integrating ZenPhoto in sNews 1.6 WIP
« Reply #11 on: August 24, 2007, 01:21:22 PM »

Well if it wasn't for you with starting this out, I probably wouldn't get too far!  So thank you Patric. 
Logged

Zucye

  • Sr. Member
  • ****
  • Karma: 5
  • Posts: 347
    • Simplemente una Mujer
Re: [Mod]Integrating ZenPhoto in sNews 1.6 WIP
« Reply #12 on: August 24, 2007, 05:21:00 PM »

Is there a demo??
Logged
We can always learn from our failures, not so much from obvious success - C. Robinson (W. Disney). :)

centered

  • Guest
Re: [Mod]Integrating ZenPhoto in sNews 1.6 WIP
« Reply #13 on: August 24, 2007, 06:34:19 PM »

No demo, sorry.  You could download the package and install the databases and run it from there (put it in a folder called 16 or whatever I have it called.  I placed images in the package to show a working version
Logged

Zucye

  • Sr. Member
  • ****
  • Karma: 5
  • Posts: 347
    • Simplemente una Mujer
Re: [Mod]Integrating ZenPhoto in sNews 1.6 WIP
« Reply #14 on: August 24, 2007, 08:15:40 PM »

Since there is not Demo and I am really tired (reason why I probably don’t get it :( )… Do you care to explain me what is this suppose to do??
Logged
We can always learn from our failures, not so much from obvious success - C. Robinson (W. Disney). :)
Pages: [1] 2 3 4