Hi!

I made a block view, that displays only for some kind of content (e.g. article), so on the pages whose addresses are /articles/any_article.
I made a page view that lays underneath an article content (e.g. at /articles/any_article/my_view) and that uses "any_article" as argument to display things related to "any_article".

I would like to place a link in the header or footer of the block view, that links to the view at ./my_view
I can't manage that... using href="my_view" or href="./my_view" or any token like "[node:nid]" or "[node:url]" doesn't work :
- "my_view" links to root_url/my_view (is that considered as a bug?)
- the token are not replaced (or the tokens of the first row are used if the corresponding box is checked)

Thanks!

Comments

Grumot’s picture

Priority: Normal » Minor

I circled the problem by using the "more" link in the block view and a "node/%/my_view" address for the page view.

If somebody would ever solve the previous problem, I am nevertheless interested!

dawehner’s picture

- "my_view" links to root_url/my_view (is that considered as a bug?)

Not really because this is how html works if you have a relative path.

You could use a custom area handler which allows you then to add any kind of custom stuff into the header if you want.
Sadly this isn't documented that well at the moment.

Grumot’s picture

Hi Dereine,
Thanks for your answer

You could use a custom area handler

Is it php in any case, thus?

dawehner’s picture

Yes it is.

dawehner’s picture

Category: bug » support
Status: Active » Fixed

That's actually more of a support question.

Mark as fixed because of no response from the author.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

hedel’s picture

Issue summary: View changes

Just for future readers - there is Views link area module:

The Link Area module provides an "area plugin" for Views 3. It allows customized links to be placed in the header, footer, or empty text of any view.
The obvious use case is to create a list of all nodes of type "foo" and then add a header link to the node/add/foo page. By making it a real link rather than just a blob of HTML in a header text area it gets all of the special handling and clean URL friendliness and base-path portability that any Drupal link gets.