We are using AjaxControlToolkit 4.1 version from past 4 years. We are uploading files using ajaxfileupload control. When we upload files the request will got to Apache Tomcat server with the application URL and by default adding two parameters in the query
string contextkey and guid automatically.
The two parameters in the URL ContextKey and guid is automatically appended by ajax and the request is sent. The user can't see contextkey={DA8BEDC8-B952-4d5d-8CC2-59FE922E2923}&guid=B943E2E3-A536-80BC-F364-E5C39377704A in the URL. The above URL mentioned
in the example is given by the server team. They are telling to encode the { and } and send it but i am not sure how to do that..
When i Check AjaxFileUpload.cs page there is one line
internal const string ContextKey = "{DA8BEDC8-B952-4d5d-8CC2-59FE922E2923}";
Can i know what does this mean and whether the above constant can be without { and }
Now the problem is they (server team) is telling they won't accept { and } characters. The files are not getting uploaded.
Can you please help me as this is very urgent for me to fix it.
OR
Can i have the AjaxControlToolkit 4.1 version code so that i can remove { and } in the const ContextKey and rebuild the code and use that updated dll so that the { and } characters will not be available in the ContextKey param value.
MSDN Community Support
Please remember to click "Mark as Answer" the responses that resolved your issue.
If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.
The ContextKey and guid paramaters will be generated by the ajaxcontroltoolkit automatically. We don't have control and this url is given by the server team.
As an user we will see till Upload.aspx only in the browser URL.
None
0 Points
9 Posts
AjaxFileUplaod control not uploading files due to { and } characters present in the ContextKey pa...
Feb 21, 2018 09:54 AM|nkaryala|LINK
We are using AjaxControlToolkit 4.1 version from past 4 years. We are uploading files using ajaxfileupload control. When we upload files the request will got to Apache Tomcat server with the application URL and by default adding two parameters in the query string contextkey and guid automatically.
For example the url will look like this:
https://reality.alcatel-lucent.com/rsp/action/app/mtap6/MTAPServer/Upload/Upload.aspx?contextkey={DA8BEDC8-B952-4d5d-8CC2-59FE922E2923}&guid=B943E2E3-A536-80BC-F364-E5C39377704A
The two parameters in the URL ContextKey and guid is automatically appended by ajax and the request is sent. The user can't see contextkey={DA8BEDC8-B952-4d5d-8CC2-59FE922E2923}&guid=B943E2E3-A536-80BC-F364-E5C39377704A in the URL. The above URL mentioned in the example is given by the server team. They are telling to encode the { and } and send it but i am not sure how to do that..
When i Check AjaxFileUpload.cs page there is one line
internal const string ContextKey = "{DA8BEDC8-B952-4d5d-8CC2-59FE922E2923}";
Can i know what does this mean and whether the above constant can be without { and }
Now the problem is they (server team) is telling they won't accept { and } characters. The files are not getting uploaded.
Can you please help me as this is very urgent for me to fix it.
OR
Can i have the AjaxControlToolkit 4.1 version code so that i can remove { and } in the const ContextKey and rebuild the code and use that updated dll so that the { and } characters will not be available in the ContextKey param value.
Thanks in advance!!!
Contributor
6730 Points
2715 Posts
Re: AjaxFileUplaod control not uploading files due to { and } characters present in the ContextKe...
Feb 22, 2018 08:17 AM|Eric Du|LINK
Hi nkaryala,
According to your description and issue, i think you could encode the whole URL directly, for more details, please check the following tutorials:
HttpServerUtility.UrlEncode Method (String):
https://msdn.microsoft.com/en-us/library/zttxte6w%28v=vs.110%29.aspx?f=255&MSPPError=-2147217396
ASP URLEncode Method:
https://www.w3schools.com/asp/met_urlencode.asp
Best Regards,
Eric Du
Please remember to click "Mark as Answer" the responses that resolved your issue.
If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.
None
0 Points
9 Posts
Re: AjaxFileUplaod control not uploading files due to { and } characters present in the ContextKe...
Feb 23, 2018 07:53 AM|nkaryala|LINK
Hi,
The ContextKey and guid paramaters will be generated by the ajaxcontroltoolkit automatically. We don't have control and this url is given by the server team.
As an user we will see till Upload.aspx only in the browser URL.