Viewing the article ... (joomla content items)

Started by kai920, September 09, 2006, 02:09:28 PM

Previous topic - Next topic

SlammedDime

Quote from: kai920 on September 14, 2006, 10:31:07 PM
AirRideTalk: are you having the same problems with category viewing? ???
I was, along with sections, but I simply edited the php similar to what was done for articles.

Here is what my function looks like now, fwiw...
//Additions to the $txt array for the whos online
function add_to_txt(){

global $txt, $mosConfig_live_site, $mosConfig_sitename, $mosConfig_sef;

$txt['who_home'] = 'Viewing the home page of <a href="' . $mosConfig_live_site . '">' . $mosConfig_sitename . '</a>.';
$txt['who_article'] = 'Viewing the article <a href="' . ($mosConfig_sef !='1' ? $mosConfig_live_site . '/index.php?option=com_content&amp;task=view&amp;Itemid=%2$s&amp;id=%1$s' : sefReltoAbs ('index.php?option=com_content&amp;task=view&amp;Itemid=%2$s&amp;id=%1$s') . '%2$s/' ) . '">%3$s</a>.';
$txt['who_section'] = 'Viewing the section <a href="' . ($mosConfig_sef !='1' ? $mosConfig_live_site . '/index.php?option=com_content&amp;task=section&amp;Itemid=%2$s&amp;id=%1$s' : sefReltoAbs ('index.php?option=com_content&amp;task=section&amp;Itemid=%2$s&amp;id=%1$s') . '%2$s/' ) . '">%3$s</a>.';
$txt['who_blogsection'] = 'Viewing the section <a href="' . ($mosConfig_sef !='1' ? $mosConfig_live_site . '/index.php?option=com_content&amp;task=blogsection&amp;Itemid=%2$s&amp;id=%1$s' : sefReltoAbs ('index.php?option=com_content&amp;task=blogsection&amp;Itemid=%2$s&amp;id=%1$s')) . '">%3$s</a>.';
$txt['who_category'] = 'Viewing the category <a href="' . ($mosConfig_sef !='1' ? $mosConfig_live_site . '/index.php?option=com_content&amp;task=category&amp;Itemid=%2$s&amp;id=%1$s' : sefReltoAbs ('index.php?option=com_content&amp;task=category&amp;Itemid=%2$s&amp;id=%1$s') . '%2$s/') . '">%3$s</a>.';
$txt['who_blogcategory'] = 'Viewing the category <a href="' . ($mosConfig_sef !='1' ? $mosConfig_live_site . '/index.php?option=com_content&amp;task=category&amp;Itemid=%2$s&amp;id=%1$s' : sefReltoAbs ('index.php?option=com_content&amp;task=category&amp;Itemid=%2$s&amp;id=%1$s')) . '">%3$s</a>.';
$txt['who_newsfeeds'] = 'Viewing the <a href="' . ($mosConfig_sef !='1' ? $mosConfig_live_site . '/index.php?option=com_newsfeeds&amp;task=view&amp;Itemid=%d' : sefReltoAbs ('index.php?option=com_newsfeeds&amp;task=view&amp;Itemid=%d')) . '">News Feeds</a>.';
$txt['who_virtuemart'] = 'Shopping in the <a href="' . ($mosConfig_sef !='1' ? $mosConfig_live_site . '/index.php?option=com_virtuemart&amp;Itemid=%d' : sefReltoAbs ('index.php?option=com_virtuemart&amp;Itemid=%d')) . '">store</a>.';
$txt['who_sitesearch'] = 'Using the <a href="' . ($mosConfig_sef !='1' ? $mosConfig_live_site . '/index.php?option=com_search&amp;Itemid=%d' : sefReltoAbs ('index.php?option=com_search&amp;Itemid=%d')) . '">Site Search</a>.';
$txt['who_wiki'] = 'Viewing the <a href="' . ($mosConfig_sef !='1' ? $mosConfig_live_site . '/index.php?option=com_wikidoc&amp;Itemid=%d' : sefReltoAbs ('index.php?option=com_wikidoc&amp;Itemid=%d')) . '">Wiki</a>.';
}
SlammedDime
Former Lead Customizer
BitBucket Projects
GeekStorage.com Hosting
                      My Mods
SimpleSEF
Ajax Quick Reply
Sitemap
more...
                     

kai920

#41
Thanks for that... I found your 'who_blogcategory' was missing the appending . '%2$s/' near the end.

