Hi All,
Currently i am working on one jquery plugin. below is the plugin. http://www.jqueryscript.net/other/Easy-Any-Content-Pagination-Plugin-jQuery-Paginate-js.html
using above plugin i have generated the dynamic list of ul using below code.
- function FetchData() {
- $.ajax({
- ......
- success: function (r) {
-
-
- $.each(JSON.parse(data), function (key, result) {
-
- }
- });
- Called Another function for pagination which is as per above plugin.
- SetPaginate();
- }
- });}
-
-
-
-
-
-
- function SetPaginate() {
-
- $('#locationdata').paginate({
- perPage: 20,
- autoScroll: true,
-
- useHashLocation: true
- });
-
- }
-
-
-
- <div class="DivwithScroll" id="divresultdata">
-
- <ul id='example'>
- </ul>
-
- </div>
- <div id="datapager">
-
- </div>
-
-
- <style>
- .DivwithScroll {
- border: 2px solid black;
- background-position: center;
- background-size: cover;
- background-repeat: no-repeat;
- margin: 0 -2px -2px 0;
- height: 360px;
- overflow-y: auto;
- }
- <style>
I am looking data pager of plugin outside ul parent div. have to separate out from plugin. Can anyone help me to seprate out data pager from ul list. in seprate div. I have check paginate js code .
***** js file**** This is some thing code written in js file.
- var paginationHTML = generatePagination();
-
- if($.inArray('top', plugin.settings.paginatePosition) > -1) {
- $element.before(paginationHTML);
- }
-
- if($.inArray('bottom', plugin.settings.paginatePosition) > -1) {
- $element.after(paginationHTML);
- }
-
- ***** Js file code end here ******
Please help me thanks in advance.
Omi....