Tag Archives: Views Custom Field

Drupal – Show a node location with Google Map in Views

We could add location information to node using the Location module. If the GMap module is enabled, we could even show the location with Google Map in Views.
1. Download and enable the GMap module.
 

2. Edit the Locative information of any content type. Make sure the Coordinate Chooser is set to Allow. Continue reading Drupal – Show a node location with Google Map in 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 – Sharing data across fields in the same row with Views Custom Field

We have talked about the Views Custom Field module previously. If you have no idea what is it for, you can take a look @ Drupal – Custom PHP code for Views Field.

Sometimes we may need to get a full node using Views Custom Field. For example, i want to get the number of images of a node. Continue reading Drupal – Sharing data across fields in the same row with Views Custom Field