Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $(".category").select2({
- ajax: {
- url: "/index/getcategory",
- type: 'GET',
- dataType: 'json',
- delay: 250,
- data: function (params) {
- return {
- q: params.term,
- };
- },
- processResults: function (data, page) {
- return {
- results: data.results
- };
- },
- }
- });
Advertisement
Add Comment
Please, Sign In to add comment