Hi,
I am trying to implement ImageBrowser feature of editor of KendoUI web but not able to make a webmethod call. Since I found sample code for MVC implementation and taken reference of the same but unfortunately not working for me. Below is my code.
HTML:
<textarea id="editor" rows="10" cols="15" style="height:200px">Test</textarea>
JS:
$(document).ready(function () {
$("#editor").kendoEditor({
imageBrowser: {
transport: {
read: {
type: "POST",
contentType: "application/json; charset=utf-8",
url: "ManageNotes.aspx/Read",
dataType: "json"
},
//destroy: {
// url: "http://localhost/editor/service/ImageBrowser/Destroy",
// type: "POST",
// dataType: "json",
// contentType: "application/json"
//},
create: {
url: "ManageNotes.aspx/Create",
type: "POST",
dataType: "json",
contentType: "application/json"
},
//thumbnailUrl: "http://localhost/editor/service/ImageBrowser/Thumbnail",
uploadUrl: {
url: "ManageNotes.aspx/Upload",
//data: "{'type':''}",
type: "POST",
dataType: "json",
contentType: "application/json"
},
imageUrl: "ManageNotes.aspx/Image?path={0}"
}
}
});
});
CS:
[WebMethod]
// [ScriptMethod(UseHttpGet = true, ResponseFormat = ResponseFormat.Json)]
public static void Read(string path)
{
}
Attaching same sample code... Is there anything I'm missing?