GetSimple Support Forum
News Manager (updated) - Printable Version

+- GetSimple Support Forum (http://get-simple.info/forums)
+-- Forum: GetSimple (http://get-simple.info/forums/forumdisplay.php?fid=3)
+--- Forum: Plugins (http://get-simple.info/forums/forumdisplay.php?fid=13)
+--- Thread: News Manager (updated) (/showthread.php?tid=3972)



RE: News Manager (updated) - Oleg06 - 2014-05-01

Yes, the plugin was old, now it works Smile


RE: News Manager (updated) - mengi - 2014-05-01

(2014-05-01, 01:48:55)Carlos Wrote: ...and let me know if it works for you.

It sure did. Thank you for the quick reply!!


RE: News Manager (updated) - Oleg06 - 2014-05-02

be ever able to use breadcrumbs?


RE: News Manager (updated) - Carlos - 2014-05-03

It can be done. I assume there's already some code that generates the breadcrumbs for normal GS pages, so we just have to insert some code after it.

Tell me, do you want breadcrumbs only for single/full posts? Or also for tag pages and archives?
Do you want them to have a link, or just the title?
What would be the separator? (» or other)


RE: News Manager (updated) - Oleg06 - 2014-05-03

I'm usually working with this plugin, today for the first time decided to use your great plugin and found it
http://get-simple.info/extend/plugin/microdata-breadcrumbs/617/


RE: News Manager (updated) - Carlos - 2014-05-03

I was going to prepare a snippet for this, but I just found that the Microdata Breadcrumbs plugin doesn't generate correct URLs. Well, it does only if your permalink structure is %slug% (without trailing slash, and no parent)


RE: News Manager (updated) - Oleg06 - 2014-05-03

hmm, really need to use or i18n or function of the theme of innovation


RE: News Manager (updated) - TeeJay - 2014-05-03

I'm too busy to help you in some better way because of exams period, but at least the very few I can say:

I've been using I18N Breadcrumbs for some time and of course I added a piece of code to make it work with News Manager posts as well Smile and those microdata - yeah, I use them too, but again in my custom implementation without any plugin - something had to be added to I18N as well.

So this is how my breadcrumbs look like
Code:
<p class="breadcrumbs">
  <span itemscope itemtype="http://data-vocabulary.org/Breadcrumb">
      <a href="<?php get_site_url(); ?>en/" itemprop="url"><span itemprop="title">Home</span></a>
  </span>                                      
  <?php get_i18n_breadcrumbs(return_page_slug());
  
  if (nm_is_single()) { ?>
  &nbsp;»&nbsp;&nbsp;<span itemscope itemtype="http://data-vocabulary.org/Breadcrumb"><strong><a href="<?php nm_post_url(); ?>" itemprop="url"><span itemprop="title"><?php nm_post_title(); ?></span></a></strong></span>
  <?php } ?>
</p>

You can remove any intemscopes and itemtypes if you don't want to use them. If you want to, then you should edit I18N too like this:

frontend.class.php, lines +- 342-343
Code:
echo ' &raquo; <span class="breadcrumb"><a href="' . $url . '" title="' .
        strip_quotes($title) . '" >' . $text . '</a></span>';

replace with

echo ' &raquo; <span class="breadcrumb" itemscope itemtype="http://data-vocabulary.org/Breadcrumb"><a href="' . $url . '" title="' .
        strip_quotes($title) . '" itemprop="url"><span itemprop="title">' . $text . '</span></a></span>';. $text . '</span></a></span>';

But definitely I agree that this way of adding correct microdata is a kind of dirty core hack. At least I've shown you my way for the NM breadcrumbs.


RE: News Manager (updated) - Oleg06 - 2014-05-03

thanks TeeJay it works


RE: News Manager (updated) - Carlos - 2014-05-03

Just a side note. If you don't need the microdata, here's a simple, modified version of mvlcek's example for breadcrumbs with I18N Navigation. (I only inserted the <?php if... line.)

Code:
<div class="breadcrumbs">
  <a href="<?php echo find_url('index',null); ?>">home</a>
  <?php get_i18n_breadcrumbs(return_page_slug()); ?>
  <?php if (nm_is_single()) { ?>&raquo; <span class="breadcrumb"><a href="<?php nm_post_url(); ?>" title="<?php nm_post_title(); ?>"><?php nm_post_title(); ?></a></span><?php } ?>
</div>



RE: News Manager (updated) - smolek1980 - 2014-05-12

Welcome

First sorry for my english but my english is weak.

I would ask is possible to display newst i mean last topics on site ic code sometching like in template

<?php get ;?>

Title last topics ( 10 topics i need to display ) and i want link topics too.

Anyone can help me please sorry for my english again.

Btw. this is possible ?


RE: News Manager (updated) - Carlos - 2014-05-12

If by "topics" you mean "posts" (or "articles"), the code to insert in your template is:
Code:
<?php nm_list_recent(); ?>

You can set the number of posts in the plugin settings -> Number of recent posts (in sidebar)

(more info: http://www.cyberiada.org/cnb/news-manager/ -> Sidebar functions)


RE: News Manager (updated) - xxdex - 2014-05-14

there is any chance to get a news manager working on couple pages in get simple ?
example:

in page index (start) every news are visible...
in page sport ... is sortable... and visible only news with sport ...
in page drinking Smile ... is sortable... and visible only a news with drinking...
??


RE: News Manager (updated) - Carlos - 2014-05-14

D.O. and TeeJay already posted some tips to do stuff like this by using template tags and conditionals. I can search for those posts if you wish. But here's another way:

- Select index as newspage (Page to display posts)

- Install the DynPages plugin and activate it.

- Create a component e.g. newsbytag with:
Code:
<?php global $args; nm_show_tag($args[0]); ?>

- In your Sports page body, insert:
{% newsbytag sports %}

etc.

If you don't want the index page to be the newspage (but another slug, e.g. news or blog, but still want to show all your latest posts in the home page, it's also possible - let me know.

PS What do you mean by "sortable"? Posts are always sorted in descending date order.


RE: News Manager (updated) - Carlos - 2014-05-17

News Manager 3.0 beta 20 available. Download - Info

NEW:
- added showTags custom setting. (If you don't want to display tags under the posts, enter showTags 0 in Custom Settings.)
- added NMNOPARAMPOST gsconfig setting (allows to have single post URLs without the /post/ prefix if using fancy URLs and your newspage is not index) (more info here)

CHANGES:
- renamed custom setting template to templateFile (was added in beta 19)

OTHER:
- small fixes
- completed several language files (thanks to the translators involved)

Thanks in advance for your feedback, even if it's only to tell me that it doesn't break anything. ;-)
I think this will be the last beta for 3.0.


RE: News Manager (updated) - Oleg06 - 2014-05-17

Carlos, already replace the line 176 in the file edit_settings.php
Code:
<span class="hint"><?php i18n('news_manager/UPDATE_HTACCESS'); ?></span>



RE: News Manager (updated) - Carlos - 2014-05-17

Sorry Oleg, I don't understand what you mean.


RE: News Manager (updated) - Oleg06 - 2014-05-17

Code:
<span class="hint"><?php i18n('news_manager/PRETTY_URLS_NOTE'); ?> <a href="load.php?id=news_manager&amp;htaccess"><?php i18n('MORE'); ?></a></span>
i18n('MORE'); translated as Другие (Other)
"UPDATE_HTACCESS" => "<b>Note:</b> You probably have to update your <a href=\"%s\">.htaccess</a> file!",


RE: News Manager (updated) - Carlos - 2014-05-17

That MORE string is reused/taken from the GS language file. It's at the left of "custom permalink structure" in GS settings (does it sound strange there too?)
I expected it to mean "more [info]" in most languages.
(I added this link back in NM 2.2.5)


RE: News Manager (updated) - Oleg06 - 2014-05-17

yes, in the language file mistranslation


RE: News Manager (updated) - Carlos - 2014-05-17

I can leave it like it is (no one complained since 2.2.5 :-)) or maybe replace that "more" by e.g. a plus sign (+)
Are you going to change that string in your GS translation?


RE: News Manager (updated) - Oleg06 - 2014-05-17

Yes, I have replaced the translate, you can leave as is


RE: News Manager (updated) - TeeJay - 2014-05-17

Hey,
I'm still busy with my school but after a bare reading the thing with a new way of hiding/showing tags, I wonder if
Code:
showfields title,date,author,image,content

still works? If yes, I find this extra setting a bit useless. Are you planning to remove the old way of doing the same?


RE: News Manager (updated) - Carlos - 2014-05-17

Yes, showfields works and will work.
You're right, showtags is just kind of a shortcut.

(I was going to add showtags at first, then I discarded it when added showfields. But the other day I thought it may be handy if you just don't want to display the post's tags and not reorder anything.)


RE: News Manager (updated) - Carlos - 2014-05-17

Ok, showtags will not be in 3.0. If there's a need for it I will add it back. Thank you TeeJay.