Just thought it would be a good idea to have an automatic expiry for news articles.... 1 week, 1 month, 1 year, never.....
and have it default to the last used value.....
got I gotta get some time to work on these plans.
News mods
-
- Support Guru
- Posts: 8169
- Joined: Tue Oct 19, 2004 6:44 pm
- Location: Fernie British Columbia, Canada
News mods
Well, the end date is already there. You'd just need to add some magic to make it work from a dropdown list of predefined values.
-
- Support Guru
- Posts: 8169
- Joined: Tue Oct 19, 2004 6:44 pm
- Location: Fernie British Columbia, Canada
News mods
Done.... a "News2" module is available from http://techcom.dyndns.org
Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
News mods
OK ... I must be doing something wrong here.
I place this plugin link into a page
{cms_module module=news summary=page length=80 showcategorywithtitle=true}
The news page shows all the news items, the long items are shortened to 80 characters, the category shows, however ...
The links go nowhere, the links created are like this example
I created another page (news3) with the all the news items being displayed and not displayed in the menu.
I put this line in it
{cms_module module=news}
Then in my original news page I changed the line to
{cms_module module=news summary=news3 length=80 showcategorywithtitle=true}
Problem is the path is still incorrect. If I manually type in the correct url the page news3 shows and jumps to the correct news item.
UPDATE - 2
changed /index ... to index... on line 193 of the news modulefunctions.php and all works well.
Is there a way to pass the news id as a parameter to another page with the news module so it displays the selected news item only?
{cms_module module=news id=?} ?
One more question ... what is the no_anchors parameter for?
UPDATE - 3
Added lines at 219 in news modulefunctions.php
This adds a [url=http://#]more ....[/url]link at the end of the news content if the summary is on and the length of the content is longer than the length parameter.
I also took the links off the titles as it is redundant if the length of the content is shorter than the length parameter (commented out lines 191 - 195 and removed the else in line 196).
I place this plugin link into a page
{cms_module module=news summary=page length=80 showcategorywithtitle=true}
The news page shows all the news items, the long items are shortened to 80 characters, the category shows, however ...
The links go nowhere, the links created are like this example
UPDATE:
I created another page (news3) with the all the news items being displayed and not displayed in the menu.
I put this line in it
{cms_module module=news}
Then in my original news page I changed the line to
{cms_module module=news summary=news3 length=80 showcategorywithtitle=true}
Problem is the path is still incorrect. If I manually type in the correct url the page news3 shows and jumps to the correct news item.
UPDATE - 2
changed /index ... to index... on line 193 of the news modulefunctions.php and all works well.
Is there a way to pass the news id as a parameter to another page with the news module so it displays the selected news item only?
{cms_module module=news id=?} ?
One more question ... what is the no_anchors parameter for?
UPDATE - 3
Added lines at 219 in news modulefunctions.php
Code: Select all
if (strlen($row["news_data"]) >$params["length"]){
echo "<br><a href="index.php?page=".$params["summary"]."#".$row["news_id"]."">more info ...</a>";}
I also took the links off the titles as it is redundant if the length of the content is shorter than the length parameter (commented out lines 191 - 195 and removed the else in line 196).
Greg
News mods
News2 has been merged into the current News module and will be in 0.7.3 (and is in the latest rc)
-
- Support Guru
- Posts: 8169
- Joined: Tue Oct 19, 2004 6:44 pm
- Location: Fernie British Columbia, Canada
News mods
Here's what I have.....
where "the-latest-and-greatest" is a page alias to one of my pages....
where "the-latest-and-greatest" is a page alias to one of my pages....
Code: Select all
{cms_module module="news" summary="the-latest-and-greatest" number="5" length="80"}
Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.