The shortcomings of << improving the performance >> of dynamic Paging in ASP and suggestions for amendment
Source: Internet
Author: User
The shortcomings of << improving the performance >> of dynamic Paging in ASP and suggestions for amendment
Oh, can enter the essence area? It took me a day.
Two brother Zhang << improve the performance of dynamic pagination in ASP >> I am very inspired by the article, but there are some deficiencies in my thinking.
One is unable to respond to some updates with the information.
Add now is a BBS, then the information updated at any time has
Click on each posting
New post information, these in the two Brother Brother's scheme can not be automatically updated, only users can change the query to use.
Second, the memory used too much, in fact, for a forum, most people still in order to visit, there is no need for everyone a session.
Third, the processing of data is not convenient
It can only be done in array mode, not intuitive, poor readability.
For the above points, I propose the following improvement plan
The use of application can be used to achieve multiple people using the same data
Two only save and retrieve ID number, other data make second select
Three automatically deletes obsolete application to save memory.
Iv. re-import data when adding and deleting data
Other benefits
Oh, you can use the GetString (), the original pagination does not
You can use 1, 3,
The code is as follows
A_page.asp
-----------------------------------------------------------------'
<%
Dim apage_pagesize ' Number of records per page
Dim apage_count ' Total Record count
Dim Apage_pagecount ' Total Pages
Dim apage_pageform ' Jump page with form
Dim apage_pageurl ' Previous Page next page link
Dim apage_timeout ' Expiration Time setting (seconds)
apage_timeout=300 ' Expiration Time set (SEC)
Apage_pagesize=20 '
function apage_bactive (str_name) ' To determine if there is this object and to delete expired objects
Apage_bactive=false
Dim Item, S_temp
For Item=1 to Application.contents.count ' Find out all application
S_temp=application.contents (item)
If IsArray (s_temp) Then
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service