Attachment Mod

All new MODs released in our MOD Database will be announced in here. All support for released MODs needs to take place in here. No new MODs will be accepted into the MOD Database for phpBB2
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

On February 1, 2009 this forum will be set to read only as part of retiring of phpBB2.

Rating:

Excellent!
2035
71%
Very Good
444
16%
Good
175
6%
Fair
54
2%
Poor
156
5%
 
Total votes: 2864

Qudeid
Registered User
Posts: 27
Joined: Wed Jun 28, 2006 2:17 pm

Post by Qudeid » Fri Jul 14, 2006 11:18 pm

Ehm, I just followed the instructions

Sergeyzh
Registered User
Posts: 7
Joined: Fri Jul 14, 2006 11:08 pm
Location: Seattle, WA

absolute path?

Post by Sergeyzh » Fri Jul 14, 2006 11:29 pm

Hi,

I am sorry if this question has been asked before, but I was unable to find anything by using the search.
I am currently building my forum and have installed the attachement mod. The attachement part works great. I can upload the file to my ftp with no problem. It goes to my /forums/files folder. However, when I try to download the file, it just loads me a page that says "PK□□□."

I know that this has something to do with my configurations. The file can upload, so the mod works. It just cant seem to find the file on my ftp to upload it to others. The directions on the file paths were quite confusing and I could not figure out how to find the FTP path to my upload directory. This is probably my problem. Could someone please tell me how to find the "complete home path?"

Thanks

madpwr1
Registered User
Posts: 93
Joined: Mon Mar 06, 2006 4:24 am

Post by madpwr1 » Fri Jul 14, 2006 11:37 pm

Qudeid wrote: Ehm, I just followed the instructions


would you be able to send me these files that you modified to madpwr1@gmail.com or just post them up here using code tags?

posting_attachments.php, displaying.php, functions_thumbs.php, lang_admin_attach.php, lang_main_attach.php, viewtopic_attach_body.tpl

JJLodge
Registered User
Posts: 48
Joined: Mon Jan 16, 2006 10:24 am

Post by JJLodge » Fri Jul 14, 2006 11:51 pm

help please :)

i installed this mod works a treat now well after i corrected a typo lol, one prob is though since installing it when a PM is sent it shows the sender but noting in the subject, its completly empty ??

please help, obviously a very big part of the forum i am now missing

James

User avatar
DavidIQ
Customisations Team Leader
Customisations Team Leader
Posts: 17050
Joined: Thu Jan 06, 2005 1:30 pm
Location: Fishkill, NY
Name: David Colón
Contact:

Post by DavidIQ » Fri Jul 14, 2006 11:53 pm

JJLodge wrote: help please :)

i installed this mod works a treat now well after i corrected a typo lol, one prob is though since installing it when a PM is sent it shows the sender but noting in the subject, its completly empty ??

please help, obviously a very big part of the forum i am now missing

James

Is this when looking at the list of PMs or...?
Apply to become a Jr. Extension Validator
My extensions | In need of phpBB services? | Was I helpful today?
No unsolicited PMs unless you're planning on asking for paid help.

JJLodge
Registered User
Posts: 48
Joined: Mon Jan 16, 2006 10:24 am

Post by JJLodge » Fri Jul 14, 2006 11:56 pm

yes its when i clcik on where it says you have * number of pm's

James

Qudeid
Registered User
Posts: 27
Joined: Wed Jun 28, 2006 2:17 pm

Post by Qudeid » Sat Jul 15, 2006 12:00 am

@madpwr1: The problem is, that I'm using the german language-files. And I actually don't feel like translating them. The others, though, I could send you... But why not try to do it again? Is there any error or so?

@My question: Could anyone help me out? Please? I know it's just an aesthetics thingy.. but.. It would be great, you know...

User avatar
DavidIQ
Customisations Team Leader
Customisations Team Leader
Posts: 17050
Joined: Thu Jan 06, 2005 1:30 pm
Location: Fishkill, NY
Name: David Colón
Contact:

Post by DavidIQ » Sat Jul 15, 2006 12:10 am

Actually madpwr1...it's probably not working right for Qudeid either. I just did the edits and I have the same symptoms as you're having. The only way that he/she is getting it to work is if they have the minimum thumbnail filesize value set. Tracing the edits to see what's going on...
Apply to become a Jr. Extension Validator
My extensions | In need of phpBB services? | Was I helpful today?
No unsolicited PMs unless you're planning on asking for paid help.

User avatar
DavidIQ
Customisations Team Leader
Customisations Team Leader
Posts: 17050
Joined: Thu Jan 06, 2005 1:30 pm
Location: Fishkill, NY
Name: David Colón
Contact:

Post by DavidIQ » Sat Jul 15, 2006 12:38 am

madpwr1 wrote:
Qudeid wrote:Ehm, I just followed the instructions


would you be able to send me these files that you modified to madpwr1@gmail.com or just post them up here using code tags?

posting_attachments.php, displaying.php, functions_thumbs.php, lang_admin_attach.php, lang_main_attach.php, viewtopic_attach_body.tpl

Ok...after an hour of toying around with the files from that other mod I'm able to fix the problem you're having. Make sure you have thumbnails set to yes...well actually that doesn't really matter the way this was written :roll:

Here's the additional changes:

Code: Select all

# 
#-----[ OPEN ]------------------------------------------ 
# 
attach_mod/includes/functions_thumbs.php

# 
#-----[ FIND ]------------------------------------------ 
# 
	if (!$img_filesize || $img_filesize <= $min_filesize)
	{
		return false;
	}

	list($width, $height, $type, ) = getimagesize($source);

