Hi I have an issue with Editing and Saving PNG files for use with HTML.
I have PNG files made with PhotoPaint X3 that are linked to in IMG tags or as a background-images in CSS Style sheets. When I open and edit them with X5 the permissions or security changes on the files. If I drop the saved file into a browser the PNG displays fine but opening the HTML or PNG file directly via //localhost naming doesn't work. So I think the IIS Network User doesn't have rights to display the image.
This happens on Windows XP SP3 and on Windows 7 Pro x64. Have I installed it wrong? Is there a setting somewhere or is there a new security model implemented with Corel X5. This happens when creating new content and when saving over existing PNGs.
Any Solutions? Anyone else with the same issue?
EDIT (8 Jul 2010) - In posts below I have tested a few things and in summary, Corel PHOTOPAINT X5 does not preserve existing permissions on files. On saving over or creating new PNG files for example permissions for Everyone and Users are not written to file. Saving over image files in IIS Inetpub folders changes their permissions making them inaccessible via iis requests. This is on Windows 7 x64 Pro, (A toshiba laptop with OEM configured install) and a home made Windows XP SP3, my own OEM install. I don't know if this was the intended file management behaviour but it has slowed me down. And it is different to Corel 10 and Corel X3 which I was using in the past.
EDIT (22 July 2014) - This post relates mostly to Windows Internet Information Server (IIS) folders under C:\inetpub\wwwroot but other windows folders with awkward permissions may suffer the same problems. In windows with IIS installed the INETPUB folders are where you can place HTML files and Image files like PNG, JPG, GIF etc. For IIS to correctly serve these files in a browser - over an HTTP connection - the IUSR and IIS_USER windows users - or some ungodly combination of windows IIS accounts - need to be added to those images and files. Copying already finished images into INETPUB folders via a windows copy-paste operation adds the right IIS users to the files. Editing those images with X5 from the INETPUB folders doesn't preserve the IIS users on Save.
Bottomline - Rob's workaround does the trick!
I've never used IIS, but I've done plenty of development on localhost using apache/php/mysql etc.
When you say 'opening the HTML or PNG file directly via //localhost naming doesn't work' what is actually happening? Is there an error message? Are you sure you are typing the url correctly? Are you sure you're saving or placing the modified png's in the correct location?
I can't see how CorelDraw would have anything to do at all with the permissions of the http server. If viewing the web page in question via localhost works before modifying a png then it should still work after modifying it.
Thanks for the response.
When inside a webpage, like //localhost/virt_dir/page.html as an IMG object I would get the ALT text for the image and when in the CSS as background-image I would get the background-color as it would drop the declaration and fallback or not load an image and fallback. When accessing the image directly ie //localhost/virtdir/image.png I get:
"You are not authorized to view this page"
...
WORKAROUND - Work in a temp Directory, Edit Image, Copy to Web Folders.
I thought I had a solution, I stopped using my virtual directory and dropped the folder into c:\Inetpub\wwwroot and it loaded those PNGs I edited. I also tested GIF files this way and they work. Unfortunately Editing Files from wwwroot still screws permissions so I have a working folder then I copy to my web development folder. This can even be as simple as c:\inetpub\wwwroot\html\img\ copy to c:\inetpub\wwwroot\html\ and back to IMG folder and it works.
This is different to my experience with Corel X3. I am using Windows XP Pro SP3 as an administrator, I will check Windows 7 when I get home.
EDIT WORKAROUND 2 - I shared my virtual folders directory and then created a Mapped Network Drive v: (\\Andrew\VirtDir) so now I can edit and save work off V:\ and it behaves as it did in the past.
Well, in the post above I see the path's aren't the same (unless that's a typing mistake just in the message). It looks like it could just be not finding the file. I'd double check my paths & maybe the case (upper/lower) on file names. I recall some versions of Draw or PP would create files with an upper-case extension like somepic.JPG
Did you create the original files? The only thing I can think of with permissions is that ownership might change if you save-as or create a new version of something. In that case it would be the OS doing it, not the graphic app.
Anyway, glad you found a way to work with it. Can't offer much more since I've never used IIS.
I always have a working folder I use outside the http server for originals & put a copy in the site folder.
Hi, It was a spelling mistake in the post.
I'm not used to Windows 7 Sharing so I haven't got my workaround for win 7. But I have documented the permissions issues in XP in a PDF for anyone interested. It's a half-assed attempt at documenting and I won't update it cause I am moving on but I don't know if this is a bug I should report to Corel so if anyone else can replicate this problem and believes its either by design or omission the wrong behaviour then please post here.
EDIT:
My website folders and image folders in IIS are my development folders and I usually copy to a live server system after I finish all editing and testing. So having a working images folder only to copy to my development website image folders is too much work for me :) But doing this does write the permissions back to the files. I just posted an image which shows the result of saving the same image (I changed the colours) and the resulting permission difference via local addressing or over a network map to the same location. Copying an image file from a work folder with permissions like z0.png and pasting to a development folder changes the permissions to that of z1.png in the image above so that would work too but using a mapped drive avoids the file copying every time I edit a file and need to refresh my browser.
I don't have Win7 so unfortunately I can't pursue it. Hopefully somebody else here will have some ideas & chime in.
It looks like Windows is not happy with you saving directly to c:.. I know Vista is very aggressive as far as 'protecting' what it thinks is system stuff. ie the root of c:, program files & subfolders, etc. , I bet Win 7 is similar. But I don't think XP was that picky & it happened on XP too, so maybe this isn't the problem.