Image upload issues with upgrade to v6.6

Last post 05-13-2010, 1:41 AM by Kenneth. 14 replies.
Sort Posts: Previous Next
  •  04-20-2010, 2:30 PM 60258

    Image upload issues with upgrade to v6.6

    Hi
     
    I upgraded our installation today to v6.6 from v6.1 I think. After deploying the client files and bin files, I copied back our customized config files in the AutoConfigure and Security folders. When I try to upload an image in Firefox v3.6.3 I get an error that states "Unable to find the uploaded file in directory: C:\WINDOWS\TEMP\". When I try to upload an image in IE 7, I get the error " 

    Server Error in '/Admin' Application.

    Invalid parameter used.

    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

    Exception Details: System.ArgumentException: Invalid parameter used.

    Source Error:

    An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

    Stack Trace:

    [ArgumentException: Invalid parameter used.]
       System.Drawing.Bitmap..ctor(Int32 width, Int32 height, PixelFormat format) +114
       System.Drawing.Bitmap..ctor(Int32 width, Int32 height) +14
       CuteEditor.Dialogs.FileBrowserPage.a(Object A_0, UploaderEventArgs A_1) +1713
       CuteEditor.UploaderBase.OnFileUploaded(UploaderEventArgs args) +21
       CuteEditor.UploaderBase.a(UploaderProvider A_0, UploaderEventArgs A_1) +70
       CuteEditor.UploaderBase.a(String A_0) +438
       CuteEditor.UploaderBase.System.Web.UI.IPostBackDataHandler.RaisePostDataChangedEvent() +65
       System.Web.UI.Page.RaiseChangedEvents() +115
       System.Web.UI.Page.ProcessRequestMain() +1099
    
    "
     
    At this point neither browser can get an image to the server.
     
    Another question is how can I specify an unlimited value for max width, max height and max size (using
    SetSecurityMaxImageDimension(w,h) for example)? I tried "0" but it seems the editor intreprets that literally.
     
     
    Thanks in advance!!
  •  04-20-2010, 6:51 PM 60261 in reply to 60258

    Re: Image upload issues with upgrade to v6.6

  •  04-20-2010, 8:50 PM 60263 in reply to 60261

    Re: Image upload issues with upgrade to v6.6

    Hi Adam
     
    I followed instructions you gave me. I created a TEMP folder in the root of the web directory. I gave both NETWORK_SERVICE and IIS_WPG modify permission on TEMP. I also added the key

    <add key="CuteEditorTempPath" value="~/TEMP"/>

    to the web.config file.
     
     IE 7 works and I can now upload files to the server. However, Firefox is still giving the same error (Unable to find the uploaded file in directory: c:\path_to_web_root\TEMP) but now for the new location I defined in the web.config file (c:\path_to_web_root\TEMP). Any other ideas for Firefox?
     
    I noticed that after uploading a file through IE 7, there is now a file in the TEMP folder named "persisted.33b99221-6898-4c7b-a09d-525b8de50a65.dragon.jpg.resx". I assume the AJAX control doesn't remove the temp files after its done with them? If I want this folder emptied periodically, will I need to write scheduled batch to do this?
     
    Also, any thoughts on my previous question:
    Another question is how can I specify an unlimited value for max width, max height and max size (using
    SetSecurityMaxImageDimension(w,h) for example)? I tried "0" but it seems the editor intreprets that literally.
     
    THANKS!
  •  04-21-2010, 10:15 PM 60294 in reply to 60263

    Re: Image upload issues with upgrade to v6.6

    I still have the issue in Firefox...any ideas?
     
    I found another issue in IE using the Image Editor. When using the ImageEditor I get the error below. Is this "temp folder" configurable in the web.config file like the AjaxUploader? I could give read/write to the path in the error...but I'd rather not.
     
    Thanks!
     

    Server Error in '/Admin' Application.

    Access to the path "C:\Inetpub\wwwroot\path_to_web_root\CuteSoft_Client\CuteEditor\ImageEditor\TempFiles\db4c07ce-c513-4eeb-b496-0f0ba895d934000001-.tmp" is denied.

    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

    Exception Details: System.UnauthorizedAccessException: Access to the path "C:\Inetpub\wwwroot\path_to_web_root\CuteSoft_Client\CuteEditor\ImageEditor\TempFiles\db4c07ce-c513-4eeb-b496-0f0ba895d934000001-.tmp" is denied.

    ASP.NET is not authorized to access the requested resource. Consider granting access rights to the resource to the ASP.NET request identity. ASP.NET has a base process identity (typically {MACHINE}\ASPNET on IIS 5 or Network Service on IIS 6) that is used if the application is not impersonating. If the application is impersonating via <identity impersonate="true"/>, the identity will be the anonymous user (typically IUSR_MACHINENAME) or the authenticated request user.

    To grant ASP.NET write access to a file, right-click the file in Explorer, choose "Properties" and select the Security tab. Click "Add" to add the appropriate user or group. Highlight the ASP.NET account, and check the boxes for the desired access.

    Source Error:

    An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

    Stack Trace:

    [UnauthorizedAccessException: Access to the path "C:\Inetpub\wwwroot\path_to_web_root\CuteSoft_Client\CuteEditor\ImageEditor\TempFiles\db4c07ce-c513-4eeb-b496-0f0ba895d934000001-.tmp" is denied.]
       System.IO.__Error.WinIOError(Int32 errorCode, String str) +393
       System.IO.File.Delete(String path) +165
       CuteEditor.ImageEditor.ApplicationRecords..ctor(String temppath) +48
       CuteEditor.ImageEditor.ImageEditor.OnPreRender(EventArgs e) +1994
       System.Web.UI.Control.PreRenderRecursiveInternal() +62
       System.Web.UI.Control.PreRenderRecursiveInternal() +125
       System.Web.UI.Control.PreRenderRecursiveInternal() +125
       System.Web.UI.Page.ProcessRequestMain() +1499
    


    Version Information: Microsoft .NET Framework Version:1.1.4322.2407; ASP.NET Version:1.1.4322.2407
  •  04-21-2010, 11:08 PM 60295 in reply to 60294

    Re: Image upload issues with upgrade to v6.6

    cw808:
    I still have the issue in Firefox...any ideas?
     
    I found another issue in IE using the Image Editor. When using the ImageEditor I get the error below. Is this "temp folder" configurable in the web.config file like the AjaxUploader? I could give read/write to the path in the error...but I'd rather not.
     
    Thanks!
     

    Server Error in '/Admin' Application.

    Access to the path "C:\Inetpub\wwwroot\path_to_web_root\CuteSoft_Client\CuteEditor\ImageEditor\TempFiles\db4c07ce-c513-4eeb-b496-0f0ba895d934000001-.tmp" is denied.

    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

    Exception Details: System.UnauthorizedAccessException: Access to the path "C:\Inetpub\wwwroot\path_to_web_root\CuteSoft_Client\CuteEditor\ImageEditor\TempFiles\db4c07ce-c513-4eeb-b496-0f0ba895d934000001-.tmp" is denied.

    ASP.NET is not authorized to access the requested resource. Consider granting access rights to the resource to the ASP.NET request identity. ASP.NET has a base process identity (typically {MACHINE}\ASPNET on IIS 5 or Network Service on IIS 6) that is used if the application is not impersonating. If the application is impersonating via <identity impersonate="true"/>, the identity will be the anonymous user (typically IUSR_MACHINENAME) or the authenticated request user.

    To grant ASP.NET write access to a file, right-click the file in Explorer, choose "Properties" and select the Security tab. Click "Add" to add the appropriate user or group. Highlight the ASP.NET account, and check the boxes for the desired access.

    Source Error:

    An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

    Stack Trace:

    [UnauthorizedAccessException: Access to the path "C:\Inetpub\wwwroot\path_to_web_root\CuteSoft_Client\CuteEditor\ImageEditor\TempFiles\db4c07ce-c513-4eeb-b496-0f0ba895d934000001-.tmp" is denied.]
       System.IO.__Error.WinIOError(Int32 errorCode, String str) +393
       System.IO.File.Delete(String path) +165
       CuteEditor.ImageEditor.ApplicationRecords..ctor(String temppath) +48
       CuteEditor.ImageEditor.ImageEditor.OnPreRender(EventArgs e) +1994
       System.Web.UI.Control.PreRenderRecursiveInternal() +62
       System.Web.UI.Control.PreRenderRecursiveInternal() +125
       System.Web.UI.Control.PreRenderRecursiveInternal() +125
       System.Web.UI.Page.ProcessRequestMain() +1499
    


    Version Information: Microsoft .NET Framework Version:1.1.4322.2407; ASP.NET Version:1.1.4322.2407
     
    Hi cw808,
     
    About the firefox issue. Is your site online? If so, please send the test url to me, I will test it and get back to you as soon as possible.
     
    About the ImageEditor issue, please give the full permission to folder "CuteSoft_Client\CuteEditor\ImageEditor\TempFiles" and try again.
     
    When you active the ImageEditor function, it will create a temp file there, so it need the w/r permission too.
     
    Regards,
     
    ken
  •  04-21-2010, 11:39 PM 60297 in reply to 60295

    Re: Image upload issues with upgrade to v6.6

    Hi Ken
     
    I changed the permissions on the temp folder and its working now. Is there any documentation on how to use the AjaxUploader and ImageEditor? Are they configurable? The Image Editor has these images on the right hand side that are draggable. I would like to remove or hide these images and possibly the draggable column.
     
    While the site is online, I can't provide access as its a private extranet for our customer. I can send you anything you need to see on the Firefox issue though. Just let me know what that would be.
     
    I ran into another issue with PDF creation. I have a table with a background image and then a single image in the table cell (see code below). When the PDF is created, only the image in the table cell displays....the background image does not. How can I fix this?
     
    Thanks!
     

    protected string CouponHtmlHeader=@"<table style='border-right: 0px; padding-right: 0px; background-position: center center; border-top: 0px; padding-left: 0px;background-image: url(http://www.glendale-chamber.com/images/coupons/hd_coupon.jpg); padding-bottom: 20px; margin: 0px; border-left: 0px; width: 504px; padding-top: 0px; border-bottom: 0px; background-repeat: no-repeat; height: 504px; text-align: center' height='504' cellspacing='0' cellpadding='0' width='504' align='center' border='0'>"

    +@" <tbody>"

    +@" <tr>"

    +@" <td style='background-position: center center;background-image: url(http://www.glendale-chamber.com/images/coupons/hd_coupon.jpg); text-align: center' valign='middle' align='center' width='504' height='504'>";

    protected string CouponHtmlFooter=@" </td>"

    +@" </tr>"

    +@" </tbody>"

    +@"</table>";

    private void SaveToPdf(string s,string path)

    {

    CuteEditor.Convertor.PDF.HTML2PDF html2pdf=new CuteEditor.Convertor.PDF.HTML2PDF(s);

    html2pdf.Render();

    html2pdf.Save(path);

    }
     

    if(ImageFilePath==string.Empty)

    {

    ImageFilePath=null;

    }

    else

    {

    ImageFilePath=this.CouponHtmlHeader+ImageFilePath+this.CouponHtmlFooter;

    SaveToPdf(ImageFilePath,this.ceFolder+@"\"+Name+".pdf");

    }

     
  •  04-22-2010, 10:58 AM 60314 in reply to 60297

    Re: Image upload issues with upgrade to v6.6

    Hi again
     
    I continued working on the pdf issue and tried it another way. I changed the html defined from above as follows (note: all the other html and code not redefined here is the same as above):

    protected string CouponHtmlHeader=@"<div style='position: relative;'> "

    +@"<img src='http://www.domain.com/images/coupons/hd_coupon.jpg' width='504' height='504' alt='' border='0'>"

    +@"<table height='504' style='position: absolute;top: 0;left: 0;padding-bottom: 20px;border-right: 0px;padding-right: 0px;border-top: 0px;padding-left: 0px;margin: 0px;border-left: 0px;width: 504px;padding-top: 0px;border-bottom: 0px;height: 504px;text-align: center;' cellspacing='0' cellpadding='0' width='504' align='center' border='0'>"

    +@" <tbody>"

    +@" <tr>"

    +@" <td style='text-align: center' valign='middle' align='center' width='504' height='504'>";

    protected string CouponHtmlFooter=@" </td>"

    +@" </tr>"

    +@" </tbody>"

    +@"</table></div>";

     
    So in a web page it displays as:
     
    But the generated pdf looks like:
     
    Its much closer, but still needs to look like the web page. Any ideas on how to mitigate?

    Thanks!
     
     
  •  04-22-2010, 2:16 PM 60323 in reply to 60297

    Re: Image upload issues with upgrade to v6.6

  •  04-22-2010, 5:23 PM 60332 in reply to 60323

    Re: Image upload issues with upgrade to v6.6

    Still no luck rendering the pdf. I did try taking the rendered html and used
    http://www.pdfonfly.com/
     to render a pdf and it looked correct. Not sure thats helpful but it does the render correctly.
    Thanks
     
  •  04-23-2010, 8:29 AM 60349 in reply to 60332

    Re: Image upload issues with upgrade to v6.6

    Hi guys
     
    Any update on the Firefox issue or the PDF issue? My customer is getting increasingly irritated since development has stopped and there hasn't been any update in days.
     
    Any help appreciated
    Thanks!
     
  •  05-04-2010, 1:02 PM 60678 in reply to 60349

    Re: Image upload issues with upgrade to v6.6

    Hi
     
    Any update on any of these issues? Its been over a week and there has been no response or update from CuteSoft. I really need help with this as my customer is at the end of their patience. I don't want to lose them and I don't understand the lack of response to my request.
     
    To summarize, the issues I encounter are:
     
    1. Valid html is not rendered to pdf correctly. Web page displaying html is fine and other pdf conversion utilities render the html fine.
     
    2. Firefox 3.6.3 is throwing an error when trying to upload an image to the server as described above.
     
    Please help
    Thanks
     
     
  •  05-05-2010, 4:09 PM 60755 in reply to 60678

    Re: Image upload issues with upgrade to v6.6

    cw808:
    Hi
     
    Any update on any of these issues? Its been over a week and there has been no response or update from CuteSoft. I really need help with this as my customer is at the end of their patience. I don't want to lose them and I don't understand the lack of response to my request.
     
    To summarize, the issues I encounter are:
     
    1. Valid html is not rendered to pdf correctly. Web page displaying html is fine and other pdf conversion utilities render the html fine.
     
    2. Firefox 3.6.3 is throwing an error when trying to upload an image to the server as described above.
     
    Please help
    Thanks
     
     
     
    For the PDF issue, please wait for the new version.
     
    For the uploader issue, can you provide FTP and testing URL to your site?
     
    Thanks.

    asp.net Chat http://cutesoft.net/ASP.NET+Chat/default.aspx
    Web Messenger: http://cutesoft.net/Web-Messenger/default.aspx
    asp.net wysiwyg editor: http://cutesoft.net/ASP.NET+WYSIWYG+Editor/default.aspx
    asp wysiwyg html editor: http://cutesoft.net/ASP
    asp.net Image Gallery: http://cutesoft.net/ASP.NET+Image+Gallery/default.aspx
    Live Support: http://cutesoft.net/live-support/default.aspx

  •  05-06-2010, 8:27 AM 60773 in reply to 60755

    Re: Image upload issues with upgrade to v6.6

    Hi Adam
     
    For the PDF, what version are you referring to? The next release (eg, v6.7) or the next version (eg v7)? Any ETA?
     
    As I said before on access, this is a customer's extranet with sensitive info. They are not keen on allowing access. I can probably create an unprotected page and provide that. Will that suffice? What exactly do you need ftp access to? I can probably get permission to create a very limited account but I need to know exactly what you need access to.
     
    Let me know these things and I will email you the info.

    Thanks
     
  •  05-12-2010, 11:55 PM 60978 in reply to 60773

    Re: Image upload issues with upgrade to v6.6

    I'm really surprised at the time it is taking to get a response on this...its really disappointing. I know you have other priorities but things really seems to be taking too long. Please support your customer....
    Thanks
     
  •  05-13-2010, 1:41 AM 60980 in reply to 60978

    Re: Image upload issues with upgrade to v6.6

    Hi cw808,
     
    Please create a test page like beow on your site and send the page url to me.
    1. <%@ Page Language="C#" ValidateRequest="false" Debug="true" %>   
    2.   
    3. <%@ Register TagPrefix="CE" Namespace="CuteEditor" Assembly="CuteEditor" %>   
    4. <html>   
    5. <head>   
    6. </head>   
    7. <body>   
    8.     <form id="Form1" runat="server">   
    9.         <CE:Editor ID="editor1" runat="server">   
    10.         </CE:Editor>   
    11.     </form>   
    12. </body>   
    13. </html>  
    And if allow, please set up ftp access for me of your site (maybe I need to upload some new files for test).
     
    You can send  the info to [email protected], I will check it and get back to you  as soon as possible.
     
    Regards,
     
    ken
View as RSS news feed in XML