Page 1 of 1
Windows Changes PHP Files to PDF
Posted: Sat Jun 28, 2014 6:11 pm
by hosedown
Every time I save a file with the extension .php Windows 7 changes it to .pdf. Does anyone know how to remedy this? I did do a search for this problem on this site as well as a general Internet search and I found nothing.
Thanks.
Re: Windows Changes PHP Files to PDF
Posted: Sun Jun 29, 2014 1:12 am
by requinix
Probably because that doesn't really happen. Where are you saving the file from and how are you saving it?
Re: Windows Changes PHP Files to PDF
Posted: Sun Jun 29, 2014 2:34 am
by hosedown
One instance was when downloaded the examples for a PHP text from Apress.com. That was a ZIP and I just clicked on it and it downloaded. Also, anytime I create a notepad doc and save it as title.php and then go to the folder I saved it in, Windows shows it as .pdf
Re: Windows Changes PHP Files to PDF
Posted: Sun Jun 29, 2014 5:22 am
by requinix
hosedown wrote:One instance was when downloaded the examples for a PHP text from Apress.com. That was a ZIP and I just clicked on it and it downloaded.
Not sure where the renaming comes into that. The file would have downloaded as *.zip and I'm 99% sure that they didn't accidentally provide PDFs instead of *.php files.
hosedown wrote:Also, anytime I create a notepad doc and save it as title.php and then go to the folder I saved it in, Windows shows it as .pdf
You remembered to change the "Save as type" to the "All files" option, right? Or alternatively made sure to specify the filename using quotes? If you don't then you'll get files named *.php.txt.
Now to clarify, are you saying that the files
look like they're PDF files? Like the icon? Or are you saying they are actually named *.pdf? What happens when you try to open one?
Re: Windows Changes PHP Files to PDF
Posted: Sun Jun 29, 2014 9:07 pm
by hosedown
When I opened the ZIP file they all looked like PDF files and had the extension .pdf. The files once extracted are the same. I didn't rename anything. When I try to open them, Adobe reader says it can't read them.
For the Notepad docs I did change to All Files and saved them with the extension .php. All I can figure is Windows doesn't know the file type PHP and is going with the alphabetically closest file type it does recognized, which is PDF.
Re: Windows Changes PHP Files to PDF
Posted: Sun Jun 29, 2014 10:28 pm
by requinix
Windows just does not do that. I'd even suggest you may have a virus on your system... except I can't find a mention of such a virus.
Can you post a screenshot?