[Fixed]-Django: Passing URL parameters to app URL handler

1👍

As the comments have pointed out, the problem is that your project level pattern contains a $ but it should not when using include.

Will the parameters intercepted at the project-level be transmitted to the app-level urls.py to transfer to the placeholder view?

Yes they will. No you shouldn’t do this. It makes it difficult to read/comprehend the urls. It also makes it required that all of the app level included url/views accept the height/width parameters. Currently there is only a single view in your placeholder app but if you added another which didn’t accept these parameters and included it in the placeholder/urls.py it would break in an unexpected way.

Leave a comment