Tuesday, July 2, 2013

Re: Getting URL root

On 2/07/2013 5:07pm, Larry Martell wrote:
> I need to get it from a standalone program. It's a django script, but
> not invoked from a request.

import socket
def get_fully_qualified_domain_name():
return socket.getfqdn()

--
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 http://groups.google.com/group/django-users.
For more options, visit https://groups.google.com/groups/opt_out.

No comments:

Post a Comment