Tag Archives: Views

Drupal – $data->field_name problem in Views Custom Field

We have talked about using Views Custom Field which really makes Views more versatile. In the custom PHP field, you can get the data of other fields from $data. But the field names under the $data may changed later as you modify the view.

A workaround is to get the field data from $data using the field_id. Continue reading Drupal – $data->field_name problem in Views Custom Field

Drupal – Form Path Problem of Exposed Filter Block in Panel Page

In Views, we can make the exposed filter into block and therefore we can select it for Panel page. But this would not work because after the filter form submission, it will redirect to the view page rather than the current panel page.

Luckily, i found a solution to resolve the issue. Continue reading Drupal – Form Path Problem of Exposed Filter Block in Panel Page

Drupal – Increase Views Relationship Delta Limit

The relationship delta in Views helps you to link a specific referenced node. but it only has 1 to 10 options. I want to increase the delta limit, so let’s hack the CCK module. Yes, the CCK module instead of the Views module. =P

Open cck/includes/views/handlers/content_handler_relationship.inc and modify the $max_delta as follow. Continue reading Drupal – Increase Views Relationship Delta Limit

Drupal – Add Previous and Next Links for Node Navigation

When you are viewing a node, it would be nice to have the previous and next navigation buttons so that you can browse other nodes of the same content type more easily. This is exactly the recent task i need to complete. Luckily i found a very good post showing how to add the navigation buttons in just 2 steps.

1. Add the following function in your theme template.php Continue reading Drupal – Add Previous and Next Links for Node Navigation