Article ID/URL in Category Blog Layout - Joomla! Forum - community, help and support


i creating social media sharing module display share links facebook, twitter , g+.

i have 1 blog category category blog layout, module embedded in top of article display between article details (published date, author, etc) , content.

everything working on individual article pages using following snippets:

for article title:

code: select all

$option = jrequest::getcmd('option');
$view = jrequest::getcmd('view');
if ($option=="com_content" && $view=="article") {
    $ids = explode(':',jrequest::getstring('id'));
    $article_id = $ids[0];
    $article =& jtable::getinstance("content");
    $article->load($article_id);
    $title = $article->get("title");
}


and url:

code: select all

$url    = juri::getinstance();
$url    = $url->tostring();


my problem social media buttons display on category blog layout page. have set display full articles in full width column.

i able pick url article , it's title category blog layout. have ideas?

a plugin more appropriate. lot of social media sharing extensions exist.

on blog page, id each article have fetched. not on url.

the "onafterdisplaytitle" event can used put them after title of article.
http://docs.joomla.org/plugin/events/content#onafterdisplaytitle





Comments

Popular posts from this blog

How to change text Component easybook reloaded *newbee* - Joomla! Forum - community, help and support

After Effect warning: A problem occurred when processing OpenGL commands

Preconditions Failed. - Joomla! Forum - community, help and support