So now I have to figure out why I get these content/blogcategory/0/37/ (why there are 0's in my Itemid/URL)...

OK on this particular Blog-Category, I had selected two different categories from two different sections. After limiting it to just one section (one category) the link changed to blogcategory/14/37, which is good. So for this menu link, Who's Online is functioning correctly now.  :)

On another Blog-Category, I have selected the content from 4 different categories -- but they are all in the same section. I am not sure how this can be fixed but I'll play around with the settings.

kai920

Quote from: AirRideTalk on September 15, 2006, 04:34:04 AM
//Additions to the $txt array for the whos online
function add_to_txt(){

global $txt, $mosConfig_live_site, $mosConfig_sitename, $mosConfig_sef;

$txt['who_home'] = 'Viewing the home page of <a href="' . $mosConfig_live_site . '">' . $mosConfig_sitename . '</a>.';
$txt['who_article'] = 'Viewing the article <a href="' . ($mosConfig_sef !='1' ? $mosConfig_live_site . '/index.php?option=com_content&amp;task=view&amp;Itemid=%2$s&amp;id=%1$s' : sefReltoAbs ('index.php?option=com_content&amp;task=view&amp;Itemid=%2$s&amp;id=%1$s') . '%2$s/' ) . '">%3$s</a>.';
$txt['who_section'] = 'Viewing the section <a href="' . ($mosConfig_sef !='1' ? $mosConfig_live_site . '/index.php?option=com_content&amp;task=section&amp;Itemid=%2$s&amp;id=%1$s' : sefReltoAbs ('index.php?option=com_content&amp;task=section&amp;Itemid=%2$s&amp;id=%1$s') . '%2$s/' ) . '">%3$s</a>.';
$txt['who_blogsection'] = 'Viewing the section <a href="' . ($mosConfig_sef !='1' ? $mosConfig_live_site . '/index.php?option=com_content&amp;task=blogsection&amp;Itemid=%2$s&amp;id=%1$s' : sefReltoAbs ('index.php?option=com_content&amp;task=blogsection&amp;Itemid=%2$s&amp;id=%1$s')) . '">%3$s</a>.';
$txt['who_category'] = 'Viewing the category <a href="' . ($mosConfig_sef !='1' ? $mosConfig_live_site . '/index.php?option=com_content&amp;task=category&amp;Itemid=%2$s&amp;id=%1$s' : sefReltoAbs ('index.php?option=com_content&amp;task=category&amp;Itemid=%2$s&amp;id=%1$s') . '%2$s/') . '">%3$s</a>.';
$txt['who_blogcategory'] = 'Viewing the category <a href="' . ($mosConfig_sef !='1' ? $mosConfig_live_site . '/index.php?option=com_content&amp;task=category&amp;Itemid=%2$s&amp;id=%1$s' : sefReltoAbs ('index.php?option=com_content&amp;task=category&amp;Itemid=%2$s&amp;id=%1$s')) . '">%3$s</a>.';
$txt['who_newsfeeds'] = 'Viewing the <a href="' . ($mosConfig_sef !='1' ? $mosConfig_live_site . '/index.php?option=com_newsfeeds&amp;task=view&amp;Itemid=%d' : sefReltoAbs ('index.php?option=com_newsfeeds&amp;task=view&amp;Itemid=%d')) . '">News Feeds</a>.';
$txt['who_virtuemart'] = 'Shopping in the <a href="' . ($mosConfig_sef !='1' ? $mosConfig_live_site . '/index.php?option=com_virtuemart&amp;Itemid=%d' : sefReltoAbs ('index.php?option=com_virtuemart&amp;Itemid=%d')) . '">store</a>.';
$txt['who_sitesearch'] = 'Using the <a href="' . ($mosConfig_sef !='1' ? $mosConfig_live_site . '/index.php?option=com_search&amp;Itemid=%d' : sefReltoAbs ('index.php?option=com_search&amp;Itemid=%d')) . '">Site Search</a>.';
$txt['who_wiki'] = 'Viewing the <a href="' . ($mosConfig_sef !='1' ? $mosConfig_live_site . '/index.php?option=com_wikidoc&amp;Itemid=%d' : sefReltoAbs ('index.php?option=com_wikidoc&amp;Itemid=%d')) . '">Wiki</a>.';
}


Just want to say that this helped me again (for bridge 1.1.7)

Advertisement: