Respond problem for upload image
there is an error when parsing the response at grapesjs Which error??? Probably just try to change context.Response.ContentType = "text/plain"; with context.Response.ContentType = "application/json";
Read full answer below βQuestion
I know is an old problem but I have an issue for the respond where I tried to return a response by using asp.net to return a response below is my code(services code to save into directory and return a response): (code in ashx asp.net) context.Response.ContentType = "text/plain"; context.Response.Expires = -1; try { HttpPostedFile postedFile = context.Request.Files[0] as HttpPostedFile; string tempPath = "/uploadImg"; string savePath = context.Server.MapPath(tempPath); string filename = postedFile.FileName; if (!Directory.Exists(savePath)) { Directory.CreateDirectory(savePath); } string path =...
Answers (3)
there is an error when parsing the response at grapesjs
Which error???
Probably just try to change context.Response.ContentType = "text/plain"; with context.Response.ContentType = "application/json";
hi @artf the error is I tried changed the context.Response.ContentType = "application/json"; but still get the above error and my response from service is as below the response get by using Fiddler 4. and I would like to check whether the require response as above because it is weird that response...
Unexpected token E in JSON at position 0 means your response it's not a valid JSON string (which should start, for instance, with { or [ not E, probably there is an Error...). Check the response in your dev tools and you will see it
Related Questions and Answers
Continue research with similar issue discussions.
Issue #2009
'Select' trait no updated in edit mode
Hi there, There is a problem with me, I don't know if it from my code or from grapejs itself, For LINK tool, it takes its links from my DB...
Issue #932
Setting background image results in duplicate style rules
Hi @artf, I have one strange little problem. I have a custom trait which has an implementation for setting images and background images. Wh...
Issue #933
Setting backgroud image results in duplicate style rules
Hi @artf, I have one strange little problem. I have a custom trait which has an implementation for setting images and background images. Wh...
Issue #1026
GrapeJS can't render HTML code
Hi, I intergrated GrapesJS to my application (asp.net MVC) and it works but sometimes GrapesJS can't render HTML. First, I clone html from...
Paid Plugins That Match This Issue
Curated by issue keywords and label relevance to help you ship faster.
Loading paid plugin recommendations...
Check the open-source GrapesJS plugins on GitHub or run a quick search in our free catalog.
Browse free plugins βPremium plugins ship with support, regular updates, and production-ready features β save days of integration work.
Browse premium plugins βRelated tutorials
In-depth guides on the same topic.
Browse Plugin Categories
Jump directly to plugin category pages on the marketplace.