Re: Attachments (pun_attachment)

Doesn't work. PHP-error: "SAFE_MODE restriction...". PunBB gives out that it can't create file.
Why can PunBB create files in the cache directory, but not in other directories?

Re: Attachments (pun_attachment)

Slavok wrote:

Is it a fresh install or an upgrade from another version of the extension? If it is an upgrade, post the version of your extension before upgrading, please.

That's not an upgrade of this extension.

I had the same kind of extension when I was in PunBB 1.1.x but I updated step by step to the last version (1.3.4) and everything else works.

So the error happens when I want to edit a post

The error occurred on line 20 in /home/www/63b135ce53397c1b0bcb278bb4fc6df0/web/comite/post.php(108) : eval()'d code

Database reported: Unknown column 'secure_str' in 'field list' (Errno: 1054).

and also when I clic on the "Add file" button

The error occurred on line 21 in /home/www/63b135ce53397c1b0bcb278bb4fc6df0/web/comite/edit.php(75) : eval()'d code

Database reported: Unknown column 'secure_str' in 'field list' (Errno: 1054).

And everywhere on my forum I have this error :

Notice: Undefined index: attach_disable_attach in /home/www/63b135ce53397c1b0bcb278bb4fc6df0/web/comite/viewtopic.php(***) : eval()'d code on line **

With differents figures instead of the * and once in header instead of viewtopic.

And I'm with the version 1.0.2 of the extension.

Re: Attachments (pun_attachment)

There's no more developpement on this extension ???

Or nobody has no idea of how to solve my problem ?

Thx for you answers !

29

Re: Attachments (pun_attachment)

Hi,

ok, I think I know how to solve it.

I had a few problems too. I upgraded from a previous version. Can't remember what version exactly and the problem was that the column 'secure_str' in my database was missing. Like the error message says. So I removed the extension completly. Deleted everything in the databased connected to the extension and then I installed it again.

Maybe you can just add the secure_str column by hand? I don't really know how the extension works. So if you want to keep your old attachments maybe you will have to do it by hand?! I don't know.

Another problem I had was that the value for the folder where the attachments are saved wasn't updated. So it still tried to upload the attachments to the old folder which didn't exist anymore.

But if you remove everything that shouldn't be a problem. Just don't forget to remove the values in the config table.

30

Re: Attachments (pun_attachment)

maststef wrote:

Doesn't work. PHP-error: "SAFE_MODE restriction...". PunBB gives out that it can't create file.
Why can PunBB create files in the cache directory, but not in other directories?

In PHP, there are some security and safe mode directives. Could you post the values of these directives, please?

Re: Attachments (pun_attachment)

Guys i cant seem to increase the size of an upload.

I have changed the settings in the Administrations-> Group settings but it still limits the upload. Any ideas?

Re: Attachments (pun_attachment)

Tagge wrote:

Hi,

ok, I think I know how to solve it.

I had a few problems too. I upgraded from a previous version. Can't remember what version exactly and the problem was that the column 'secure_str' in my database was missing. Like the error message says. So I removed the extension completly. Deleted everything in the databased connected to the extension and then I installed it again.

Maybe you can just add the secure_str column by hand? I don't really know how the extension works. So if you want to keep your old attachments maybe you will have to do it by hand?! I don't know.

Another problem I had was that the value for the folder where the attachments are saved wasn't updated. So it still tried to upload the attachments to the old folder which didn't exist anymore.

But if you remove everything that shouldn't be a problem. Just don't forget to remove the values in the config table.

Now it works !

Thank you !

33

Re: Attachments (pun_attachment)

There are problems with many types of files i.e .xls, .doc, .ppt,... w/ me it just works with .pdf only. Any advice?

34

Re: Attachments (pun_attachment)

Do any errors appear after uploading the files? Describe in more detail way, please.

35

Re: Attachments (pun_attachment)

There was no error, just can't open the file after downloading sad

36 (edited by jacofan 2009-09-15 07:07)

Re: Attachments (pun_attachment)

seikou wrote:

There was no error, just can't open the file after downloading sad

it can sound weirdly, but there can be a problem with the translation... I have had the same problem with the Uploader mod in punbb 1.2

the problem was, that i translated the mod into slovak language (with accents) and I saved the language file as utf8
and when I downloaded f.e. a .doc file, then I couldn't open it...
so don't save it as utf8 but replace the special characters with those combinations of letters (like in Dreamviewer)

37

Re: Attachments (pun_attachment)

jacofan wrote:
seikou wrote:

There was no error, just can't open the file after downloading sad

it can sound weird, but there can be a problem with the translation... I have had the same problem with the Uploader mod in punbb 1.2
the problem was, that i translated the mod into slovak language (with accents) and I saved the language file as utf8
and when I downloaded f.e. a .doc file, then I couldn't open it...
so don't save it as utf8 but replace the special characters with those combinations of letters (like in Dreamviewer)

