Webmastersite.net
Register Log In

Comment Attachments

Comments on Comment Attachments

zippo
Forum Regular

Usergroup: Customer
Joined: Jan 11, 2006

Total Topics: 48
Total Comments: 166
zippo
Posted Jan 24, 2006 - 11:56 AM:

If I upload attachments to a comment strage things happen.

- graphic files (gif,png,etc) not showing thumbnails
- not usable in any other way except delete attachement

I am able to upload/use avatars okay however.

./attachments/*.* all <a href="http://scripts.webmastersite.net/wsnlinks/wsnmanual/articles/107"><a href="http://scripts.webmastersite.net/wsnlinks/wsnmanual/articles/107">chmod</a></a> 777 and the files do show in the directory.

I am using:

File attachments naming method: random
Remove File Extensions? yes
Allow All Extensions: yes

Additionally I have log entries such as:

PHP Warning: imagejpeg(): supplied argument is not a valid Image resource in /httpdocs/classes/gd.php on line 216
PHP Warning: imagecreatefrompng(templates/default/images/nothumbnail.png): failed to open stream: No such file or directory in /httpdocs/classes/gd.php on line 195
PHP Warning: imagesx(): supplied argument is not a valid Image resource in /httpdocs/classes/gd.php on line 196
PHP Warning: imagesy(): supplied argument is not a valid Image resource in /httpdocs/classes/gd.php on line 197
PHP Warning: Division by zero in /httpdocs/classes/gd.php on line 198
PHP Warning: Division by zero in /httpdocs/classes/gd.php on line 198

Can onyone confirm this?
Paul
developer

Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California

Total Topics: 61
Total Comments: 7868
Paul
Posted Jan 29, 2006 - 5:09 AM:

Nothing is wrong with comment attachments (as you can note in this forum too).
zippo
Forum Regular

Usergroup: Customer
Joined: Jan 11, 2006

Total Topics: 48
Total Comments: 166
zippo
Posted Jan 29, 2006 - 10:35 PM:

Something is not right though since the attachment is effectivly not here for anything but deleting after uploading.

I created a comment, attached a .png image and the final comment shows the attachment link (which goes to a blank page) and the icon that should be displayed below the text link, isn't.

Consequently I can attach the same file in the link description and the link works. However the 0KB size is not correct..

I noticed the attachment for comments was not stored in the category directory as the link description attachment is.. IE: The comment attachment for the same link is being saved in /attachments where the link description attachment is being saved to /attachments/category.
Paul
developer

Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California

Total Topics: 61
Total Comments: 7868
Paul
Posted Jan 31, 2006 - 10:43 AM:

Observe. It works the same as this in Links for me:

Attached Files:
zippo
Forum Regular

Usergroup: Customer
Joined: Jan 11, 2006

Total Topics: 48
Total Comments: 166
zippo
Posted Feb 01, 2006 - 7:35 AM:

Hmm. I will try a separate / new installation and see what happens. I forgot to mention that I also have:

[SEO]
Use apache mod_rewrite URL rewriting: yes
Use category names in URL: yes
Use link names in link details URL: yes

[SWITCHES]
Attachments directory as category tree: on

..also, although I realize there is some of the same code between Forum and Links (hence your reference to Forum for examples/tests above) I wanted to clarify in case we've misunderstood each other, that I am talking about Links. wink
zippo
Forum Regular

Usergroup: Customer
Joined: Jan 11, 2006

Total Topics: 48
Total Comments: 166
zippo
Posted Feb 01, 2006 - 4:28 PM:

Okay, I concede. smiling face I tried the 3.3.4B version on another server, shared hosting account. No problems.

One other thing I noticed is that I am getting the attached files uploaded just fine, right size and so forth. However, in the case of images no thumbnails are being generated/properly saved or something. I just have the random named file in the attachments/ directory.

Before I scratch my install and re-do it maybe you could scan below and see if there is anything glaring you're aware of that would be related to my problem? ..or maybe have a suggestion on what I could check/try?
PHP Version: 4.3.11
Zend Engine Version: 1.3.0
Loaded PHP Extensions: yp xml wddx tokenizer sysvshm sysvsem standard sockets shmop session pspell posix pcre overload iconv gmp gettext gd ftp exif dio dbx dba curl ctype calendar bz2 bcmath zlib openssl apache2handler domxml imap ldap mbstring mysql odbc snmp xmlrpc ionCube Loader Zend Optimizer

MySQL Version: 3.23.58
MySQL Stats: Uptime: 523007 Threads: 2 Questions: 174584 Slow queries: 0 Opens: 250 Flush tables: 1 Open tables: 91 Queries per second avg: 0.334

Server Type: Apache/2.0.51 (Fedora)
Accepted Encoding: deflate, gzip, x-gzip, identity, *;q=0
..or with the attached phpinfo()?

Attached Files:
zippo
Forum Regular

Usergroup: Customer
Joined: Jan 11, 2006

Total Topics: 48
Total Comments: 166
zippo
Posted Feb 02, 2006 - 10:06 AM:

Well! I am narrowing this down some..

I turned off in: Settings->Search & SEO
  • Use apache mod_rewrite URL rewriting?
  • Use category names in URL:
  • Use link names in link details URL:
..and commented out the WSN Links rewrite lines in my .htaccess file and regenerated everything. Images in comments are showing now.

I've had no other indication that the re-write rules were not working correctly so I will see if I can isolate what was causing my issue.
zippo
Forum Regular

Usergroup: Customer
Joined: Jan 11, 2006

Total Topics: 48
Total Comments: 166
zippo
Posted Feb 02, 2006 - 11:34 AM:

With the above changes, I still had:

[SWITCHES]
Attachments directory as category tree: on

Images were displaying as thumbnails in the comments but would not show with a click of either the link or thumbnail.

Additionally, an image attached to the link entry was giving zero size until regenerating.

I switched off 'category tree' and regenerated everything. Quirks were still present and the category tree was still present in the /attachments directory. I removed them manually, pruned out the two attachments from the edit link|comment functions and regenerated.

This time the category tree was not re-created and at this point all appears to be working as it should -- proper size figure on link attachment, comment link & thumb properly show image when clicked, etc.

I'll test further but it seems for some reason the category tree got 'stuck' and wasn't destroyed as it should be when I switched it off and regenerated all.
Search thread for
Download thread as
  • 0/5
  • 1
  • 2
  • 3
  • 4
  • 5



This thread is closed, so you cannot post a reply.