Skip to main content
Post Closed as "Needs more focus" by avpaderno
edited tags
Link
avpaderno
  • 97.9k
  • 15
  • 164
  • 284
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
removed "Drupal" from the title; removed tags from the title
Link
avpaderno
  • 97.9k
  • 15
  • 164
  • 284

When todo I use views_get_view_result Drupal 7()?

Source Link

When to use views_get_view_result Drupal 7

I have basic listing in a View. I can give styles, or unformatted text, provide a link, etc. However, I would need the listing to be a list of linked items, with the destination URL changing depending on context: language, type of user, etc. So I just retrieve the listing with a view, and in the template, I use views_get_view_result to print the fields I need and warp them with the necessary parameters (the dynamic URL, etc.). Is that a good approach or could this be achieve through the config of the View or with aid of another module (Context, Context Views, whatever...). Thanks!