cck

Is it safe to modify CCK tables by hand?

I'm not intimately familiar with CCK but I have a one-time custom setup and know that I could get some performance gains if I created indexes and changed the field type and length of some of the fields in my CCK table. Is it save to modify this table at all or will I end up destroying something in the process? Thanks ...

Creating content in a block in Drupal 6

By default for creating content a new page is opened. I want to do this inside a block. A block where there will be some fields like title body taxonomy terms and a create content button. How can I do this? ...

Collapse taxonomy fieldset on node form by default

While creating a (custom) content in Drupal, I have three vocabularies. But these make my create content page very heavy. I want to collapse the Vocubalary fieldset by default and want it to expand only if user chooses to. ...

Changing the Header of a Matrix Table on Drupal CCK.

I have a Matrix Table in a content type on Drupal CCK. That content type also has 5 Node References, I want the headers to be the node references (link to it) I tried adding a JS file that would change the headers automatically But it doesn't submit them, is there an already built solution to this or just some other way? The thir...

Drupal, CCK -- remove draggable reorder for non-admins

Is there a clean way to remove the draggable option on multiple-value CCK fields? I assume I could style it out with CSS but that doesn't seem like the "right" way to do it. Ideally, the draggable option wouldn't be available for any users except admins. Thanks! ...

Theme CCK fieldset.

I am attempting to use the CCK theme_fieldgroup_fieldset($elements) hook to convert the fieldset to a two column layout. I thought that this shouldn't be to hard because the individual fields are in the $elements variable so all I have to do is iterate over them and print them individually. the problem is that I have no way to tell if t...

Fb like share box in drupal website

I am making a drupal website and have a content type "quotation". The standard way of taking input in drupal is going to the create content in the menu which is not very user friendly considering your normal user. I want to have an option to create content (i.e quotation) like in facebook, twitter or any other social networking site. A ...

Why does $form_state['values'] get obliterated in drupal_process_form()?

I'm trying to programmatically store CCK type nodes using drupal_execute(). Empty nodes get created; none of the CCK fields is saved. Evidently the first line in drupal_process_form() is responsible: $form_state['values'] = array(); So my question is why does 'values' get erased, and more importantly, how can I save CCK fields using ...

Drupal 6: how to assign more than 1 imagecache to 1 cck field

Hi friends, I create few imagecache for featured slide img standard listing img details page thumb and original img I need to assign all these imagecaches to 1 image that member upload. so It will create all these images from 1 image upload, and I will use them wherever I need. At cck editing part, I can assign only 1 imagecache :/...

Take data from a field from exsisting node and make that the default value of a field in different content type.

I don't know if I'm on the right track but I'm trying to let users of my web site create there own versions of pages on my web site. Basically I'd like to make our documentation used as a starting point where they just add details and make a new page for themselves in the process. I have a 'book' content type that I have changed with CCK...

Drupal Multiline Title

At the moment I may have a title like Welcome to my new Website made using Drupal This title is splitting onto two lines but I have no control where the break takes place. I would much rather have: Welcome to my new Website made using Drupal To do this I decided the best thing to do is to create a new CCK field to house the title a...

Creating sub-nodes in Drupal from a single node form.

I would like to have a special "sub-node" that could be attached to other Drupal nodes, that allows authors to include commentary (from the author, so this isn't a comment node) and sample text, to the parent node. I plan to use the exact same fields for the author commentary and sample text, and to create a view that lists both togethe...

How-to count nodes based on cck filed data in Drupal

Nodes with cck checkboxes need counting nodes based on cck data and displaing via views field In drupal6 + taxonomy - there is a simple and fast function taxonomy_term_count_nodes() But I`m thinking about d7 without taxonomy via cck custom field Are there any API functions for counting nodes based on CCK fileds ? ...

Drupal 6: how to display cck node fields' values at search result page

Hi friends, I need to display some specific cck fields such as Telephone Number, Address, etc. at search result page. As I see the search-result.tpl.php, there is no $node->... So how can I get the node fields into search result page? Thanks a lot! Appreciate! [SORTED] wow, that simple :) search-result.tpl.php <?php if ($result['...

Problem saving imagefield using hooks in Drupal 6

Here's my custom module; it basically fetches a file from a particular URL, saves it on temporary folder and then i want it to modify a cck field of type 'file' (field name being : field_video_thumb) : function mymodule_nodeapi(&$node, $op) { switch ($op) { case "update": $node->field_video_thumb[0] = f...

Which CCK field properties are shared when using field in different node-types?

Which CCK field properties are shared when using a CCK field-type between node-types? I Ask this question because I wanted to re-use a created field 'date' with another node type. When I altered the date notation to input only the year, suddenly I noticed that only the year was showing with the first node-type I set the Date-field to als...

Weird hierarchical select requirement for Drupal

Anybody know of a module or other way to do a hierarchical select in Drupal that first pulls in a taxonomy vocabulary from which you select and then based on your taxonomy selection limits a CCK related node field to a specific content type. ...

How to embed multiple view blocks into a view block and display them conditionally?

I'm trying to embed multiple view blocks into a single view block. However, I want each of the other views displayed only if they meet certain conditions. What is the best way to do this? Im running Drupal 6 with Views 2 and CCK. ...

Storing external img in Drupal as if it was uploaded by user

I have a scenario where users can upload an image, OR a video (from youtube or vimeo) using CCK via ImageField (Images) & Embedded Media Field (Videos) My site has been using the ImageField images to create thumbnails in various views with imagecache actions. Youtube/vimeo provide an image capture of the video that I want to use as a "...

Key of radio-button into json view

Hi there, I am using the view_datasource module with drupal5 to get a json view. Now I have a cck-field with radio-boxes and want the key to be displayed in the json. However, it always displays the label. My allowed value list: http://dummyimage.com/960x240&amp;text=foo|&lt;img src="http://dummyimage.com/96x24&amp;text=foo"&gt; http:...