Views Dynamic title
tristanmatthews - March 17, 2009 - 20:52
Hi all,
So I feel like this should be really easy to do, or at least I did when I started trying hours ago, but I may be wrong.
So I have a view the displays a recipe that a user has entered. Is there a way to set the Basic Setting: Title to be the Node: Title?
I think I'm just not seeing where this is set and the header is built.
Thanks,
Tristan

Are you saying a single
Are you saying a single recipe? Why not just display at node/{nid} where {nid} is the node id?
Titles
I think (and I'm just THINKING here) that setting the Title in Basic Settings: Title Gives you a fixed title. You could name it "Recipes" and if you print 10 recipes, this would be the header. If you are trying to get 10 recipes and each one to have the dynamic title, you might want to include the Node: Title as a field -- along with whatever else you are displaying. So each of the 10 would be Titled"Spinach Pie" "Beef Stew" etc.
Capiche?
Kind of
So I have the node title field included, but I can't see how to set the basic setting of title to the value of the field for each recipe. So I can call it Recipes and they are all called that, and then do a title under it with "spinach pie", but I feel like it would be much cleaner if I could set the title to the node title for all of them. That way you not only "spinach pie" on the page, but as the page title and so forth.
One more thing
One more thing that might help....
The default display in views is just a node. Look along the left edge of the window and add or see if there is a "Page" view. You may only be looking at the node view. (I don't know how much I am helping as I am a Views novice myself.)
Nope, its a page
Thanks mcfilms, but its a page already.
A lot of the fields can do things with string replace like use [title] to insert the title, but that doesn't seem to work with the basic settings, so who know. I'm sure I'll figure it out...
It really seems like you want
It really seems like you want to list nodes not fields.
That said, if you add "Node: title" as a field it displays the label (Title by default) and the title for the current node so am no sure what "So I can call it Recipes and they are all called that, and then do a title under it with "spinach pie"," refers to.
As for "That way you not only "spinach pie" on the page, but as the page title and so forth." once again it sounds like you are trying to display a single node (not a list) in which case using the nodes path may be more appropriate.
Node Path
Hi Nevets,
Thanks for the replay, and yes I am just displaying a single node worth of data, but I'm using a some of views features for the display, and what fields are shown. Since I have a number of ways to look at each recipe based on who you are and how you get there this seemed like the easiest thing to do.
So when I set the basic settings title it displays at the top of the main content part of the page, in the title tag, in the header, and in the bread crumbs trail. It looks like there was a "not to bad" way to do set the title tag, and bread crumbs with views 1, but I can't figure out how to do it in views 2, with out using the basic settings.
Why not use CCK permissions
Why not use CCK permissions to determine who can view what fields and/or theming in node-{content_type}.tpl.php (replace {content_type} with your content type), this seems easier to me.
To each his own...
Besides, I can think of an number of other reason I would want to be able to do this, so...
I think he meant html page
I think he meant html page title.
I'm rather late for you...lol
But this is what I followed to accomplish exactly what you are talking about.
http://www.davidnewkerk.com/book/18
I just replaced the word Articles with Recipes
Now I'm trying to take it a step further, which looks like others are interested as well: http://drupal.org/node/612468
Dynamic Views Page Title
I don't know if this is the right one but I think we share the same problem. I have a view that has a static title. I also have a taxonomy term which is based on views. What I want, is when I click on the taxonomy term I would also get that taxonomy term as the title on the page view.
How can I do this?
looking for the same
looking for the same
Subscribing
Subscribing
me too! This shouldn't be too
me too! This shouldn't be too hard given that it's possible to use the replacements like [fieldname] almost everywhere else.. then why not in the title.
Thanks!
subscribing
subscribing
I'm looking in to some custom code to get this done.
See you at the The Do It With Drupal Seminar
Learn from the Lullabot Drupal Video Series
- Doug Vann
- http://www.dougvann.com My Blog
- http://www.twitter.com/dougvann Twitter Me
- http://www.facebook.com/dougvann
- http://www.linkedin.com/in/dougvann
- http://www.smallerindiana.com/profile/DougVannn