Fixed. After some Google-fu I set SITE_ID = 2 and it worked.

On Monday, January 20, 2014 4:41:05 PM UTC-8, James wrote:
>
> I’m having trouble implementing flatpages in Django 1.5.1 - I’m new to 
> Django/Python (~3 months) so any insight is appreciated.
>
> I’ve added flatpages in APPS and MIDDLEWARE_CLASSES and ran a syncdb:
>
> INSTALLED_APPS = (
>
>     'django.contrib.auth',
>
>     'django.contrib.contenttypes',
>
>     'django.contrib.sessions',
>
>     'django.contrib.sites',
>
>     'django.contrib.messages',
>
>     'django.contrib.staticfiles',
>
>     # Uncomment the next line to enable the admin:
>
>     'django.contrib.admin',
>
>     # Uncomment the next line to enable admin documentation:
>
>     'django.contrib.admindocs',
>
>     'django.contrib.flatpages',
>
>     'blog',
>
> )
>
>
> MIDDLEWARE_CLASSES = (
>
>     'django.middleware.common.CommonMiddleware',
>
>     'django.contrib.sessions.middleware.SessionMiddleware',
>
>     'django.middleware.csrf.CsrfViewMiddleware',
>
>     'django.contrib.auth.middleware.AuthenticationMiddleware',
>
>     'django.contrib.messages.middleware.MessageMiddleware',
>
>     'django.contrib.flatpages.middleware.FlatpageFallbackMiddleware',
>
> )
>
> I logged into Django admin and created:
>
> URL: /about/
>
> Title: About
>
> Content: testing…
>
> Sites:  127.0.0.1:8000
>
> I clicked ‘view on site’ within the Django admin > flatpages > /about/ and 
> I get sent to http://localhost:8000/about/ which returns a 404.  I opened 
> up a SQLite browser and I can see that my page is in the db.  Am I missing 
> anything else?
>
> Thanks
>
> James
>

-- 
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+unsubscr...@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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/b15140af-244f-4fb1-8cae-82058849d0d8%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to