Posts: 8
Threads: 1
Joined: Jan 2011
2011-01-08, 03:20:41
(This post was last modified: 2011-01-08, 07:12:49 by laurel.)
Hello!
While I do have a very basic understanding of PHP, some things used here are at the moment too complex and I need some help figuring something out.
My problem is that I on my website would like to have an easy system for managing several posts on one page. GetSimple doesn't seem to have this kind of feature, but this plugin does. However, with this plugin, the same news appear on every page. What I would need is for every different page to have different news. It could perhaps be achieved by having a drop-down menu in the news editing plugin choosing on which page it should go, and then only loading the xml-files that belong to that page (for example by saving the page name in the xml-file or in the xml-filename), and if this was a simple system I made myself I could do that, but in this more professional system it's too complex for me.
Another solution, even though not as pretty, would be just editing all pages in the normal CKE-editor and have all news in one big text with headers in between, but then there's another problem, how would you enable someone to insert headers in the current CKE-editor? I don't want to force the users to go into source mode and for example add h1-tags around their headers.
I'd be thankful if someone could help me come up with a solution to this problem.
EDIT: Found a temporary solution by finding the option to change the WYSIWYG Editor toolbar to advanced. This will work until I get the news plugin to work as I want, currently trying to make a function that will simply return all the pages.
Posts: 93
Threads: 7
Joined: Oct 2010
I see what you mean, and a solution would be to use categories. At the moment I'm not really interested in implementing this, as I intended this plugin to be basic and simple, but it shouldn't be much work so if anyone wants to extend the plugin, feel free to do so.
Posts: 1
Threads: 0
Joined: Jan 2011
Any chance of pagination and and extra news page, like
On the main site it shows 3 latest news and for example alltimenews page shows news all time?
Posts: 93
Threads: 7
Joined: Oct 2010
2011-01-14, 09:01:24
(This post was last modified: 2011-01-15, 01:27:48 by ljgww.)
Yes, I just added this :-)
To get what you want you should create 2 templates/pages: one that has the line
Code: <?php show_articles(3); ?>
and one with
Code: <?php show_articles(); ?>
Note the value 3 added as an argument in the upper line of code.
Posts: 1,928
Threads: 88
Joined: Apr 2010
Yesterday I installed the Disqus Plugin, and now when you click on the link Create New ARTICLE I send
Code: http://neowebtime.ru/01/admin/load.php?id=external_comments&edit
Posts: 93
Threads: 7
Joined: Oct 2010
You're right, it's fixed now. Thanks for pointing that out!
Posts: 45
Threads: 12
Joined: Nov 2010
Is there anyway to implement this script perhaps on the index content page, instead of having to place it within the theme files. It's a great on the fly news manager, and very easy for like a 1 liner updates, but if you don't want your news content on every page, any idea how you guys. I tried putting it in the actual data xml, but it automatically just gets commented out.
Posts: 93
Threads: 7
Joined: Oct 2010
If you don't want your news articles on every page of your website, then create a seperate theme template (a copy of template.php for example) that links to the news plugin and choose that particular template when creating a new page.
Posts: 2,094
Threads: 54
Joined: Jan 2011
You can also use the DynPages plugin ( http://get-simple.info/extend/plugin/dynpages/81/).
Just put the code to show the news, e.g.
Code: <?php show_articles(); ?>
in a component named "news" and put the following place holder on any page where you want to show news:
This way you could include content before and after the news, for example:
Code: <p>Some text...</p>
<p>And now the news:</p>
<p>{% news %}</p>
<p>An now back to other topics...</p>
Posts: 45
Threads: 12
Joined: Nov 2010
mvlcek: awesome man! I got it all lined up @ http://www.shoutinginfrench.com on the homepage.
Posts: 16
Threads: 2
Joined: Jun 2010
2011-02-02, 08:37:43
(This post was last modified: 2011-02-02, 08:38:13 by binhdownunder.)
Why don't work "Enable the HTML editor" option?
I disable HTML editor in GetSimple settings, but in News Manager it's enabled
p.s. News Manager 1.1.1
Posts: 16
Threads: 2
Joined: Jun 2010
Somebody does title=link to full news on single page?
Posts: 93
Threads: 7
Joined: Oct 2010
Eugene, the plugin now honors the HTML editor option. As for your title=link request, I might do that later.
Posts: 105
Threads: 10
Joined: Dec 2009
2011-02-11, 23:39:47
(This post was last modified: 2011-02-11, 23:41:47 by Jeff.)
Hello,
I have an error in 3.0B with exec-php in debug mod :
(testing with version 1.1.2)
Code: Warning: Missing argument 1 for show_articles(), called in
D:\ZMWS\_web.zmwsc\GetSimple_3.0Beta_r307\plugins\zzzz_exec-php.php(30) : eval()'d code on line 2 and defined in
D:\ZMWS\_web.zmwsc\GetSimple_3.0Beta_r307\plugins\news_manager.php on line 222
Thanks
Posts: 105
Threads: 10
Joined: Dec 2009
madvic Wrote:Hello,
I have an error in 3.0B with exec-php in debug mod :
(testing with version 1.1.2)
Code: Warning: Missing argument 1 for show_articles(), called in
D:\ZMWS\_web.zmwsc\GetSimple_3.0Beta_r307\plugins\zzzz_exec-php.php(30) : eval()'d code on line 2 and defined in
D:\ZMWS\_web.zmwsc\GetSimple_3.0Beta_r307\plugins\news_manager.php on line 222
Thanks
I correct with :
Code: <?php show_articles(0); ?>
and an another error :
Code: Notice: Undefined variable: index in
D:\ZMWS\_web.zmwsc\GetSimple_3.0Beta_r307\plugins\news_manager.php on line 234
Notice: Undefined variable: pages in
D:\ZMWS\_web.zmwsc\GetSimple_3.0Beta_r307\plugins\news_manager.php on line 234
Thanks
Posts: 105
Threads: 10
Joined: Dec 2009
When I do this :
Code: <?php show_articles(1); ?>
I have this error in debug mod :
Code: Notice: Undefined index: QUERY_STRING in
D:\ZMWS\_web.zmwsc\GetSimple_3.0Beta_r307\plugins\news_manager.php on line 267
Thanks
Posts: 93
Threads: 7
Joined: Oct 2010
2011-02-12, 08:47:27
(This post was last modified: 2011-02-12, 08:47:48 by ljgww.)
Madvic, I've addressed the first two issues, they should be solved now. About the third one, afaik $_SERVER['QUERY_STRING'] is a valid php variable so I don't understand why you are having this error.
Posts: 105
Threads: 10
Joined: Dec 2009
OK, Thanks for issues.
Definition :
'QUERY_STRING'
The query string, if any, via which the page was accessed.
But if query string not exist ? -> error.
Posts: 1,928
Threads: 88
Joined: Apr 2010
2011-02-18, 01:20:39
(This post was last modified: 2011-02-19, 00:45:48 by jhondavis.)
really impossible to make a short news item and follow a link to the full article?
http://neowebtime.ru/01/news-2
Posts: 1,204
Threads: 30
Joined: Jun 2010
roog Wrote:Note that this plugin won't work with fancy urls unless you write your own mod_rewrite rules!
Has anyone been successful with generating rewrite rule to access older articles with fancy urls ?
I'm not even 100% sure if this option works as supposed, because even with furls disabled, clicking on "older articles" doesn't lead to them. At least not with gs2.04b.
ps. you could make use of function located in basic.php to create furls
Addons: blue business theme, Online Visitors, Notepad
Posts: 18
Threads: 1
Joined: Dec 2010
2011-03-02, 13:28:33
(This post was last modified: 2011-03-02, 13:30:29 by ganga0.)
Oleg06 Wrote:really impossible to make a short news item and follow a link to the full article?
http://neowebtime.ru/01/news-2 Þûõó, ò 19 ÿþÑÂтõ òыûþöõýð üþѠòõрÑÂøѠѠÿрõòьюшúðüø ýþòþÑÂтõù, úþтþрыõ òõôут ýð ÿþûýую ýþòþÑÂть - ýõ ÿþôþùôёт? àтут - руÑÂøфøцøрþòðýýðÑÂ
Posts: 1,928
Threads: 88
Joined: Apr 2010
2011-03-02, 18:26:07
(This post was last modified: 2011-03-02, 18:27:07 by jhondavis.)
ÑÂôõûðù ÿþöðûуùÑÂтð рð÷ñøòúу ÿþ ÑÂтрðýøцðü, чтþñы üþöýþ ñыûþ хþтѠñы ò úþôõ рõóуûøрþòðть úþûøчõÑÂтòþ ÑÂтðтõù ýð ÑÂтрðýøцõ ø цõýы ýõ ñуôõт тòþõüу ÿûðóøýу
http://neowebtime.ru/00/www
Posts: 105
Threads: 10
Joined: Dec 2009
2011-03-03, 01:03:59
(This post was last modified: 2011-03-03, 01:11:05 by Jeff.)
madvic Wrote:OK, Thanks for issues.
Definition :
'QUERY_STRING'
The query string, if any, via which the page was accessed.
But if query string not exist ? -> error.
The correction :
/*******************************************************
* @function show_articles
* @action runs the news plugin on the theme/site page
*/
function show_articles($n = NULL) {
$articles = get_articles();
if (isset($n) && $n > 0) {
$index = (isset($_GET['page'])) ? $_GET['page'] : 0;
$pages = array_chunk($articles, $n);
if (count($pages) > 0){
$articles = $pages[$index];
}
}
foreach ($articles as $article) {
$id = basename($article, ".xml");
show_single($id);
}
if (isset($n) && $n > 0)
show_navigation($index, sizeof($pages));
}
/*******************************************************
* @function show_navigation
* @action provides links to navigate between article pages
*/
function show_navigation($index, $pages) {
$queryString = "";
if (isset($_SERVER['QUERY_STRING'])){
$queryString = $_SERVER['QUERY_STRING'];
}
$query_string = preg_replace('/&?page=-?\d+/', '', $queryString);
if (strlen($query_string) == 0) {
$url = $_SERVER['PHP_SELF'];
$delimiter = '?';
} else {
$url = $_SERVER['PHP_SELF'] . '?' . $query_string;
$delimiter = '&';
}
....
Posts: 2,928
Threads: 195
Joined: Feb 2011
2011-03-03, 17:13:53
(This post was last modified: 2011-03-03, 18:16:07 by Tuliptani.)
I am testing the plugins for Get-Simple and I run into poor documented plugins
why should we read a long forum thread to get information how to use the plugin?
This is discouraging ;=)
maybe you write a short step by step instruction, show this at the extend-page and add it to the download zip?
It makes me sad to read such a lot of php-discussions and complaints when I want to find out how to get this to work
Edit:
I noticed that the pagination does not work ("older articles") at the footer of a page which shows 3 Articles:
The page is:
http://www.urbanistan.de/getsimple/news-...-der-seite
the link to older articles is:
http://www.urbanistan.de/getsimple/index...ite&page=1
I added this line to .htaccess:
Code: RewriteRule ^news/([^/]*)\.html$ /index.php?article=$1 [L]
with no result
Posts: 1,928
Threads: 88
Joined: Apr 2010
anyone can make a normal plug-in news that on every news created a separate page in the directory pages, as in the I18N Search, to a pagination of pages, to can add pictures, so you can individually write a short news text, a separate full news
Sorry, Google translate
|