View Full Version : IE says cannot download attachment.php
AFemaleProdigy
02-21-2011, 02:57 AM
I'm having an odd issue... never seen it before. When adding an attachment to a post, all seems to work well. But then when you try to click the link to view the attachment, you get an error saying "cannot open attachment.php".
I checked the tables and all the information appears to be there. The url looks like it's correct. I tried converting to storing as file system, but still have the same error.
Here is the url to a page where I posted a test pdf file (last post):
http://www.40by20.com/forum/showthread.php?751-Winningest-American-doubles-players-do-it-again&p=2609#post2609
Anyone have any ideas??
Thanks!
Lynne
02-21-2011, 03:06 AM
You don't allow guests to download attachments, so I just get a login screen when clicking on the link.
Does this work with other browsers like firefox?
AFemaleProdigy
02-22-2011, 11:36 PM
Hi, sorry it took me so long to reply. Ok, I changed the permissions so that guests can now download attachments. If you have any solutions, I would really really appreciate it! Thanks! :D
I just tried it in FF and got this error...
XML Parsing Error: unexpected parser state
Location: jar:file:///C:/Program%20Files/Mozilla%20Firefox/chrome/toolkit.jar!/content/global/netError.xhtml
Line Number 327, Column 50: <div id="ed_netReset">&netReset.longDesc;</div>
Lynne
02-23-2011, 12:20 AM
I get this error trying to download that attachment:
File not found
Firefox can't find the file at http://www.40by20.com/forum/attachment.php?attachmentid=127&d=1298262938.
* Check the file name for capitalization or other typing errors.
* Check to see if the file was moved, renamed or deleted.
I'd suggest creating a new style with no parent:
Styles & Templates > Style Manager > Add New Style
Parent Style: No Parent Style
Title: Default vBulletin
Allow User Selection: Yes
Save
Then go to that thread using that totally default vbulletin style - do you still have the same problem?
If so, try disabling your modifications/plugins and see if you still have this problem.
Note: To temporarily disable the plugin system, edit includes/config.php and add this line right under <?php
define('DISABLE_HOOKS', true);
AFemaleProdigy
02-27-2011, 02:47 PM
I created the custom theme with no parent style so it was a completely separate style. So I just made the original default style active to test. I still got the same error. Created a new default style just in case... same error.
There are no plugins/products installed, but I put that bit of code in config anyway to test. Still got the same error.
sigh :confused:
Could this be a problem in the database?
Lynne
02-27-2011, 04:11 PM
I doubt it is a problem with the database, I would suspect the server is the issue.
What is the mime type you have for the pdf in your attachment manager?
And how big is the pdf - do you get this error for both large and small files of that type?
AFemaleProdigy
02-27-2011, 04:44 PM
There appears to be some issue with more than one type of attachment. jpg images that are attached show up as a red x and the picture is not displayed.
I just noticed something though... if you take a look at this thread, a member posted two image inline in his post. They appear to show up just fine. But then below that, another member quoted that post and the images were converted to attachment links. If you try to click the attachment links, you get that same error with the image not displaying (red x).
http://40by20.com/forum/showthread.php?134&p=246#post246
It seems to me there is something causing problems when you try to click an attachment link and open it in a separate view. If that makes sense.
The file sizes are all varied by the way.
How do I determine the mime type?
I am also a web host reseller for GoDaddy. This website is hosted via my reseller site. I have been using vB on this hosting for many years, including currently with no problems. I have never experienced this issue. I have never had any issue with the server settings/etc.
Lynne
02-27-2011, 05:18 PM
Go to Maintenance > Diagnostics > Upload. What happens there if you upload? What is the info it spits out?
And, what do you have set in AdminCP > Settings > Options > Server Settings and Optimization Options > Safe Mode Upload Enable and Safe Mode Temporary Directory ?
AFemaleProdigy
02-27-2011, 05:37 PM
no errors...
file_uploads:on
open_basedir: none
safe_mode: off
upload_tmp_dir: /tmp
upload_max_filesize: 8.00 MB
"No errors occurred while opening the uploaded file for reading. "
Lynne
02-27-2011, 05:49 PM
Where are your attachments being served from right now - the database or filesystem? If in the filesystem, can you see the files in that directory? Is the directory chmod 777 and all directories in it also?
AFemaleProdigy
02-27-2011, 06:12 PM
Initially they were stored in the database when I noticed the problem. I then tried changing to file system to see if that would correct the problem, but it did not. So it's currently in the file system. All CHMOD permissions have been at 777 the whole time.
Lynne
02-27-2011, 07:00 PM
And can you actually *see* the attach files in the file system?
AFemaleProdigy
02-27-2011, 07:15 PM
The files show up like this... 116.attach and my pc does not have a program to open that format. But they are there and they show the correct file sizes.
Zachery
02-27-2011, 07:25 PM
What is the mime-type seto to in the attachment manager for the broken images?
AdminCP > Attachments > Attachment Manager (or Extension and Sizes) edit each attachment to view the mime type.
AFemaleProdigy
02-27-2011, 07:34 PM
ahhh... ok...
PDF: Content-type: application/pdf
JPG: Content-type: image/jpeg
JPEG: Content-type: image/jpeg
Do you need to see any of the other formats?
Zachery
02-27-2011, 08:53 PM
Failed to load source for: http://www.40by20.com/forum/attachment.php?attachmentid=127&d=1298262938I get a http 503 error for service unavaiable. Are you on a shared webhost or a dediated machine?
AFemaleProdigy
02-27-2011, 09:47 PM
Shared hosting.
PS.... I saw one other person on vBulletin.com that reported the same exact problem, but no one ever responded to his post.
Zachery
02-28-2011, 12:49 PM
If you have a valid ticket support option (suite, or ticket support contract). Can you open a support ticket to my attention? :)
AFemaleProdigy
03-02-2011, 12:46 AM
Woohoo!! I figured this out on my own!
I put my email address into the config file for the error reporting. I then got an error emailed to me telling me the attachmentviews table did not exist. That was odd to me because I did a full export of the old vB database and imported it into the new vB database. So I went back to the old DB to check it out. I noticed that the attachmentviews table in the old DB said "in use" and nothing I did would turn it off. So I just went to the new DB and ran a query to create the new table from scratch. Now all of our attachments seem to be working fine.
I am curious though... Does anyone know of a way to tell the old DB mySQL to stop running that table without damaging it's content?
Thanks everyone for all your help!!
Zachery
03-06-2011, 01:21 AM
IN USE means its locked for some reason, normally crashed.
your24hourstore
03-06-2011, 01:45 PM
downloaded for me in firefox
vBulletin® v3.8.12 by vBS, Copyright ©2000-2025, vBulletin Solutions Inc.