View Thread
Private Stock » Administrative and Housekeeping » Site Notes
 Print Thread
Edited random_photo_center_panel.php in BACK ROOM ONLY
Royce
I customized the code in the random_photo_center_panel.php file IN THE BACK ROOM ONLY to make the images smaller and more of them displayed.

Original:

if (!defined("IN_FUSION")) { die("Access Denied"); }

if (file_exists(INFUSIONS."random_photo_center_panel/locale/".$settings['locale'].".php")) {
   include INFUSIONS."random_photo_center_panel/locale/".$settings['locale'].".php";
} else {
   include INFUSIONS."random_photo_center_panel/locale/English.php";
}

$result=dbquery(
   "SELECT ta.album_id,album_title,photo_id,photo_title,photo_thumb1 FROM ".$db_prefix."photo_albums ta ".
   "JOIN ".$db_prefix."photos USING (album_id) ORDER BY RAND() LIMIT 6"
   );

opentable($locale['rpc100']);
if (dbrows($result)!= "0") {
   echo "
";
   while($data = dbarray($result)) {
      echo "";
   }
   echo "
";
      echo "";
      echo "100' height='75' title='".$data['photo_title']."' alt='".$data['photo_title']."' border='0'>
";
      echo "
".$data['photo_title']."";
      echo "
".$locale['rpc101']."
".$data['album_title']."";
      echo "
";
} else {
   echo $locale['rpc102'];
}


Modified to:

if (!defined("IN_FUSION")) { die("Access Denied"); }

if (file_exists(INFUSIONS."random_photo_center_panel/locale/".$settings['locale'].".php")) {
   include INFUSIONS."random_photo_center_panel/locale/".$settings['locale'].".php";
} else {
   include INFUSIONS."random_photo_center_panel/locale/English.php";
}

$result=dbquery(
   "SELECT ta.album_id,album_title,photo_id,photo_title,photo_thumb1 FROM ".$db_prefix."photo_albums ta ".
   "JOIN ".$db_prefix."photos USING (album_id) ORDER BY RAND() LIMIT 10"
   );

opentable($locale['rpc100']);
if (dbrows($result)!= "0") {
   echo "
";
   while($data = dbarray($result)) {
      echo "";
   }
   echo "
";
      echo "";
      echo "50' height='38' title='".$data['photo_title']."' alt='".$data['photo_title']."' border='0'>
";
      echo "
".$data['photo_title']."";
      echo "
".$locale['rpc101']."
".$data['album_title']."";
      echo "
";
} else {
   echo $locale['rpc102'];
}

 
Jump to Forum