Home N-13 News Forums Help Search
RegisterForgot password?
How to add image to post necklacesdiscou
Known bugs - 4.0.3 necklacesdiscou

Latest N-13 News 4.0.3

What is N-13 News?
Where can I get help?
Known bugs

Forums Help & Support Change "Full Message" display
Rayc
Posted on 13 Jun 2010, 16:07:09

Access: Member
Total Posts: 74
Joined: 2010-06-13

Hi,

I'm working my way through N-13. I'm using the default template provided for displaying News. By using the Short Message, I get a display of headlines with short message, and a link to display the full message.

How can I modify how the Full Message is displayed?

Should I have TWO pages with different templates - one for the news summaries and one for full stories?

Thanks,
-RayC
#2443
Chris
Posted on 13 Jun 2010, 19:20:00

Access: Admin
Total Posts: 1395
Joined: 2006-05-19

It depends on how your site is designed. Do you have a section where it shows only headlines and another section to display the full article? or do you use the same section to display the headlines, once a headline is clicked it displays the full article in its place?

If displaying in the same section you could use a bit of custom code to use multiple templates, something like this

Code:
<?php
if(!$_GET['id']){
    
// not viewing a full article so use the headlines template
    
$template = 'headlines';
}else{
    
// viewing a full article, use the full story template
    
$template = 'fullstory';
}

include 
'news/index.php';
?>
#2448
Rayc
Posted on 14 Jun 2010, 01:28:44

Access: Member
Total Posts: 74
Joined: 2010-06-13

I kind of have both. I have created a very basic template called "headlines", and on the home page it lists the headlines, with the title linked to the full article.

The "News" page itself uses the default template that is installed with the script. So the news page shows the "Short Story" with this link to the "Full Story".

Code:
[readmore]Full Story[/readmore]


What I was trying to do was slightly alter the "Full Story" display. I just wanted a link from the Full Story display to go back to the main news display. I figured out that if I put a link in the "COMMENTS STRUCTURE", that would work.

It confuses me a bit to have this;

Code:
{shortstory}
{story}
[readmore]Full Story[/readmore]


in the "NEWS" section of the template, yet the {story} is not displayed until the [readmore][/readmore] link is clicked. That is, unless there is no Short Story entered.

I guess I need to get my head around the template structure a little better. I'm not sure I completely understand it. It would be cool if there were some sample templates set up to display the news in various ways that folks could either use as-is, or study to help understand things better.

I'm not saying you should run off and do that -- you do more than enough. :eheheh: But maybe there could be a way for users to post template configurations to share/show off.

Thanks, again, for all your efforts.

-Ray
#2487
Network-13.com © 2013