Commits

Yorgos Pagles  committed bb9e7a5

* Changes where only applied to the examples folder

  • Participants
  • Parent commits 85ef1dc

Comments (0)

Files changed (1)

File jquery.pajinate.js

 			nav_label_first : 'First',
 			nav_label_prev : 'Prev',
 			nav_label_next : 'Next',
-			nav_label_last : 'Last'
+		        nav_label_last : 'Last',
+		        nav_display_first_last: true,
+		        nav_label_ellipse : '...'
 		};
 		var options = $.extend(defaults,options);
 		var $item_container;
 			var number_of_pages = Math.ceil(total_items/options.items_per_page);
 			
 			// Construct the nav bar
-			var more = '<span class="ellipse more">...</span>';
-			var less = '<span class="ellipse less">...</span>';
+			var more = '<span class="ellipse more">' + options.nav_label_ellipse + '</span>';
+			var less = '<span class="ellipse less">' + options.nav_label_ellipse + '</span>';
 			
-			var navigation_html = '<a class="first_link" href="">'+ options.nav_label_first +'</a>';
+		    var navigation_html = options.nav_display_first_last ? '<a class="first_link" href="">'+ options.nav_label_first +'</a>' : "";
 			navigation_html += '<a class="previous_link" href="">'+ options.nav_label_prev +'</a>'+ less;
 			var current_link = 0;
 			while(number_of_pages > current_link){
 				current_link++;
 			}
 			navigation_html += more + '<a class="next_link" href="">'+ options.nav_label_next +'</a>';
-			navigation_html += '<a class="last_link" href="">'+ options.nav_label_last +'</a>';
+		    navigation_html += options.nav_display_first_last ? '<a class="last_link" href="">'+ options.nav_label_last +'</a>' : "";
 			
 			// And add it to the appropriate area of the DOM	
 			$nav_panels = $page_container.find(options.nav_panel_id);