Comments (8)
Just mentioning that I'm only following the README.rst file so far ..
from django-mptt-comments.
Or should I just look at /mptt_comments/templates/*.html and copy things I like? Sorry, don't mean to abuse the Issue tracker here :( I'm just very interested in getting everything to work without making use of Disqus or non-threaded comments. Thanks in any case.
Edit: I've changed 'get_mptt_comments_media' to 'mptt_comments_media' and now I'm not getting the error anymore. Looks like the README.rst file is a tad outdated. However, I'm now getting this error:
Caught KeyError while rendering: 'MEDIA_URL'
It probably has something to do with switching from django 1.2 to 1.3 (which I've just done), but I'm not sure what.
from django-mptt-comments.
Okay so I've added the proper context processor and got rid of the above error, but I'm still getting certain errors like this one for example:
Caught NoReverseMatch while rendering: Reverse for 'django.views.i18n.javascript_catalog' with arguments '()' and keyword arguments '{'packages': u'mptt_comments'}' not found.
Could you do me a huge favor and paste a working settings/manage/urls.py ? Since I'm probably missing some crucial stuff. I promise not to bother you anymore then :)
from django-mptt-comments.
Yup, sorry about the sad state of the documentation. I really need to update it.
First, make sure you are using django 1.3. Django 1.2 is completely unsupported.
Then, you just need the urls.py that's inside the app, plus django.contrib.comments.urls, and this:
url(r'^jsi18n/(?P<packages>\S+?)/$', 'django.views.i18n.javascript_catalog'),
For context processors, here is what we use:
TEMPLATE_CONTEXT_PROCESSORS = (
'django.contrib.auth.context_processors.auth',
'django.core.context_processors.i18n',
'django.core.context_processors.request',
'django.core.context_processors.media',
'django.core.context_processors.static',
)
Note : you'll also need to include jquery in your own base.html to get the javascript working.
from django-mptt-comments.
Okay, almost there then. No problem about the docs, I hate documenting when there's more exiting stuff to do, so I know exactly what you mean.
I have this in my urlconf :
(r'^comments/', include('mptt_comments.urls')),
but how do i include the django.contrib.comments.urls ?
from django-mptt-comments.
You can include it in the same way, in comments/, just make sure to put it below the mptt_comments.urls line. mptt_comments redefines some of the django.contrib.comments urls.
from django-mptt-comments.
Perfect, thanks!
One final question (I really hope you don't mind, you're the only source of help I can find ..). I see a lot of template files and javascript. Are there easy methods of rendering the comments / form / reply-to-comment or do i have to invent my own?
from django-mptt-comments.
The templates that come with the app should be enough to get started. Start with mptt_comments/templates/comments/display_comments_toplevel.html for instance.
Don't hesitate filing bugs or even pull requests for any specific issues you have.
from django-mptt-comments.
Related Issues (4)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from django-mptt-comments.