View Full Version : Web Page Pagination
azmanar
04-20-2006, 12:49 PM
Hi,
Is there a way for me to paginate HTML pages which were created on the fly? The HTML pages would be created by populating HTML variables by data sets coming from SQLite , which is done through a FOR-DO loop.
Scenario:
- Say I have 100 records of members in SQLite.
- Then whenever I click a View All button, only 20 members appear on the WebObject. This would be page one. So I have 4 pages more to view.
- The pagination is SET on several LABEL objects just outside the WebObject, at the bottom.
- Therefore the pagination would show something like this, if I'm on page 2, where [2] is NOT an ACTIVE LABEL:
<<PREVIOUS ... [1] [2] [3] [4] [5] ... NEXT>>
As a result, when I clicked on an ACTIVE LABEL, say [3], it will repopulate the WebObject with Record NUMBER 41 to 60. And LABEL [3] will then become INACTIVE. Or I can also click ACTIVE LABEL NEXT>> for the same RECORD series.
Any help, tip, formula or example would be greatly appreciated.
azmanar
04-29-2006, 10:59 AM
Hi,
Okay. I managed to do exactly as I stated above, for Web Pagination on AMS.
But I found out that I need to Auto-EXPAND the area where the Labels are created on the fly if the database is large. So this method is suitable for eBook such as recipes, science and the like, where the number of pages are FIXED at design time. And not suitable for user-definable/writable apps.
Using Listbox Object is a better way of Web Page Pagination.
So I was thinking that if only I can have Object in an Object Plugin. This means to embed Labels inside Shape Plugin and let the Shape autoscroller on when more Labels are inserted. hehehe wishful thinking.
Then, I thought, it would be nice if there is also a Horizontal ListBox. This will fix it and enriches AMS-based developers with even more flexibilty.
Any comments?
Roboblue
04-29-2006, 12:04 PM
Maybe I'm don't have what you want correct in my mind, but could you substitute the Application.ShowpopupMenu for the list box?
it can be populated from a table (text-db, etc).
azmanar
04-29-2006, 01:22 PM
Maybe I'm don't have what you want correct in my mind, but could you substitute the Application.ShowpopupMenu for the list box?
it can be populated from a table (text-db, etc).
Good idea.... this means I can save space using PopUpMenu and have as many LINKS without messing the design. Having it hidden and bringing it up when needed.
And when I need to show lots of stuff in 1 screen, I can use ListBox. This brings the idea of having ComboBox in the middle of <<PREVIOUS n NEXT>>, would be a good substitute to Active Labels and ListBoxes.
Thanks for the spark, Robo...
Now I have many options.
Roboblue
04-29-2006, 01:53 PM
you could also have catagories for your html, then create global popup functions for each catagory, so you could still use popups even if you have a lot of links.
you could use a db and call tables for the catagory to dynamically populate each popup. Use an sVariable to call a menu.
see this simple apz for a basic idea
azmanar
04-29-2006, 02:55 PM
hmmmm ...nice one ..
This means, I am drilling down 1 layer on behalf of users. Making their life much easier..
Really nice one.
Roboblue
04-29-2006, 03:20 PM
Sure
Just populate a popup from the table names (Title) in the db (tables named by catagory). Then when they choose a Title, call another popup populated by the data in the selected table.
You can see how to populate the popup from SQLite from this apz (http://www.indigorose.com/forums/showpost.php?p=80555&postcount=2) (Amanzar, I think you already have this).
Man, if you could only customize the menu (color, transparency, font, etc) this would be a cool looking way to do this. Much cooler than a tree object or listbox.
azmanar
04-29-2006, 03:30 PM
Robo,
Thanks for the pointers. Indeed I have the apz.
I like the idea of controlling the PopUps specs.
In the mean time, maybe I'll upload the Web Pagination with Active Labels for others to refer and hack around. Could be useful.
Powered by vBulletin™ Version 4.0.6 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.