Thread Rating:
  • 6 Vote(s) - 4.5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
News Manager (updated)
(2013-07-07, 01:20:33)Carlos Wrote: What do you (anyone) think would be better?

1. mvlcek's I18N way: slugs post-1, post-1_en, etc. (files post-1.xml, post-1_en.xml in data/posts folder)

Options 2 and 3 look nicer to me, but 1 has one thing I like: easy to import-export from/to GS normal pages (I'm interested on this, which almost works right now)

As most people including me use NM with I18N (and everyone for multilingual sites), I would prefer to not change the way how it already is in I18N. Then it will be really easy to use, because the way how to do things multilingual won't change.

I understand that Mlvcek's solution isn't perfect but it is very good and user friendly.

Let's not forget the name of GetSimple and the reason why it was named as it is. I don't think that it's a good idea to do very similar thing a different way.
Tomáš Janeček - Multilingual personal website powered by GetSimple
» The little I did for GetSimple
Reply
hmm... I shouldn't have mixed different things - one is the data storage structure (for posts), another is the user interface (yes, I agree it should be similar to I18N's way)

By user-friendly, do you mean just the UI or also the slug/file structure?
Reply
(2013-07-07, 20:18:12)Carlos Wrote: hmm... I shouldn't have mixed different things - one is the data storage structure (for posts), another is the user interface (yes, I agree it should be similar to I18N's way)

By user-friendly, do you mean just the UI or also the slug/file structure?

I mean both, the adding _en for English is very simple.

The UI is also very well-understandable. For every page there's a row and for every language there's a column. So it's an imaginary table and an empty space means that's the page is not translated in the language of the column, it's hard to explain what I mean but I'm sure you get it.

That's what makes it user-friendly.

What I'm missing there is a feature which would translate the URL, but okay I can live with that.
Tomáš Janeček - Multilingual personal website powered by GetSimple
» The little I did for GetSimple
Reply
Hi,

is there a way to edit the creation date(s) of the articles other than editing the xml-files directliy?

Alex
Reply
Yes, of course: see the post Options.
Reply
(2013-07-09, 23:40:01)Carlos Wrote: Yes, of course: see the post Options.
Note to me: first look, then ask ;-)

Alex
Reply
A question about the post image support in 2.5 (beta):

Do you think it would be a good idea that all img tags have an alt attribute with the post title as value?

If yes, would it be better to have this enabled by default?
Reply
Carlos, I guess it could be optional and disabled by default.
Because the post's title is often abstract and often the post starts with a picture of certain people, which probably should be titled relatively and officially. So, the title of the post can be "True friendship never ends!" with a pic of mr. Putin and mr. Medvedev shaking hands titled as "President Putin and Premier Medvedev"..
Reply
Totally agree with 0zz. Alt is 1) obligatory tag according to XHTML standards 2) SEO tag. You could ruin SEO possibilities of images with this. But if you can do it optional with settings in back-end or GSConfig.php, some people might like it.
Tomáš Janeček - Multilingual personal website powered by GetSimple
» The little I did for GetSimple
Reply
Thank you for your feedback. alt will not be enabled by default.



Another question:
I'm going to change excerpt generation so that the last word isn't truncated (as usually happens). I never liked that, and I think this way will be better for most languages.
Anyone thinks it would be nice to have a setting to enable truncating?
Reply
(2013-07-15, 05:06:47)Carlos Wrote: Another question:
I'm going to change excerpt generation so that the last word isn't truncated (as usually happens). I never liked that, and I think this way will be better for most languages.
Anyone thinks it would be nice to have a setting to enable truncating?

In this case, this should be standard and I don't see any reason why'd anyone like to keep his words tearing up Smile and there is no reason to add settings for this - this little improvement is expectable behaviour.
Tomáš Janeček - Multilingual personal website powered by GetSimple
» The little I did for GetSimple
Reply
Agree. I don't see a reasong why anyone may need this ugly presentation of news anonces, excerpt for very specific need of cutting anonces to certain number of symbols.. Even in this case, I'd prefer to rewrite the post to fit such limits.
Reply
(2013-07-14, 20:44:02)Carlos Wrote: A question about the post image support in 2.5 (beta):
Do you think it would be a good idea that all img tags have an alt attribute with the post title as value?
If yes, would it be better to have this enabled by default?

Ad far I am concerned, it's a very good idea and it should be by default
My website made with GetSimple CMS is

Arte & Società
www.artesocieta.eu

An indipendent website about Italian Contemporary Visual Arts
Reply
Hi mates, just a question: how I can display the last news of a particular TAG?

Example, I would like to show only the news under the tag "books" and not the last news under the tag "music".

is it possible?
My website made with GetSimple CMS is

Arte & Società
www.artesocieta.eu

An indipendent website about Italian Contemporary Visual Arts
Reply
With News Manager Addons plugin 0.5,
Code:
<?php nm_list_recent_by_tag('books'); ?>
Reply
Hi Carlos, I didn't know this addon. Thanks!

