I’m just starting to use the comments extension and I followed the
instructions that ere there in messages here and there and it works
fine. (I’m going to compile it for Summer Reboot soon).
There is just one thing that comes up. Both versions (ntalbott and
artofmission) make a clear note saying:
Relative urls will not work on comment pages if they fail validation,
since the page gets re-rendered at a (probably) different level of the
hierarchy. Always use absolute urls and you won’t have any issues.
But, I find that when the form is submitted with a comment, it usually
directs to a page like:
http://localhost:3300/en/my_page/comments#comment-4
On this page also, I get errors like:
undefined method `relative_url_root’ for nil:NilClass
”>Concepts
On the other hand, the main page http://localhost:3300/en/my_page/ works
just fine!
[1] I’m wondering what is the recommended approach to prevent this from
happening (other than relative URLs being avoided) since my pages are
connected to one another using things like <r:children:each> and one of
the good things with the CMS is the ability to not have to use hard
coded absolute links.
[2] If I were to try to change this behaviour, where in the code should
I look? For example, if I wanted to change the display of the page
details and the comment together (which causes the above issue
specifically) or to look for a better generic solution (though I’m not
sure I’d be able to find one).
[3] Finally, I find that in the admin UI, when I click to view the
comments, quite often, the HTML is all messed up for the page (e.g. the
headings and fonts are larger than the regular Radiant admin UI). Any
one else noticed that? I haven’t investigated this enough, so I’m not
yet sure why that happens.
Thanks
Mohit.