Thread Rating:
  • 6 Vote(s) - 4.5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
News Manager (updated)
(2013-05-03, 20:02:00)stevenjaycohen Wrote: Hi Carlos! Thank you for continuing support for News Manager. I am using the Updater plugin for GS. As you can see in the screenshot, it tells me that I have your version 2.3.5 installed, but it identifies the last version of the old plugin (2.2.4) as current. Also, it appears that you never made a module entry for that Create Post module you whipped up.

Updater is really useful for keeping up on patches. I hope it's an easy fix on your end.

This issue with News Manager happens (also with the admin plugins page) because of this (post #140 replying to #139). I've not decided yet about this, sorry.

As for the NM Create Post Shortcut plugin, it isn't in Extend. Maybe the Updater plugin should check if it's in Extend, as not all plugins are available there. I suppose the issue would disappear if I upload it.
Reply
News Manager 2.4.0 beta attached to this post.

Main changes are:
- support for other plugins that insert content using tokens or shortcodes (galleries, dynpages, etc.)
- also fixes issue when you use getPageContent in template/component
- use full/excerpt setting for archives/tag pages, not only main news page
- removed "Link to local page" link type in post editor
(see full changelog)

If you want to test it, please check if
  • localized dates (monthnames, week days) are properly displayed
  • posts are rendered correctly if they have:
    - non-English characters (accented, cyrillic...)
    - backslashes (e.g. try inserting this "\ \\ \\\" and see if all are displayed)
    - "less than" symbol ("<" in wysiwyg editor, "&lt;" in source code mode)

[attachment removed: news_manager-2.4.0-beta.zip (Downloads: 9)]
Reply
I've added some strings to the language file for 2.4.0 (right now these validation alerts are shown in English, and also I want them to be more descriptive):

Code:
"FIELD_IS_REQUIRED"   => "This field is required",
"ENTER_VALID_DATE"    => "Please enter a valid date / Leave blank for current date",
"ENTER_VALID_TIME"    => "Please enter a valid time / Leave blank for current time",

I need them translated to French, Greek and Polish. Thank you.

edit:
I found another (old) string that was never translated to these languages (no one noticed?):
Code:
"SUCCESS_RESTORE"     =>  "The post has been restored.",
Reply
Hi Carlos,
I'm using NM Versione 2.3.5 + NM Addons
But when I use the plugin romantranslit... it gives me some troubles.
Should I use the new version 2.4.0 ?
My website made with GetSimple CMS is

Arte & Società
www.artesocieta.eu

An indipendent website about Italian Contemporary Visual Arts
Reply
(2013-05-09, 05:34:36)D.O. Wrote: Hi Carlos,
I'm using NM Versione 2.3.5 + NM Addons
But when I use the plugin romantranslit... it gives me some troubles.
Should I use the new version 2.4.0 ?
2.4.0 is better in many ways, but it's not necessary for everyone.
What kind of troubles do you get? I think this is the most important information you didn't mention.
I made a Czechoslovak translit plugin (a re-write of Carlos's romantranslit plugin) and it works nice. It was working for me in 2.3.5 and it also works in 2.4.0 beta.
Tomáš Janeček - Multilingual personal website powered by GetSimple
» The little I did for GetSimple
Reply
Yes D.O., as TeeJay says, you don't tell what trouble are you having.
I just tested NM + NM Addons + romantranslit and had no issues.
Reply
Oh I apologise, I didn't see his Post!
Then, it happens when you're in the admin panel:
weirdly the position and the dimension of the font are modified without a reason.
Only removing the plugin Romantranslit everything is okay.
Of course, this didn't happen with the old version of GS.
My website made with GetSimple CMS is

Arte & Società
www.artesocieta.eu

An indipendent website about Italian Contemporary Visual Arts
Reply
Did you edit romantranslit.php? (with an editor that doesn't support UTF-8 without BOM, like Notepad)
Or, did you ftp upload it in ASCII mode instead of binary?
If you enable debug mode, do you get any errors?
Reply
News Manager works perfectly, right out of the box. I'm not sure why GS-blog gave me so much trouble.

Thanks so much.

Don
Reply
usually when your layout changes or font changes size, there is an inline php error somewhere.
NEW: SA Admin Toolbar Plugin | View All My Plugins
- Shawn A aka Tablatronix
Reply
(2013-05-11, 05:01:25)lakechicago Wrote: News Manager works perfectly, right out of the box. I'm not sure why GS-blog gave me so much trouble.

Thanks so much.

Don

It's strange that NM works for you but not GS Blog. They're quite similar, at least the way they're first installed and set up (only that GS Blog has a lot more options).
Reply
@Carlos
@Shawn

I am just doing some tests on this plugin. I am gonna write you later.
Thanks for you help.


(2013-05-11, 05:40:38)shawn_a Wrote: usually when your layout changes or font changes size, there is an inline php error somewhere.
My website made with GetSimple CMS is

Arte & Società
www.artesocieta.eu

An indipendent website about Italian Contemporary Visual Arts
Reply
Hi to all.
Yes Carlos you're right, in fact I used Notepad++ and everything works fine now. I edited the file "romantranslit.php" to add the marks "°" and, distractedly, I did it with Notepad. Problem fixed!
Thanks to all for your help!
My website made with GetSimple CMS is

Arte & Società
www.artesocieta.eu

An indipendent website about Italian Contemporary Visual Arts
Reply
@lakechicago

Could you please test News Manager 2.4.0 beta? (I suggest you don't do it in a public site where you have another NM instance)

Main change since 2.3.5 is the way the blog/news content is inserted into the page, in a similar way how GS Blog does (and also other plugins). I would like to make sure this is not the problem. Thanks.

[Edit] Nice to know you solved your problem with GS Blog, so with NM 2.4.0 you shouldn't have problems either.
Reply
Hi Carlos,
I was wondering if it's possible to show in NM the authors of the news
(in the case if you use the plugin "user-managment.php")
Example: I modified your plugin "recentpages.php" to show the author and it worked fine.
PHP Code:
$PAGEAUTHOR returnPageField($s,'author'); 
Can you do something like this in NM?
My website made with GetSimple CMS is

Arte & Società
www.artesocieta.eu

An indipendent website about Italian Contemporary Visual Arts
Reply
(2013-05-19, 17:09:19)D.O. Wrote: I was wondering if it's possible to show in NM the authors of the news
[...]
Can you do something like this in NM?

Some time ago I prepared a patch for NM to do this (but I think I didn't post it). I can look for it if you're interested.

However at this time I don't want to include this feature in the plugin, as it exposes user names. Maybe I'll do it (as an option) in some future release, but using the new display name field (GS 3.2), not the author field.
Reply
Meanwhile you could send me this patch, You know I am interested for that cultural magazine.
And yes I agree better using "display name" for the next official version.

(2013-05-20, 03:02:23)Carlos Wrote:
(2013-05-19, 17:09:19)D.O. Wrote: I was wondering if it's possible to show in NM the authors of the news
[...]
Can you do something like this in NM?

Some time ago I prepared a patch for NM to do this (but I think I didn't post it). I can look for it if you're interested.

However at this time I don't want to include this feature in the plugin, as it exposes user names. Maybe I'll do it (as an option) in some future release, but using the new display name field (GS 3.2), not the author field.
My website made with GetSimple CMS is

Arte & Società
www.artesocieta.eu

An indipendent website about Italian Contemporary Visual Arts
Reply
(2013-05-20, 05:38:33)D.O. Wrote: Meanwhile you could send me this patch,

Edit news_manager/inc/posts.php, find this:
Code:
$obj = $xml->addChild('content');
$obj->addCData($content);
Just after that, insert this:
Code:
// patch (author)
  if (isset($_POST['author'])) {
    $author = safe_slash_html($_POST['author']);
  } else {
    global $USR;
    if ($USR) $author = $USR;
  }
  if (isset($author)) {
    $obj = $xml->addChild('author');
    $obj->addCData($author);
  }
  // end patch (author)

Now edit news_manager/inc/site.php, find this:
Code:
if ($excerpt) $content = nm_create_excerpt($content);
Just after that, insert this:
Code:
$author = isset($post->author) ? stripslashes($post->author) : 'default_author'; // patch (author)
(change that default_author string by the name you want to be displayed in posts created before this patch)

And also in site.php, some lines below, insert <?php echo $author; ?> to display the user name.
For example, you could replace this:
Code:
<p class="nm_post_date"><?php echo i18n_r('news_manager/PUBLISHED') . " $date"; ?></p>
by this:
Code:
<p class="nm_post_date"><?php echo i18n_r('news_manager/PUBLISHED') . " $date"; ?> by <?php echo $author; ?></p>

As always, you'll have to re-do these patches when/if you upgrade the plugin.

The most important is the first one (posts.php) - if you don't do it and update some existing post, its author field will be lost.
Reply
Carlos, thank you very very much!
I think it's perfect now and I will suggest you to add something like this in the next NM versions. So GetSimple will not have anything to envy to Wordpress and Joomla!!
My website made with GetSimple CMS is

Arte & Società
www.artesocieta.eu

An indipendent website about Italian Contemporary Visual Arts
Reply
News Manager 2.4.0 available in Extend

Changelog:

Frontend
- support for other plugins that insert content using tokens or shortcodes (galleries, dynpages, etc.)
- also, fixes issue when you use getPageContent in template/component
- localization (for dates) is now set in the language file (new LOCALE string)
- moved some hardcoded strings (<<, ←, etc.) to language file
- new string (ELLIPSIS) for "[...]" in language file
- all frontend language strings are now redefinable (in gsconfig), no need to edit the language file
Backend
- several validation alert messages in English (title, date, time) are now translated
- removed "Link to local page" link type in post editor
- future/scheduled posts have dates in a different color
- CKeditor no longer uses html entities (like GetSimple)
- changed link to updated documentation page
- fix for fancy URL setting not being available in some cases
Both/other
- added Czech language (@TeeJay)
- added Danish language (@chrsand)
- better (though not optimal) support for I18N-powered multilanguage sites
- and some other small fixes, optimizations...
Reply
Since version 2.4.0 you can redefine all frontend language strings, allowing some basic customization. (With previous versions of the plugin, some of them could be modified by editing the language file, but then you had to be careful not to overwrite it when upgrading.)

To use this feature, you can insert some lines in your site's gsconfig.php file. Here's an example where we redefine the "Published on" string, the date format and those three dots after an excerpt:

Code:
$nm_i18n = array();
$nm_i18n["PUBLISHED"]   = "Posted on";
$nm_i18n["DATE_FORMAT"] = "%d.%m.%Y";
$nm_i18n["ELLIPSIS"]    = "...";

The first line is recommended.

This is the full list of frontend strings (with their default values):

Code:
$nm_i18n["FOUND"]       = "The following posts have been found:",
$nm_i18n["NOT_FOUND"]   = "Sorry, your search returned no hits.",
$nm_i18n["NOT_EXIST"]   = "The requested post does not exist.",
$nm_i18n["NO_POSTS"]    = "No posts have been found.",
$nm_i18n["PUBLISHED"]   = "Published on",
$nm_i18n["TAGS"]        = "Tags",
$nm_i18n["OLDER_POSTS"] = "&larr; Older Posts",
$nm_i18n["NEWER_POSTS"] = "Newer Posts &rarr;",
$nm_i18n["SEARCH"]      = "Search",
$nm_i18n["GO_BACK"]     = "&lt;&lt; Go back to the previous page",
$nm_i18n["ELLIPSIS"]    = " [...]",
$nm_i18n["LOCALE"]      = "en_US.utf8,en.utf8,en_US.UTF-8,en.UTF-8,en_US,en",
$nm_i18n["DATE_FORMAT"] = "%b %e, %Y"

It's not necessary to insert all lines, only those corresponding to texts you want to redefine (as in the example above).

Note that if you have non-English (US-ASCII) characters you must use a text editor that supports UTF-8 without BOM (e.g. Notepad++ for Windows) or use html entities for charactes like ä, é, ñ, ...
Reply
Oleg06, the fastest betatester in town, has reported an issue with 2.4.0: if you use placeholders like {% ... %} and (% ... %) near the beginning of posts, they are processed when they appear in excerpts (so if you e.g. insert a gallery in a post it can appear in the excerpt).

So here's a quick bugfix release:

News Manager 2.4.1 available in Extend
- removes {% ... %}, (% ... %) placeholders from excerpts

(Note: I've used some of mvlcek's code from I18N Search)
Reply
News Manager 2.4.2 now available in Extend
- fixes issue with meta description
Reply
Carlos,

as I had the need to implement the NM in a client's site, I went through all the news in this thread, tried to remember my experiences I had before and I found that the NM underwent a big big overhaul.

Gracias por tu pacienca y exactitud, thanks for your patience, exactness and continuity!

Connie
|--

Das deutschsprachige GetSimple-(Unter-)Forum:   http://get-simple.info/forums/forumdisplay.php?fid=18
Reply
(2013-05-23, 15:51:11)Carlos Wrote: - better (though not optimal) support for I18N-powered multilanguage sites

Could you give link or exmple how to use NM in multilingual site.
I want the same post display in different languages on my site. Is it possible with current version of NM?
Reply




Users browsing this thread: 14 Guest(s)