Ver Mensaje Individual
  #1 (permalink)  
Antiguo 18/11/2013, 12:35
Strings
 
Fecha de Ingreso: septiembre-2013
Mensajes: 125
Antigüedad: 10 años, 6 meses
Puntos: 3
He creado mi servidor

Al crear mi servidor y mi pagina se an creado la carpeta "PaginaWeb" dentro estan los archivos

__init__.py
settings.py
urls.py
views.py
wsgi.py

He visto este http://www.forosdelweb.com/3894825-post5.html tutorial para crear mi primer Hola Mundo donde tengo que crear mis archivos

views.py
urls.py

He seguido manteniendo el codigo que tenia en urls.py, solo he añadido el que estaba en el tutorial.

Pero me sale el siguiente error,
Código PHP:
ImportError at /
No module named defaults
Request Method
:    GET
Request URL
:    http://localhost:8000/
Django Version:    1.6
Exception Type
:    ImportError
Exception Value
:    
No module named defaults
Exception Location
:    C:PythonPaginaWebPaginaWeburls.py in <module>, line 14
Python Executable
:    C:PythonPython27python.exe
Python Version
:    2.7.6
Python Path
:    
[
'C:\\Python\\PaginaWeb',
 
'C:\\Windows\\SYSTEM32\\python27.zip',
 
'C:\\Python\\Python27\\DLLs',
 
'C:\\Python\\Python27\\lib',
 
'C:\\Python\\Python27\\lib\\plat-win',
 
'C:\\Python\\Python27\\lib\\lib-tk',
 
'C:\\Python\\Python27',
 
'C:\\Python\\Python27\\lib\\site-packages']
Server time:    Mon18 Nov 2013 19:36:49 +0100 
El codigo del urls.py quedaria asin:
Código Python:
Ver original
  1. from django.conf.urls import patterns, include, url
  2.  
  3. from django.contrib import admin
  4. admin.autodiscover()
  5.  
  6. urlpatterns = patterns('',
  7.     # Examples:
  8.     # url(r'^$', 'PaginaWeb.views.home', name='home'),
  9.     # url(r'^blog/', include('blog.urls')),
  10.  
  11.     url(r'^admin/', include(admin.site.urls)),
  12. )
  13.  
  14. from django.conf.urls.defaults import *
  15. from mysite.views import hello
  16.  
  17. urlpatterns = patterns('',
  18.     ('^hello/$', hello),
  19. )