#25598: support for SCRIPT_NAME for static tag and FileField.url
-------------------------------------+-------------------------------------
     Reporter:  DheerendraRathor     |                    Owner:  nobody
         Type:  New feature          |                   Status:  new
    Component:  Uncategorized        |                  Version:  master
     Severity:  Normal               |               Resolution:
     Keywords:  script_name,         |             Triage Stage:
  static_url, media_url              |  Unreviewed
    Has patch:  0                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------

Comment (by timgraham):

 What I meant was that I don't think Django should automatically use
 SCRIPT_NAME in generating those URLs. If you're running your site on a
 subpath, then you should set your STATIC_URL to
 'http://example.com/subpath/static/' or whatever. However, you might not
 even be hosting static and uploaded files on the same domain as your site
 (in fact, for user-uploaded files, you shouldn't do that
 [https://docs.djangoproject.com/en/stable/topics/security/#user-uploaded-
 content for security reasons]) in which case `SCRIPT_URL` is irrelevant in
 constructing the static/media URLs.

 How would the change make it easier to setup sites?

--
Ticket URL: <https://code.djangoproject.com/ticket/25598#comment:3>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/074.88e8e34ec1716fd56a77a2e9cc774e04%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to