or
[ { "id": 1, "email": "xxx@hotmail.com", "first_name": "Nellie", "last_name": "Bogan" }, { "id": 2, "email": "xxx@stammfunk.com", "first_name": "Jaida", "last_name": "West" }, { "id": 3, "email": "xxx@yahoo.com", "first_name": "Vito", "last_name": "Ortiz" },$transport = new \Kendo\Data\DataSourceTransport();$read = new \Kendo\Data\DataSourceTransportRead();$read->url('/data/users')->contentType('application/json')->type('POST');$transport ->read($read)->parameterMap('function(data) {return kendo.stringify(data);}');$model = new \Kendo\Data\DataSourceSchemaModel();$contactFirstNameField = new \Kendo\Data\DataSourceSchemaModelField('first_name');$contactFirstNameField->type('string');$contactLastNameField = new \Kendo\Data\DataSourceSchemaModelField('last_name');$contactLastNameField->type('string');$contactEmailField = new \Kendo\Data\DataSourceSchemaModelField('email');$contactEmailField->type('string');$contactIdField = new \Kendo\Data\DataSourceSchemaModelField('id');$contactIdField->type('number');$model->addField($contactFirstNameField)->addField($contactLastNameField)->addField($contactEmailField)->addField($contactIdField);$schema = new \Kendo\Data\DataSourceSchema();$schema->data('data')->errors('errors')->groups('groups')->model($model)->total('total');$dataSource = new \Kendo\Data\DataSource();$dataSource->transport($transport)->pageSize(10)->serverPaging(true)->serverSorting(true)->serverGrouping(true)->schema($schema);$grid = new \Kendo\UI\Grid('grid');$first_name = new \Kendo\UI\GridColumn();$first_name->field('first_name')->title('First Name')->width(140);$last_name = new \Kendo\UI\GridColumn();$last_name->field('last_name')->title('Last Name')->width(190);$email = new \Kendo\UI\GridColumn();$email->field('email')->title('Email');$id = new \Kendo\UI\GridColumn();$id->field('id')->title('ID')->width(110);$pageable = new Kendo\UI\GridPageable();$pageable->refresh(true)->pageSizes(true)->buttonCount(5);$grid->addColumn($first_name, $last_name, $email, $id)->dataSource($dataSource)->sortable(true)->groupable(true)->pageable($pageable)->attr('style', 'height:380px');?><div id="clientsDb"> <?php echo $grid->render(); ?></div><style scoped> #clientsDb { width: 952px; height: 396px; margin: 20px auto 0; padding: 51px 4px 0 4px; }</style>@(Html.Kendo().Editor().Name("Editor").Tools(tools => tools .Clear() .Bold().Italic().Underline().Strikethrough() .JustifyLeft().JustifyCenter().JustifyRight().JustifyFull() .InsertUnorderedList().InsertOrderedList() .Outdent().Indent() .CreateLink().Unlink() .InsertImage() .InsertFile() .SubScript() .SuperScript() .TableEditing() .ViewHtml() .CleanFormatting() .Formatting() .FontName() .FontSize() .FontColor(color => color.Palette(new string[] { "#ffffff", "#000000", "#e7e6e6", "#44546a", "#5b9bd5", "#ed7d31", "#a5a5a5", "#ffc000", "#4472c4", "#70ad47", "#f2f2f2", "#7f7f7f", "#d0cece", "#d6dce4", "#deebf6", "#fbe5d5", "#ededed", "#fff2cc", "#d9e2f3", "#e2efd9", "#d8d8d8", "#595959", "#aeabab", "#adb9ca", "#bdd7ee", "#f7cbac", "#dbdbdb", "#fee599", "#b4c6e7", "#c5e0b3", "#bfbfbf", "#3f3f3f", "#757070", "#8496b0", "#9cc3e5", "#f4b183", "#c9c9c9", "#ffd965", "#8eaadb", "#a8d08d", "#a5a5a5", "#262626", "#3a3838", "#323f4f", "#2e75b5", "#c55a11", "#7b7b7b", "#bf9000", "#2f5496", "#538135", "#7f7f7f", "#0c0c0c", "#171616", "#222a35", "#1e4e79", "#833c0b", "#525252", "#7f6000", "#1f3864", "#375623", "#c00000", "#ff0000", "#ffc000", "#ffff00", "#92d050", "#00b050", "#00b0f0", "#0070c0", "#002060", "#375623", })) .BackColor(color => color.Palette(new string[] { "#ffffff", "#000000", "#e7e6e6", "#44546a", "#5b9bd5", "#ed7d31", "#a5a5a5", "#ffc000", "#4472c4", "#70ad47", "#f2f2f2", "#7f7f7f", "#d0cece", "#d6dce4", "#deebf6", "#fbe5d5", "#ededed", "#fff2cc", "#d9e2f3", "#e2efd9", "#d8d8d8", "#595959", "#aeabab", "#adb9ca", "#bdd7ee", "#f7cbac", "#dbdbdb", "#fee599", "#b4c6e7", "#c5e0b3", "#bfbfbf", "#3f3f3f", "#757070", "#8496b0", "#9cc3e5", "#f4b183", "#c9c9c9", "#ffd965", "#8eaadb", "#a8d08d", "#a5a5a5", "#262626", "#3a3838", "#323f4f", "#2e75b5", "#c55a11", "#7b7b7b", "#bf9000", "#2f5496", "#538135", "#7f7f7f", "#0c0c0c", "#171616", "#222a35", "#1e4e79", "#833c0b", "#525252", "#7f6000", "#1f3864", "#375623", "#c00000", "#ff0000", "#ffc000", "#ffff00", "#92d050", "#00b050", "#00b0f0", "#0070c0", "#002060", "#375623", }))).Encode(false).Value(@<text> <p> Kendo UI Editor allows your users to edit HTML in a familiar, user-friendly way.<br /> In this version, the Editor provides the core HTML editing engine, which includes basic text formatting, hyperlinks, lists, and image handling. The widget <strong>outputs identical HTML</strong> across all major browsers, follows accessibility standards and provides API for content manipulation. </p> <p>Features include:</p> <ul> <li>Text formatting & alignment</li> <li>Bulleted and numbered lists</li> <li>Hyperlink and image dialogs</li> <li>Cross-browser support</li> <li>Identical HTML output across browsers</li> <li>Gracefully degrades to a <code>textarea</code> when JavaScript is turned off</li> </ul> <p> Read <a href="http://docs.telerik.com/kendo-ui">more details</a> or send us your <a href="http://www.telerik.com/forums">feedback</a>! </p></text>).ImageBrowser(imageBrowser => imageBrowser .Image("~/Content/UserFiles/Images/{0}") .Read("Read", "ImageBrowser") .Create("Create", "ImageBrowser") .Destroy("Destroy", "ImageBrowser") .Upload("Upload", "ImageBrowser") .Thumbnail("Thumbnail", "ImageBrowser")).FileBrowser(fileBrowser => fileBrowser .File("~/Content/UserFiles/Images/{0}") .Read("Read", "FileBrowser") .Create("Create", "FileBrowser") .Destroy("Destroy", "FileBrowser") .Upload("Upload", "FileBrowser"))).k-colorpalette{ border: 1px solid gray; padding-right: 3px;}.k-palette .k-item{ border-style: solid; border-color: White; border-width: 0px 3px 0px 3px;}.k-palette tr:first-child{ border-top: 3px solid white; border-bottom: 5px solid white;}.k-palette tr:last-child{ border-top: 5px solid white; border-bottom: 3px solid white;}class MyViewModel extends kendo.data.ObservableObject { items: kendo.data.DataSource; constructor(myItems: kendo.data.DataSource) { super(); super.init(this); this.items = myItems; } addToCart(e): void { alert("Hello There!"); }}var myData: Array<any> = [ { "id": 1, "name": "Sashimi salad", "price": 12.0, "image": "http://demos.telerik.com/kendo-ui/content/spa/websushi/images/200/sashimi-salad.jpg", "category" : "Cold starters", "description" : "Organic greens topped with fresh sashimi, wasabi soy vinaigrette.", "featured" : true }, { "id": 2, "name": "Chirashi sushi", "price": 21.0, "image": "http://demos.telerik.com/kendo-ui/content/spa/websushi/images/200/chirashi-sushi.jpg", "category" : "Cold starters", "description" : "Sushi bar variety with sushi rice.", "featured" : false}];var myItems = new kendo.data.DataSource({ schema: { model: {} }, data: myData });var viewModel: MyViewModel = new MyViewModel(myItems);var myView = new kendo.View("index-template", { model: viewModel });myView.render($("#application"));<script type="text/x-kendo-template" id="index-template"> <ul data-role="listview" data-bind="source: items" data-template="item" id="main"></ul> </script><script type="text/x-kendo-template" id="item"> <li class="products"> <a class="view-details" href="\#"> <img class="main-image" src="#= image #" alt="#: name#" title="#: name #" /> <strong data-bind="text: name"></strong> <span class="price"><span>$</span><span data-bind="text: price"></span></span> </a> <button class="add-to-cart" data-bind="click: addToCart">Add to cart</button> </li></script><div id="application"></div>var indexModel = kendo.observable({ items: myItems, addToCart: function (e) { alert("Hello There!"); }});