Random photos module Random photos module
 

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Main Menu

Random photos module

Started by bellimar, December 01, 2005, 01:51:12 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

bellimar

Hi,
What is wrong here bacuse in other album it works. Tell me what I do wrong. This is module random pics on main site.

<?php

/** ensure this file is being included by a parent file */
defined( '_VALID_MOS' ) or die( 'Direct Access to this location is not allowed.' );


echo '<center>';
$ara1 = mysql_connect('localhost', '******', '*****')
   or die('Could not connect: ' . mysql_error());
mysql_select_db ('******');


$query = "SELECT * FROM `cpg135_albums` ORDER BY RAND() LIMIT 0,3";
$result = mysql_query($query);
while($r = mysql_fetch_array($result)) {


echo '<a href="http://www.galeria.arachnea.pl/displayimage.php?cat='.$r['category'].'" target="_blank"><img src="http://www.galeria.arachnea.pl/thumbnails.php?cat='.$r['pid'].'" alt="obrazek" class="bob"/></a><br/><br/>';
}

echo '</center>';
mysql_close($ara1);

?>

Joachim Müller

not sure what your question is - standalone coppermine doesn't come with "modules".