Thks for your reply but when i try just using English only the problem still there. So my case could not be the same w/ yours.
Note: My Server is Linux & client is Windows

38

Re: Attachments (pun_attachment)

seikou wrote:

There was no error, just can't open the file after downloading sad

Is uploaded file attached to the post?

39

Re: Attachments (pun_attachment)

Slavok wrote:
seikou wrote:

There was no error, just can't open the file after downloading sad

Is uploaded file attached to the post?

Yep, attached successfully.  sad

Re: Attachments (pun_attachment)

Hello
Any advise...?
Warning: touch() [function.touch]: SAFE MODE Restriction in effect. The script whose uid/gid is 915/916 is not allowed to access /home/domains/mydomain/public_html/foorum/extensions/pun_attachment/attachments/7b418f8cd390d84b393c0b74ab0a3cd7 owned by uid/gid 100/500 in /home/domains/mydomain/public_html/foorum/admin/extensions.php(176) : eval()'d code on line 115

Using PunBB 1.3.4 and fresh pun_attach install. Directory permission set to 777, but still no luck...

Thanks!

Re: Attachments (pun_attachment)

Thanks for the info, I appreciate it.

Re: Attachments (pun_attachment)

ukunilus wrote:

Warning: touch() [function.touch]: SAFE MODE Restriction in effect. The script whose uid/gid is 915/916 is not allowed to access /home/domains/mydomain/public_html/foorum/extensions/pun_attachment/attachments/7b418f8cd390d84b393c0b74ab0a3cd7 owned by uid/gid 100/500 in /home/domains/mydomain/public_html/foorum/admin/extensions.php(176) : eval()'d code on line 115

Hi. For others having the same error. This is server side PHP SAFE MODE restriction. It helped to call to my hosting service and they will re-locate my site to their other server where this safe mode is off.

43

Re: Attachments (pun_attachment)

The pun_attachment 1.0.3 extension released. Fixed possible SQL-injection via GET-parameter.

Re: Attachments (pun_attachment)

Many users tend to upload photos without resizing so you end up with a forum that has MANY huge multi-MB files.  It seems to me that it would be a great feature to resize the images after they are uploaded.  If they are resized to some nominal size that eveyone can view (600-800 px high) then all images can display in the posts.

I would like to work on this.  Any suggestions on how to implement this?

One suggested feature on the wiki page for this extension is to display a thumbnail of the image.  I like this approach as well...wanted to get some feedback on pros and cons from others.

45

Re: Attachments (pun_attachment)

An extension that "uses the GD 2 image library, which now comes packaged with most PHP builds, to dynamically generate image thumbnails on the fly. It works with GIFs, JPGs and PNGs, produces much smaller thumbnail file sizes (saving bandwidth), maintains the proper ratio of your pics, and does not create any extra files on your server."    would be cool

Re: Attachments (pun_attachment)

Hi Forum Member,

i have a strange problem with this nice attachment.

Uploading works good, no problem e.g. with 25 MB Files, because i have edit my php.ini for that.
But every downloading bigger than 2 MB stopps exact at 2048 KB and breaks my file download!?
(i mean the links: /misc.php?item=XXX&download=1)

Why?, any ideas or hints?

Best regards,
Punner

Re: Attachments (pun_attachment)

I think it is a problem from traffic limitation at other server programs.

Why don't you look into your Apache's (or other server's) logs ?

Re: Attachments (pun_attachment)

So, i have found the Problem and my Solution. smile

The Problem was "fpassthru($fp)" in manifest.xml (Line 951).
This Function is buggy on my PHP Version (see http://google.de/search?q=%2Bfpassthru+%2B2mb).
I have change line 951 in manifest.xml to...

while( (!feof($fp)) && (connection_status()==0)){
   print(fread($fp, 1024*8));
   flush();
}
fclose($fp);

...and now it works with Files bigger than 2MB. smile

49

Re: Attachments (pun_attachment)

1. How do I make attachments visible for guests?

2. The download link [...]misc.php?item=[#]&download=1 can be pasted into another website (assuming a member has accessed it and copied it) and the file then downloaded without any restrictions (however the counting then stops on my website) - so : is there a way to keep counting, or even know where it is being accessed from?

(ps: the good thing about 2. is that I can pop in the download link to anything I've uploaded to my forum here and the file is directly downloaded to the client without any rapidshare, mediafire, etc etc limitations or ads!)

50

Re: Attachments (pun_attachment)

1. Edit the group permissions for guests. The "Allow users to download files" option should be checked.
2. There are some permissions checking at this page. Are you sure that the user haven't rights to download files?