This forum is for module development and code related questions, not general module support. For general support, use the Post installation forum.

Contemplate and CCK

Hi there

First up let me apologise for being a JSP guy who has just encountered PHP. So I don't know much and have all sorts of assumptions getting in the way.

I am trying to create custom nodes using CCK and to present those nodes nicely using contemplate. There are two types of custom nodes, ads and ad categories. Each ad category will contain a bunch of ads. The thing is that each ad has a picture, and I want to display the full picture in each ad and a thumbnail in the ad categories page. At present the picture in the ad page is a nodereference field type, that points to an image (image module). So it simply displays in the ad page, as a text link to the image page .

I thought that by using contemplate I could show the picture by tweaking the template for the ad custom node type, and do something similar to show thumbnail images in the ad category.

So That is what I am trying to do. However the only output that seems to work from the contemplate template is $item['view']
If I try anything like $item['title'] or $item['field_picture_0'][0] I get no output. To put it another way, I am trying to display members of a contained node, and the only thing that works is ['view'] which gives me a text link.

I suspect I am probably really barking up the wrong tree. Can I do what I want to do using CCK and Contemplate?

Is there a more direct way of achieving what I am trying to do?

Help test the new banner module

I'm putting the final touches on my update of the banner module (the current CVS version is simply the old banner module updated to use the form API).

New features:

image module & access

I want to make image module coplately unreachable by anonymous users...

image module has this codes for permissions and i tried to add "view images" condition but i could not get it working right... How can i do this? thanks.

Movie Upload Problems, Acidfree

I want every movie to be the same size, width 425 hight 350 how do i fix this? And I also cant get the autothumbnail to work with the movies.

Here is a movie: http://bikerpunks.com/node/46

I want to be able to upload movies and have them all the same size. How can I make this happen?

Help.. Error on my ecivicrm.module

Fatal error: Call to undefined function civicrm_initialize() in E:\XAM\xampp\htdocs\petmate\modules\ecommerce\contrib\ecivicrm\ecivicrm.module on line 181

help.. error... i dont know why..

Q: Can't Do PHP Functions with CCK?

I am using the CCK module and have created a custom node type and given it a textarea field. When I set this field to php and print something like:

//truncate text
function test() {
print 'hello';
}
print test();

It just goes blank and nothing shows up at all. If I paste this exact code into my 'page' node type it works.

Any ideas?

Pages

Subscribe with RSS Subscribe to RSS - Module development and code questions