# 
#-----[ REPLACE WITH ]------------------------------------------ 
# 
	list($width, $height, $type, ) = getimagesize($source);

	if (!(($width > intval($attach_config['img_link_width'])) || ($height > intval($attach_config['img_link_height']))))
	{
		if (!$img_filesize || $img_filesize <= $min_filesize)
		{
			return false;
		}
	}
Here's the example:
http://www.davidiq.net/phpBB2/viewtopic.php?t=3
Apply to become a Jr. Extension Validator
My extensions | In need of phpBB services? | Was I helpful today?
No unsolicited PMs unless you're planning on asking for paid help.

User avatar
DavidIQ
Customisations Team Leader
Customisations Team Leader
Posts: 17050
Joined: Thu Jan 06, 2005 1:30 pm
Location: Fishkill, NY
Name: David Colón
Contact:

Post by DavidIQ » Sat Jul 15, 2006 12:48 am

Oh yeah...and on that one I know it looks a tad different from what you end up with after you install that mod but I didn't like the edits that guy did to the template files so I left out the template edits. Still works fine but in my case I probably could have left out all (or most) edits done to displaying.php.
Apply to become a Jr. Extension Validator
My extensions | In need of phpBB services? | Was I helpful today?
No unsolicited PMs unless you're planning on asking for paid help.

User avatar
DavidIQ
Customisations Team Leader
Customisations Team Leader
Posts: 17050
Joined: Thu Jan 06, 2005 1:30 pm
Location: Fishkill, NY
Name: David Colón
Contact:

Post by DavidIQ » Sat Jul 15, 2006 12:55 am

Qudeid wrote: Hi there,

My actual state is that I have the Attachment-Mod installed and this "thumbnail to dimension" thingy. Everything works properly.

But, since in the thumbnail to dimension thingy is no comment integrated (you know, the "comment" you can type in when uploading your attachment), I added it manually. There is no problem with that.
The only thing I want to "fix" now is: If there is no comment at all, I don't want this cell under the thumbnail to be there.

I don't have any idea how to achieve that. It would be possible if there were the possibility of php in the templates. But isn't there any other way to get that? Okay, it's nothing too important. It would really be nice, though.

thanks to you in advance

Qudeid

Oh.. and the topic (for an example) is this one: http://wv.awardspace.com/WV/viewtopic.php?p=21#21 (Sorry it's german, but I guess you'll get the idea)

This will take some time as the comment gets added separately for every file type posted. I know how to do it but it'll have to wait until later.
Apply to become a Jr. Extension Validator
My extensions | In need of phpBB services? | Was I helpful today?
No unsolicited PMs unless you're planning on asking for paid help.

OKCRandy
Registered User
Posts: 51
Joined: Sat Dec 10, 2005 1:07 am
Location: NE of OKC

FTP Upload

Post by OKCRandy » Sat Jul 15, 2006 1:18 am

I am getting this error and at a loss as to how to fix it.

Could not upload files to ftp directory: '/web/okcrandy.com/phpBB2/upload'. Please check your FTP Settings.

The information for my phpbb server is:

ftp.okcrandy.com

ftp path:
/web/okcrandy.com/phpBB2/

Uploads location:/web/okcrandy.com/phpBB2/upload

ftp client example of my connection:
Image

The information entered in Attachment Mod:

FTP Upload Server: ftp.okcrandy.com

FTP Path to your upload directory: /web/okcrandy.com/phpBB2/upload

Download Link to FTP Path : upload

Then of course the username and password for my ftp provider.

User avatar
DavidIQ
Customisations Team Leader
Customisations Team Leader
Posts: 17050
Joined: Thu Jan 06, 2005 1:30 pm
Location: Fishkill, NY
Name: David Colón
Contact:

Post by DavidIQ » Sat Jul 15, 2006 2:27 am

Turn off the FTP option. You don't need that if you're hosting the files in the same place you're hosting your forum.
Apply to become a Jr. Extension Validator
My extensions | In need of phpBB services? | Was I helpful today?
No unsolicited PMs unless you're planning on asking for paid help.

madpwr1
Registered User
Posts: 93
Joined: Mon Mar 06, 2006 4:24 am

Post by madpwr1 » Sat Jul 15, 2006 2:30 am

DavidIQ wrote:
madpwr1 wrote:
Qudeid wrote:Ehm, I just followed the instructions


would you be able to send me these files that you modified to madpwr1@gmail.com or just post them up here using code tags?

posting_attachments.php, displaying.php, functions_thumbs.php, lang_admin_attach.php, lang_main_attach.php, viewtopic_attach_body.tpl

Ok...after an hour of toying around with the files from that other mod I'm able to fix the problem you're having. Make sure you have thumbnails set to yes...well actually that doesn't really matter the way this was written :roll:



That got the thumbnails to show up now! thanks for the help ... now there needs to be some appearance changes made and it'll be perfect ... would you happen to know what i need to change to change the size of the thumbnail shown and which file contains the lines and box etc that appear around the images?

User avatar
DavidIQ
Customisations Team Leader
Customisations Team Leader
Posts: 17050
Joined: Thu Jan 06, 2005 1:30 pm
Location: Fishkill, NY
Name: David Colón
Contact:

Post by DavidIQ » Sat Jul 15, 2006 2:39 am

To change the thumbnail size just change $max_width = 150; in functions_thumbs.php to whatever you'd like. It was 400 before. As far as the tables go you'll just need to edit viewtopic_attach_body.tpl. Like I said...I don't like what the mod author did with the tables so I kept the original file as is. The changes he made basically place the attachments all in one row in the case there's more than one.
Apply to become a Jr. Extension Validator
My extensions | In need of phpBB services? | Was I helpful today?
No unsolicited PMs unless you're planning on asking for paid help.

Post Reply

Return to “[2.0.x] MOD Database Releases”