or
<script>
$(document).ready(
function
(){
var
dataSource =
new
kendo.data.DataSource({
transport: {
read: {
url:
'<?= site_url('
adwords/admin/getKeywordsDetails
') ?>'
,
dataType:
"json"
},
destroy: {
url:
'<?= site_url('
adwords/admin/deleteKeywordDetail
') ?>'
,
dataType:
"json"
,
Type:
"POST"
},
parameterMap:
function
(options, operation) {
if
(operation !==
"read"
&& options.models) {
return
{models: kendo.stringify(options.models)};
}
}
},
pageSize: 50,
autoSync:
true
,
schema: {
model: {
id:
"id"
,
fields: {
id: { editable:
false
, nullable:
true
},
segment: { type:
"string"
},
keyword: { type:
"string"
},
exact_monthly_search_target: { type:
"number"
},
broad_monthly_search_target: { type:
"number"
},
exact_competition: { type:
"number"
},
exact_estimated_avg_cpc: { type:
"number"
}
}
}
}
});
$(
"#keyword_ideas_result_grid"
).kendoGrid({
dataSource: dataSource,
scrollable:
true
,
sortable:
true
,
filterable:
true
,
serverPaging:
true
,
type:
"json"
,
editable: {
update:
false
,
destroy:
true
,
confirmation:
"Are you sure you want to remove this item?"
},
pageable:
true
,
columns: [ {
field:
"segment"
,
title:
"<?= __("
Segment
") ?>"
} , {
field:
"keyword"
,
title:
"<?= __("
Keyword
") ?>"
} , {
field:
"exact_monthly_search_target"
,
title:
"<?= __("
Local Exact
") ?>"
} , {
field:
"broad_monthly_search_target"
,
title:
"<?= __("
Local Broad
") ?>"
} , {
field:
"exact_competition"
,
title:
"<?= __("
Competition Exact
") ?>"
}, {
field:
"exact_estimated_avg_cpc"
,
title:
"<?= __("
CPC Exact
") ?>"
},
{ command:
"destroy"
, title:
" "
, width: 110 }
]
});
});
</script>
// adwords/admin/deleteKeywordDetail
var_dump(
$_GET
);
var_dump(
$_POST
);
var DataSource = new kendo.data.DataSource({
pageSize: 10,
transport: {
read: "data.php",
dataType: "json",
}
sort: { field: "created", dir: "desc" },
});
$("#list").kendoMobileListView({
dataSource: DataSource,
pullToRefresh: true,
appendOnRefresh: false,
endlessScroll: true,
scrollTreshold: 30, //treshold in pixels
style: "inset",
template: $("#list").text()
});
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<
head
>
<
title
>Kendo Link Double Clicking</
title
>
<
script
src
=
"jquery-1.7.2.min.js"
type
=
"text/javascript"
></
script
>
<
script
src
=
"kendo.mobile.min.js"
type
=
"text/javascript"
></
script
>
<
link
href
=
"kendo.mobile.all.min.css"
rel
=
"stylesheet"
type
=
"text/css"
/>
</
head
>
<
body
>
<!-- View 1 -->
<
div
id
=
"one"
data-role
=
"view"
>
<
div
class
=
"km-navbar"
data-role
=
"navbar"
>
<
input
id
=
"searchInput"
type
=
"search"
data-align
=
"left"
placeholder
=
"Search Box"
/>
Page 1
</
div
>
<
br
/>
<
span
>Click the button to be taken to the 2nd page</
span
>
<
br
/>
<
br
/>
<
a
data-role
=
"button"
href
=
"#two"
>Go To Page 2</
a
>
</
div
>
<!-- View 2 -->
<
div
id
=
"two"
data-role
=
"view"
>
<
div
class
=
"km-navbar"
data-role
=
"navbar"
>
<
a
data-role
=
"backbutton"
class
=
"km-button km-back"
href
=
"#:back"
data-align
=
"left"
>Back</
a
>
Page 2
</
div
>
<
br
/>
<
span
>Possible Bug: On a touch device, holding the back button for too long will trigger a double click.</
span
><
br
/>
<
span
>If there is an textbox in the same place on the new page as the button pressed, it will be set into focus.</
span
><
br
/>
<
span
>If there is a soft keyboard, it will also activate.</
span
><
br
/><
br
/>
</
div
>
</
body
>
<
script
type
=
"text/javascript"
>
var app = new kendo.mobile.Application($(document.body));
</
script
>
</
html
>