for your case, site1 and site2 are two isolate webserver, correct?
Will all the files under both of these directories open to public once the server is up and running?
Is the article from the tutorial suggest to have .py files store in some other place to avoid it being see by visitors online?
So the framework could just import scripts from designated place through PYTHONPATH even when the scripts are not placed within site1 or site2?
Thank you for such a quick response especially to my extremely novice question.
I hope I would learn a lot from this community, thank you very much
Lachlan Musicman於 2016年4月27日星期三 UTC-7下午6時57分26秒寫道:
L.CheersAt a later point, you will need to set up your webserver to read from that directory./home/lachlan/www/site1I normally create a folder in my home dir called www and place my sites within thatThis will be defined in the webserver (apache2/httpd, nginx, etc) configuration.Mie,Traditionally the document root to your webserver is (depending on your system) /var/www.
/home/lachlan/www/site2------
The most dangerous phrase in the language is, "We've always done it this way."
- Grace HopperOn 28 April 2016 at 11:25, Mie Rex <rexm...@gmail.com> wrote:Hello everyone, I am new to Django and quite new to Python as well.--I came across this advice while I'm going through the Django tutorial hereIt mentioned "It's not a good idea to put any of this Python code within your Web server's document root..."My very newbie question is: what's document root of web server?I have no knowledge in building a web site so please forgive my very shallow question.Cheers
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users...@googlegroups.com .
To post to this group, send email to django...@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users .
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/0d8833ce- .1623-4811-836a-d82a1cc39ee9% 40googlegroups.com
For more options, visit https://groups.google.com/d/optout .
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/9f33413c-5f4c-42c3-9d87-b4ac494f6508%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
No comments:
Post a Comment