Check out pinax/pinax/core/context_processors.py and
https://docs.djangoproject.com/en/dev/ref/contrib/sites/#hooking-into-the-current-site-from-views
You don't need to add SITE_NAME to settings.py, simply create your
site in the database (can use the admin) and set the SITE_ID, also
make sure you are including this context processor in your settings.
TEMPLATE_CONTEXT_PROCESSORS = [
...
"pinax.core.context_processors.pinax_settings",
...
]
On Tue, May 24, 2011 at 18:25, Olx <[email protected]> wrote:
> I had the same issue. So had to add these two fields to settings.py
> and that helped. But agree, would be nice to have these properties
> generated for the project.
>
> On May 6, 1:51 pm, wongobongo <[email protected]> wrote:
>> I'm using:
>>
>> Pinax - 0.9a1
>> Django - 1.2.4
>> django-friends - 0.1.5
>>
>> I'm trying to test the email invitation function (via facebox) which
>> uses django-friends but the following error occurs:
>>
>> AttributeError at /invitations/invite/
>> 'Settings' object has no attribute 'SITE_NAME'
>>
>> /Users/kelvin/envs/visions/lib/python2.5/site-packages/friends/
>> models.py in send_invitation
>>
>> 123. "SITE_NAME": settings.SITE_NAME,
>> 124. "CONTACT_EMAIL": settings.CONTACT_EMAIL,
>>
>> https://github.com/jtauber/django-friends/blob/master/friends/models.py
>>
>> There is also no CONTACT_EMAIL in my settings file. Should I be adding
>> those keys into my setting file? There is also a context processor
>> (pinax/core/context_processors.py) which reads similar keys out of the
>> database.
>>
>> k
>
> --
> You received this message because you are subscribed to the Google Groups
> "Pinax Core Development" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected].
> For more options, visit this group at
> http://groups.google.com/group/pinax-core-dev?hl=en.
>
>
--
You received this message because you are subscribed to the Google Groups
"Pinax Core Development" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/pinax-core-dev?hl=en.