现在有一个table,带有一个搜索功能。我想问当我搜索了之后,也带有多页的结果,这个时候,我想看第2,第3页等的搜索结果,这个时候,我点击页码,如何处理前端得请求是 不搜索的结果 还是 搜索的 结果呢?
PHP中文网2017-04-18 09:46:40
The plan is as follows:
I don’t know if your search requires the server to provide data
Your problem is how to distinguish whether to maintain the search condition status when clicking pagination. Your question is not clearly described
1. URL passes parameters, and the search condition status must be maintained in the URL link. When js clicks on the next page, when it goes to the server to request
Bring the search conditions, such as?id=2&name='zhangsan', and the server is reading the library When, determine whether there are search conditions
If so, return the search results.