Home > Article > Backend Development > Recommended 10 tutorials on passing parameters in URLs
1 The configuration URL and its view without parameters are as follows: (r'^hello/$', hello) def hello(request): return HttpResponse("Hello World") access http://127.0.0.1:8000/hello, the output result is "Hello World" 2 Pass a parameter to configure the URL and its view as follows, specify a parameter in the URL through regular expression: (r' ^plist/(.+)/$', helloParam) def helloParam(request, param1): return HttpResponse("The param is :
1. Django URL method of passing parameters
Introduction: This article mainly introduces a summary of the method of passing parameters in Django URL. Friends in need can refer to it
Introduction: photoshop cs5 The official Chinese version of the download: photoshop cs5 The official Chinese version of the download PHP paging extension code: Originally published A paging class that is separated from the database. When I used it recently, I found that sometimes when the search items are too large, using the URL to pass parameters may have certain effects or known bugs. This time I have made some extensions. At the same time It is compatible with the previous mode. It is very simple to use the above. You only need to set one more parameter. The code is as follows: Copy the code. The code is as follows:
3. php Pagination Class Extension Code_PHP Tutorial
Introduction: PHP paging class extension code. I originally published a paging class that is separate from the database. When I used it recently, I found that sometimes when the search items are too large, using the URL to pass parameters may have a certain impact
Introduction: form When submitting a form using the Get method, is it not possible to pass parameters through the URL?
Introduction: PHP writes two identical records to the database after passing parameters through url
6. Passing parameters through url What is the reason for the extra characters at the end? Solution
Introduction: What is the reason for the extra characters at the end when passing parameters in url? $prev = $page - 1; echo "Previous page"; As a result, when "Previous Page" is clicked, the url is GET ht
7. Three php functions to parse the url
Introduction: 3 php functions for parsing URLs Passing value through URL is an important means of passing value in PHP. So we need to often parse the parameters in the url. If we know the name of the parameters passed in the url, for example /index.php?name=tank&sex=1#top We can get the transmitted data through $_GET['name'], $_GET['sex']. But what if we don’t know these variable names
8. php paging class extension code
Introduction: php Pagination class extension code. I originally published a paging class that is separated from the database. When I used it recently, I found that sometimes when the search items are too large, using the URL to pass parameters may have a certain impact
9. Three php functions for parsing url
Introduction: Three PHP functions that parse URLs. Passing values through URLs is an important means of passing values in PHP. So we need to often parse the parameters in the url. If we know the name of the parameters passed in the url, such as /index.php?name=tank&sex=1#top, we can pass $_GET['name'], $_GET ['sex'] to get the passed data. But what if we don’t know the names of these variables?
10. What is the reason for the extra characters at the end when passing parameters through url? Solution
#Introduction: What is the reason for the extra characters at the end when passing parameters through URL? HTML code$prev = $page - 1;echo "Previous page";Result click" "Previous page" when the url is GET http://
[Related Q&A recommendations]:
angular.js - angularJs uses ngRoute url to pass parameters problem
javascript - WeChat payment, uses url to pass parameters
The above is the detailed content of Recommended 10 tutorials on passing parameters in URLs. For more information, please follow other related articles on the PHP Chinese website!