Hey I modifed the function nm_search in this way for my magazine and I think it should be added by default to your NM.

You should then create a variable for the word "Search..." (e.g. i18n('news_manager/SEARCHWORD');)
but I don't think it's a problem!

Code:
function nm_search() {
  $url = nm_get_url();
  ?>
  <form id="search" action="<?php echo $url; ?>" method="post">
    <input type="text" class="text" name="keywords" name="keywords" value="Search..." onfocus="if (this.value=='Search...') {this.value=''}" onblur="if (this.value=='') {this.value='Search...'}"/>
    <!--[if IE]><input type="text" style="display: none;" disabled="disabled" size="20" value="Ignore field. IE bug fix" /><![endif]-->
    <input type="submit" class="submit" name="search" value="<?php i18n('news_manager/SEARCH'); ?>" />
  </form>
  <?php
}

?>
My website made with GetSimple CMS is

Arte & Società
www.artesocieta.eu

An indipendent website about Italian Contemporary Visual Arts
Reply
Great idea, thanks D.O.
But I think I'm going to do it like this (no javascript):
Code:
<input type="text" class="text" name="keywords" placeholder="Search..." />

By the way, instead of SEARCHWORD I prefer something like SEARCH_HINT, or SEARCH_TEXT, SEARCH_PLACEHOLDER... Opinions?
Also, I think I will not add the string to the default language files, but allow defining the string in gsconfig etc.

On the other hand, I'm not very interested in working in NM's search, other than fixing issues that you find. I'd like to adapt mvleck's i18n_dummy_search code to NM (when I have the time to play with it).
Reply
SEARCH_TEXT sounds perfect to me
and I agree, it's better to define the string in gsconfig.
About Placeholder, I don't recommend to use it because it is only for HTML5.
No great idea, Carlos, just my little contribution, anything vital!
=D
My website made with GetSimple CMS is

Arte & Società
www.artesocieta.eu

An indipendent website about Italian Contemporary Visual Arts
Reply
Thanks D.O.
I chose SEARCH_PLACEHOLDER as it seems commonly used.

I'm not sure if to use that javascript technique.
If you browse with js diabled you have to delete the characters in the search box.

I suppose anyone that wants it that way can simply put a modified function (renaming it to e.g. nm_search_js in the theme's functions.php and call it in the template.

Edit: I've added a new function nm_search_with_placeholder to NM Addons (0.6)
Reply
News Manager 2.5 beta 9 attached to this post.
Changes in this version:

- last word in excerpts is no longer truncated

- optional alt, title attributes in post <img> tags. Example:
Code:
$NMIMAGES = array('width'=>90, 'height'=>90, 'alt'=>true, 'title'=>true);

- sidebar function nm_list_archives now has an optional string parameter for date format (strftime). Examples:
month, year:
Code:
<?php nm_list_archives('%B, %Y'); ?>
year/monthnumber:
Code:
<?php nm_list_archives('%Y/%m'); ?>

- new (optional) language string for placeholder text in search box (HTML5). Usage (gsconfig):
Code:
$nm_i18n['SEARCH_PLACEHOLDER'] = 'Enter words here...';

(see more info for new features in 2.5 beta here)

[Attachment removed: news_manager-2.5-beta9.zip (Downloads: 11)]
Reply
No thanks needed, Carlos!
I am glad to have been helpful, I think NM is one of the most useful plugins of GS.
And you do a great job with IT!
Now I am starving to try the new search-bar and the new version of NM.
Thank you again!
My website made with GetSimple CMS is

Arte & Società
www.artesocieta.eu

An indipendent website about Italian Contemporary Visual Arts
Reply
Good day, how to remove the signs at the end of the post [...]


excuse me find where removed =)
Reply
Simple,
all you need to do is this:
add this line

$nm_i18n["ELLIPSIS"] = "";

to your gsconfig.php file.
My website made with GetSimple CMS is

Arte & Società
www.artesocieta.eu

An indipendent website about Italian Contemporary Visual Arts
Reply
Hi Carlos,
I found a small bug in NM... Eg. if the news is 150 characters long and its extract is instead fixed at 200 characters, NM does not show the link "read more".
So it becomes impossible to "open" the news if the linked title is disabled.
Nothing serious anyway, I just wanted you to know.
My website made with GetSimple CMS is

Arte & Società
www.artesocieta.eu

An indipendent website about Italian Contemporary Visual Arts
Reply
Not really a bug, I think it's the behaviour you should expect. But nice catch anyway.

I could change it so that:
- if no title link and readmore enabled, show the link always
or:
- you can (optionally) set it to always display the readmore link

...but I'm not sure if to do it or leave it for some future NM version that would allow more customization (with post templates or whatever).

Do you need this for some of your sites? Or were you just experimenting? (thanks for testing BTW)
Reply




Users browsing this thread: 21 Guest(s)