Page 1 of 1

News detail page using template for page it's on, I want to use other template..

Posted: Wed May 23, 2007 12:11 am
by amandapanda
Hi all. I am new here. I noticed the news detail page uses the template for the page the news summaries are displayed on which is my home page but, I want to use the other template that I use for my pages. How can I accomplish this? Thanks in advance.  :)

Re: News detail page using template for page it's on, I want to use other templa

Posted: Wed May 23, 2007 3:53 am
by Dr.CSS
If you go to Extensions » Modules then click on the Module name, ie. News, or the word Help, on the right, you get the parameters it will take, such as this from News...

So you make a page called news and have it not shown in the menu and use the template of your choice...

With pages like this I use the view source mode to put   in for content, since you can't make a blank/no content page...


# (optional) detailpage="pagealias" - Page to display News details in. This can either be a page alias or an id. Used to allow details to be displayed in a different template from the summary.

Re: News detail page using template for page it's on, I want to use other templa

Posted: Wed May 23, 2007 4:19 am
by amandapanda
Fantastic!! Thank you!  :D

Two separate pages for Summary and Detail

Posted: Mon Jul 02, 2007 12:15 pm
by wournos
mark wrote: If you go to Extensions » Modules then click on the Module name, ie. News, or the word Help, on the right, you get the parameters it will take, such as this from News...

So you make a page called news and have it not shown in the menu and use the template of your choice...

With pages like this I use the view source mode to put   in for content, since you can't make a blank/no content page...


# (optional) detailpage="pagealias" - Page to display News details in. This can either be a page alias or an id. Used to allow details to be displayed in a different template from the summary.
I have run into a similar problem.
My problem is that I would like to have News Summary on one page and News Detail on another page and link them together with a "Full article" link. I tried the tip you gave but I find it lacking in detail. I have created a page called news_in_detail and added the  . What now? On which page should I add detailpage="pagealias" and where?

Thanks.

/W

Re: News detail page using template for page it's on, I want to use other templa

Posted: Mon Jul 02, 2007 12:43 pm
by stopsatgreen
On the page where you want the summaries to appear, just use {news detailpage="news_in_detail"}

Re: News detail page using template for page it's on, I want to use other templa

Posted: Mon Jul 02, 2007 1:33 pm
by wournos
Thanks. That worked. But how do I get the detailed news to show up on the second page? Is there a specific tag somewhere?

/W

Re: News detail page using template for page it's on, I want to use other templa

Posted: Mon Jul 02, 2007 2:32 pm
by stopsatgreen
As long as your 'news_in_detail' page uses a valid template, you should just have to put {content} in the main content area instead of  

Re: News detail page using template for page it's on, I want to use other templa

Posted: Mon Jul 02, 2007 3:13 pm
by wournos
HA! It worked. Thank you. =D

/W

Question for Mark: News detail page using template for page it's on

Posted: Fri Feb 15, 2008 4:12 pm
by mikehenson
mark wrote: If you go to Extensions » Modules then click on the Module name, ie. News, or the word Help, on the right, you get the parameters it will take, such as this from News...

So you make a page called news and have it not shown in the menu and use the template of your choice...

With pages like this I use the view source mode to put   in for content, since you can't make a blank/no content page...


# (optional) detailpage="pagealias" - Page to display News details in. This can either be a page alias or an id. Used to allow details to be displayed in a different template from the summary.
Hi Mark
I think I follow this all the way down to the part where you actually link the news item to the page you want it to be displayed on. Could you add a little more here please in the way of instruction?
Many thanks
Mike
PS. Is this on a bug/fix list somewhere. It's quite bizarre that a news item should be displayed under a completely unrelated title because that happens to be where the person was before they clicked on the news link. Mind you, with some careful thought you could come up with some hilarious headlines :)

Re: News detail page using template for page it's on, I want to use other templa

Posted: Sat Feb 16, 2008 5:11 am
by Dr.CSS
Not sure what this means?...

"It's quite bizarre that a news item should be displayed under a completely unrelated title because that happens to be where the person was before they clicked on the news link"

Re: News detail page using template for page it's on, I want to use other template..

Posted: Sat Feb 16, 2008 2:38 pm
by mikehenson
Hi Mark

You're right to not understand what I'm talking about because I seem to have broken the display of news on all three sites I've built using CMSMS and I've done it inadvertantly so I don't know how to fix it.

Normally, in the default installation, if you're sitting on the Home page the top of the content section says "Home" then, when you click on a news item, the whole content section changes and puts "News" at the top of the content section with the news detail below.

What I've done is to create a situation where the top of the content section continues to say "Home" (or whatever page was last displayed) and doesn't change to "News" when you click on a news item.

I thought this thread was a fix to that problem - I hadn't realised that the problem was made by me - and on all three sites I've made.

Kind regards

Mike

Re: News detail page using template for page it's on, I want to use other templa

Posted: Sat Feb 16, 2008 9:34 pm
by Dr.CSS
The word "Home" is most times the title of the page, so if you want it to say News you can make a page called News and set it as your detail page, clicking a news article will take you to that page...

Re: News detail page using template for page it's on, I want to use other template..

Posted: Mon Feb 18, 2008 1:02 pm
by mikehenson
Oh dear, maybe I'm not explaining this properly.

In the default installation of CMSMS, I doesn't matter what page you're sitting on, when you click on a News Item Link the title of the page in the main content area changes to "News" and the news detail appears below it.

I seem to have broken that and I don't know how/where I made the mistake but when I click on a News Item Link the title of the page does not change to News - it retains the title from whatever page I was on when I clicked on the News Item Link. The News detail appears OK but the title doesn't change to "News".

So, if I'm sitting on "Contact Us" (for example) and I click on a News Item Link, the title of the main content section stays as "Contact Us" when it should change to "News".

What have I broken?

Re: News detail page using template for page it's on, I want to use other templa

Posted: Mon Feb 18, 2008 11:13 pm
by Dr.CSS
In the default install there is a page called News and the other News tags have the {news detailpage="news"} call in it so any news items clicked go to "News" and replace any content there with that news articles details...

Re: News detail page using template for page it's on, I want to use other template..

Posted: Tue Feb 19, 2008 12:38 pm
by mikehenson
Thanks Mark

I had inadvertantly deleted the "News" page along with all the other pages in the default install.

I've been scouring the templates and CSS to try and see what I'd done wrong and, as quite often happens, the answer was simple!

Sometimes it's difficult to see the wood from the trees!