[support] help with php in a template

Metzler, David metzlerd at evergreen.edu
Thu Jul 24 15:40:32 UTC 2008


Need more information to help.  Are the podcasts a field in the PDA
content type, or are they adiffent related node? OR are you just
assuming a link convention? 

Need to know more about your setup to answer.  

-----Original Message-----
From: support-bounces at drupal.org [mailto:support-bounces at drupal.org] On
Behalf Of Simone Dal Maso
Sent: Wednesday, July 23, 2008 11:45 PM
To: support at drupal.org
Subject: [support] help with php in a template

Hi,
I'm using the content contemplate module for having different templates
for each type of contents.
I'm not able to write php, so I have a problem...
I have a type of content called "pda". 
Each node is a brief description of a model of PDA.
At the end of the page, I put 2 lines into the template of PDA's type of
content, that are:

<div>
<a href="index.php?q=Ausili/Podcast/
<?php
print $node->nid ?>
"> Download or listen to podcast about <?php print $title ?></a></div>

This lines allow user to see podcast about the PDA that he is reading.
That's ok, but, if there are no podcast about that node, how can I turn
off displaying that link?
so users don't click to see only 2 words like "no podcast for that PDA"!
Thanks in advance.

--
[ Drupal support list | http://lists.drupal.org/ ]


More information about the support mailing list