Hi all,
Once again my "related actions" are hidden. This time was contemplate that made it disapear.
I suposse I need to call theme_relativity_links explicitally, but I can imagine how.
Is this function documented any were or is this issue reported and fixed somewere?
Thanks a lot in advance for your unvaluable help,
m.
Comments
Comment #1
mbria commentedThe issue is more critical than I expected.
If you template your cck nodes, all the relativity interface dissapears: no actions shown, but neither related childs or parents.
Once again, thanks for your help,
m.
Comment #2
darius commentedHi Marc,
does this happen only on CCK nodes? Could you write (in point format) exact steps to reproduce the problem?
Darius
Comment #3
mbria commentedAs expected, Darius comes to the rescue. :-)
Thanks a lot for your help.
I made some tests with "normal" nodes as story and it also fails. :-(
Sure.
1) Base: Clean installation of drupal 4.7.2
2) Installation of CCK:
$cvs -z6 -d:pserver:anonymous:anonymous@cvs.drupal.org:/cvs/drupal-contrib checkout -d cck contributions/modules/cck
3) Installation of contemplate:
$cvs -z6 -d:pserver:anonymous:anonymous@cvs.drupal.org:/cvs/drupal-contrib checkout -d contemplate contributions/modules/contemplate
3) Installation of relativity:
$cvs -z6 -d:pserver:anonymous:anonymous@cvs.drupal.org:/cvs/drupal-contrib checkout -d relativity contributions/modules/relativity
4) Creation of a new cck node (add whatever fields you like).
5) Enable relations between new cck nodes and whatever (for instance: their selves).
Until now, with your last patch, everything works perfectly.
6) Playing with contemplate to change the ugly default template for the new node.
You can write "hello world" in the body, just to see what happens.
RESULT: Relativity's actions and related nodes aren't shown. :-(
Note: You can reproduce the problem without creating a new node and installing CCK just playing with "story" node.
I tried to create the template in the "conventional" way... but then I noticed that I would need to call theme_relativity_links() if I wanted to show actions and relations.
I didn't tested with flexinodes, but I suposse the problem will be the same.
Please, let me know if I can make any test, you like to see the issue with your own eyes, or whatever you need me to help to fix this.
Cheers,
m.
Comment #4
darius commentedThis issue turned out to be a feature of contemplate module, not a bug. Some comments:
If you wanted to print the whole body,
<?php print $body ?>wouldprint relativity links, too. If you want to access different body
parts, you will have to call relativity functions explicitly. For
example, to print relativity links, you can use
Now, regarding theming relativity links. Theme overriding is quite easy in Drupal. You can change any
theme_something() function in Drupal without touching the original source code. It depends on what themes you're using, but for PHPTemplate, see http://drupal.org/node/11811. If you were using a PHP
theme (like chameleon), it would be even easier. For overview, see http://drupal.org/node/11774.
You can then modify theme_relativity_link() (or related functions) to
change the way links are rendered. That is the whole idea of theme_...
functions.
Darius