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.


Topics - seastorm42

Pages: [1]
1
I'd like any advice anyone has to give about using the following  as a php include to cause a Movable Type blog to show the last 5 new thumbs from a 4images gallery.

Quote
<?php
define('ROOT_PATH', '../gallery/');
include(ROOT_PATH.'config.php');
include(ROOT_PATH.'includes/db_mysql.php');
include(ROOT_PATH.'includes/constants.php');

$site_db = new Db($db_host, $db_user, $db_password, $db_name);
function is_remote($file_name) {
return (preg_match('#^https?\\:\\/\\/[a-z0-9\-]+\.([a-z0-9\-]+\.)?[a-z]+#i', $file_name)) ? 1 : 0;
}

$num_images = 5;

$sql = "SELECT a.image_id, a.image_date, a.cat_id, a.image_name, a.image_active, a.image_thumb_file
FROM ".IMAGES_TABLE." a, ".CATEGORIES_TABLE." b
WHERE a.image_active=1
AND a.cat_id = b.cat_id
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);

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


echo "<center><table><tr><td width=120 align=center><a href=\"".ROOT_PATH."details.php?image_id=$image_id\"><br/><img src=\"".$thumb_src."\" border=\"0\" alt=\"$image_name\"></a><br></td><td class=main_td valign=top><b>$image_name</b></td></td></table></center>\n";
}
?>


I installed it on my index.php blog page with an include and it showed the last 5 images wonderfully...  but when i added a new photo to the gallery it didn't show up... I can't figure out why.  

Any ideas?

2
Templates & Styles (Requests & Discussions) / Member options won't stay set
« on: December 10, 2002, 05:06:43 PM »
I have my site www.image-cafe.net running through one of the www.vierstra.com templates (modified) but I have ver 1.7 installed of 4images.  

I've tried to set the USER SETTINGS through the control panel, such as "Allow users to edit their own images" etc. I've set them to YES allow users to edit, delete, etc.  Saved it but everytime I exit and come back into the program it's reset back to NO for all those selections.   :?:

I'm thinking this might be due to the template being built for an older ver of 4images??  

Any suggestions what files i need to update in the 4ROUND template to make it ver 1.7 compliant??

3
Mods & Plugins (Requests & Discussions) / Email about comments
« on: December 10, 2002, 04:59:49 PM »
Is it possible to have the site email the person who posted the image whenever someone adds a comment to one of the images they have uploaded?   :?:

4
Discussion & Troubleshooting / Banning IPs and/or users email
« on: December 06, 2002, 06:48:49 AM »
Is there a way to ban a certain email address/ ip address from registering and gaining access to a 4images gallery??? (without making the registration depend on webmaster approval for each and every new person?)

5
On the categories.php pages that come up when you select a certain catgegory that contains all the thumbs ....

I'd like to add the download count underneath HITS on my category pages so all at one glance I can see how popular which images are.

Can someone please help me with this???  I'm pretty good at following instructions if someone can tell me where to add the codes.

Thanks,
Becky

6
Installation, Update & Configuration / MY SQL Question
« on: November 09, 2002, 06:27:11 AM »
Will 4images run on sql 2000 ???

7
I'm hoping for some words of wisdom here...

I have decided to change hosts (since the one I currently have is always having downtime) and I am faced with moving the entire website with over 700 photos in the database.

I need to know what you would recommend before I do this.

I want to move it hopefully without losing any setup or photos.  I have extensively modified the look of my site's gallery with 4images and I'd have to have to start over.  Please advise! Thanks...

I also need to rename the database and change the password when I move it.  I can't for the life of me remember where to go do this...

Thank you in advance for any advice and or help.

Becky
webmaster@image-cafe.net


PS... please forgive me if this question has already been answered in language other than English.

8
My sever crashed. They restored (so they say) and now the gallery shows these messages at the top of every screen:

DB Error: Bad SQL Query: SELECT DISTINCT i.image_id, i.cat_id, i.user_id, i.image_name, i.image_description, i.image_keywords, i.image_date, i.image_active, i.image_media_file, i.image_thumb_file, i.image_download_url, i.image_allow_comments, i.image_comments, i.image_downloads, i.image_votes, i.image_rating, i.image_hits, u.user_name, c.cat_name FROM ic_images i, ic_users u, ic_categories c WHERE i.image_active = 1 AND i.cat_id NOT IN (0, 17, 18, 16) AND u.user_id = i.user_id AND c.cat_id = i.cat_id ORDER BY RAND()
Got error 28 from table handler

