DASHA
This commit is contained in:
		
							
								
								
									
										15
									
								
								Параметры маршрута/app.js
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										15
									
								
								Параметры маршрута/app.js
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,15 @@ | ||||
| const express = require('express'); | ||||
| const app = express(); | ||||
|  | ||||
| app.get('/book/:pageName.:pageExt', function ( | ||||
|     request, | ||||
|     response | ||||
| ) { | ||||
|     let pageName = request.params['pageName']; | ||||
|     let pageExt = request.params['pageExt']; | ||||
|     response.send( | ||||
|         `Запрошенный файл: ${pageName}.${pageExt}` | ||||
|     ); | ||||
| }); | ||||
|  | ||||
| app.listen(3000); | ||||
		Reference in New Issue
	
	Block a user
	 User1
					User1