Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - scubaguy

Pages: [1]
1
This code was working, but now that I've tried it with 1.7.1 with the security patches it has stopped working.  Absolutely nothing is displayed, not even error messages.  Does anyone know what might be the problem?

I also noticed that when I try to create SEO urls with $site_sess->url they are no longer being converted.  Did something change that I am not aware of.  It all used to work.   :(

2
Mods & Plugins (Requests & Discussions) / Re: Joomla 4images bridge ?
« on: December 26, 2005, 04:53:38 AM »
You might want to look at the Joomla component "com_connector" http://forum.joomla.org/index.php/topic,21066.0.html  I believe that with it you may be able to acomplish what you are looking for.

3
Mods & Plugins (Releases & Support) / Re: [MOD] Simple News Publishing
« on: December 09, 2005, 08:50:46 PM »
With om6acw's Read More code above, it works great if you only have one page.  With more than one page clicking on Read More takes you back to the first page and when you click on the pagination links on the bottom you are taken to the next page, but the news items are not expanded.

Does anyone know how to fix this?

Thanks in advance.

4
Discussion & Troubleshooting / Re: auto Resizing Mod
« on: November 14, 2005, 02:52:51 AM »
Th download link for the install_autoimage.php file was not working.  I was however able to find a copy.  It is attached here.

5
Mods & Plugins (Releases & Support) / Re: [MOD] Simple News Publishing
« on: October 22, 2005, 09:12:58 AM »
I got this mod installed ok, but I don't see any news admin links on the frontend when I am logged in as an admin.  Also the Add and Edit links do not work from the Control Panel.

I can add news directly in the database and it shows up correctly.  I am using 4images 1.7.1

Has anyone else experienced this and is there a fix?

6
Discussion & Troubleshooting / Re: Video Gallery loads sllllooooow
« on: October 22, 2005, 03:47:57 AM »
On a video site I'm using the "filesize" fix and the site went from a complete server crash every 5 minutes with 100+ simultaneous users to lightning fast.  Thanks so much for the fix!

7
I also need to add a function to shorten the length of the image name in functions.php

Code: [Select]
    function ShortenText($text) {

        // Change to the number of characters you want to display
        $chars = 10;

        $text = $text." ";
        $text = substr($text,0,$chars);
        $text = substr($text,0,strrpos($text,' '));
        $text = $text."";

        return $text;

    }

8
I am working on a site that needed three seperate modules showing the Most Recent, the Most Popular and Top Votes.

Here is the code for the Most Recent:

Code: [Select]
<?php // PATH to your 4images Gallery / PFAD zu Ihrer 4images Gallerie
define('ROOT_PATH''../');
  global 
$site_db$cat_cache$total_images;


// NUMBER OF THUMBNAILS TO DISPLAY / NUMMER DER GEWÜNSCHTEN THUMBNAILS
$num_images 5;

$sql "SELECT a.image_id, a.cat_id, a.image_name, a.image_date, a.image_active, a.image_thumb_file, a.image_comments
        FROM "
.IMAGES_TABLE." a, ".CATEGORIES_TABLE." b
        WHERE a.image_active=1
        AND a.cat_id = b.cat_id
AND a.cat_id != 23
        AND b.auth_viewcat="
.AUTH_ALL."
        AND b.auth_viewimage="
.AUTH_ALL."
        ORDER BY a.image_date DESC
        LIMIT 
$num_images";
$result $site_db->query($sql);

if (
$result) {
while (
$row $site_db->fetch_array($result)) {
  
$image_id $row['image_id'];
  
$cat_id $row['cat_id'];
  
$image_name $row['image_name'];
  
$image_comments $row['image_comments'];
  
$thumb_src = (is_remote($row['image_thumb_file'])) ? $row['image_thumb_file'] : ROOT_PATH.THUMB_DIR."/".$cat_id."/".$row['image_thumb_file'];

  echo 
"<div style='float:left;width:66px;height:68px;margin:3px;padding-bottom:4px;'><div style='border:2px solid #ffffff;width:64px;height:64px;'><a href=\"".ROOT_PATH."details.php?image_id=$image_id\"><img src=\"".$thumb_src."\" border=\"0\" alt=\"$image_name\" width=\"64\" height=\"64\"></div>\n";
  echo 
ShortenText($image_name)."\n";
echo "</div>\n";
}
}
?>

Here is the code for Most Popular:

Code: [Select]
<?php // PATH to your 4images Gallery / PFAD zu Ihrer 4images Gallerie
define('ROOT_PATH''../');
  global 
$site_db$cat_cache$total_images;

// NUMBER OF THUMBNAILS TO DISPLAY / NUMMER DER GEWÜNSCHTEN THUMBNAILS
$num_images 12;

$sql "SELECT a.image_id, a.cat_id, a.image_name, a.image_hits, a.image_active, a.image_thumb_file, a.image_comments
        FROM "
.IMAGES_TABLE." a, ".CATEGORIES_TABLE." b
        WHERE a.image_active=1
        AND a.cat_id = b.cat_id
AND a.cat_id != '23'
        AND b.auth_viewcat="
.AUTH_ALL."
        AND b.auth_viewimage="
.AUTH_ALL."
        ORDER BY a.image_hits DESC
        LIMIT 
$num_images";
$result $site_db->query($sql);

if (
$result) {
while (
$row $site_db->fetch_array($result)) {
  
$image_id $row['image_id'];
  
$cat_id $row['cat_id'];
  
$image_name $row['image_name'];
  
$image_comments $row['image_comments'];
  
$thumb_src = (is_remote($row['image_thumb_file'])) ? $row['image_thumb_file'] : ROOT_PATH.THUMB_DIR."/".$cat_id."/".$row['image_thumb_file'];

  echo 
"<div style='float:left;width:66px;height:68px;margin:3px;'><div style='border:2px solid #f2f2f2;width:64px;height:64px;'><a href=\"".ROOT_PATH."details.php?image_id=$image_id\" title=\"$image_name\"><img src=\"".$thumb_src."\" border=\"0\" alt=\"$image_name\"  width='64' height='64'><br>\n";
echo "</div></div>\n";
}
}
?>

Here is the code for the Top Votes:

Code: [Select]
<?php // PATH to your 4images Gallery / PFAD zu Ihrer 4images Gallerie
define('ROOT_PATH''../');
  global 
$site_db$cat_cache$total_images;

// NUMBER OF THUMBNAILS TO DISPLAY / NUMMER DER GEWÜNSCHTEN THUMBNAILS
$num_images 8;

$sql "SELECT DISTINCT a.image_id, a.cat_id, a.image_name, a.image_votes, a.image_active, a.image_thumb_file, a.image_comments, a.image_description, a.image_date
        FROM "
.IMAGES_TABLE." a, ".CATEGORIES_TABLE." b
        WHERE a.image_active=1
AND a.cat_id = '23'
        ORDER BY a.image_date DESC
        LIMIT 
$num_images";
$result $site_db->query($sql);
if (
$result) {
while (
$row $site_db->fetch_array($result)) {
  
$image_id $row['image_id'];
  
$cat_id $row['cat_id'];
$image_description $row['image_description'];
  
$image_name $row['image_name'];
  
$image_comments $row['image_comments'];
  
$thumb_src = (is_remote($row['image_thumb_file'])) ? $row['image_thumb_file'] : ROOT_PATH.THUMB_DIR."/".$cat_id."/".$row['image_thumb_file'];

  echo 
"<div style='float:left;width:66px;height:68px;margin:3px;'><div style='border:2px solid #f2f2f2;width:64px;height:64px;'><a href=\"$image_description\" title=\"$image_name\" target=\"_blank\"><img src=\"".$thumb_src."\" border=\"0\" alt=\"$image_name\" width='64' height='64'><br>\n";
echo "</div></div>\n";
}
}
?>

Pages: [1]