DB Error: Bad SQL Query : SELECT i.image_id, i.cat_id, i.user_id, i.image_name, i.image_description, i.image_keywords, i.image_date, i.image_active, i.image_media_file, i.image_thumb_file, i.image_download_url, i.image_allow_comments, i.image_comments, i.image_downloads, i.image_votes, i.image_rating, i.image_hits, u.user_name, c.cat_name FROM ic_images i, ic_users u, ic_categories c WHERE i.image_active = 1 AND u.user_id = i.user_id AND c.cat_id = i.cat_id AND i.cat_id NOT IN (0, 17, 18, 16) ORDER BY i.image_date DESC LIMIT 4
Got error 28 from table handler

Warning: Supplied argument is not a valid MySQL result resource in /usr/local/psa/home/vhosts/image-cafe.net/httpdocs/ic/includes/db_mysql.php on line 113


Can anyone help me repair this?

Becky
webmaster at
www.image-cafe.net/ic

9
Mods & Plugins (Requests & Discussions) / download log?
« on: August 25, 2002, 03:41:12 PM »
Is it possible to have a download log of what images are downloaded by which users???  How hard would that be to modify?

10
Can anyone help me or tell me if i can alter the files / templates somehow to leave off the user name by the images????  I personally add all the images to my site so i really don't need all the images to have "IC STOCK PHOTO" next to them.

Any suggestions or ideas?

Thanks,
Becky

PS... I can only read English so any replies need to be English and if I posted this incorrectly please forgive me.

11
Meaning I'd like to show the image on the screen at 450x600 but the download size be 900x1200 ??  I've seen this on other setups and wondered if we could do this here?

Some of the photos I've put in my gallery would be great to keep at original size, but I don't particularly want to view them at that size online, but have the big size avail for download...

just wondering...

12
Discussion & Troubleshooting / SAFE MODE problem?
« on: July 20, 2002, 04:25:39 PM »
I need help with an error message that appears
When I try to move a photo that was uploaded by one of my users FROM one folder to another folder i get this message and it loses my photos can anyone help?

Warning: SAFE MODE Restriction in effect. The script whose uid is 10647 is not allowed to access ./../data/media/40/DCP05149.jpg owned by uid 48 in /usr/local/psa/home/vhosts/image-cafe.net/httpdocs/images/admin/admin_functions.php on line 110

Warning: SAFE MODE Restriction in effect. The script whose uid is 10647 is not allowed to access ./../data/thumbnails/40/DCP05149.jpg owned by uid 48 in /usr/local/psa/home/vhosts/image-cafe.net/httpdocs/images/admin/admin_functions.php on line 154

help!!!

Can anyone tell me how to fix this? Is this a permissions problem, or a SERVER issue?

13
Installation, Update & Configuration / Directory Permission Settings
« on: July 10, 2002, 09:09:14 PM »
I have been unable to upload any entries after installing the program today. I'm sure it is something I have not configured.

This is the message I get whenever I try to upload an image:

Error uploading image file: 0001-bf.jpg
0001-bf.jpg: Copy error. Please check the directory permissions.

No database entry!


I have the directory set at 777. Also tried 755.

can anyone offer assistance?
=============================================
I'm still working on the....

here is the complete message i recieve whenever i try to upload any files to my site:


Warning: Unable to create './../data/thumbnails/14/0004-bf.jpg': No such file or directory in /usr/local/psa/home/vhosts/image-cafe.net/httpdocs/images/includes/upload.php on line 111

Warning: Unable to move '/tmp/phpvBX8eD' to './../data/thumbnails/14/0004-bf.jpg' in /usr/local/psa/home/vhosts/image-cafe.net/httpdocs/images/includes/upload.php on line 111
Image 1  
  Image file uploaded: 0004-bf.jpg
Error uploading thumbnail file: 0004-bf-tn.jpg
0004-bf.jpg: Copy error. Please check the directory permissions.

Image file deleted
No database entry!

 
 
Any ideas???


Thanks!

Pages: [1]