Thursday, 14 February 2019
  5 Replies
  746 Visits
0
Votes
Undo
Hi,

I am trying to echo all categories to an event in /administrator/components/com_jevents/icalevent/overview.php.

How do I do this? :o
6 years ago
·
#209148
Accepted Answer
0
Votes
Undo
Hello,

That's just an example of how we do it. You would also need to change $event as they is likely not defined in the event view.


If you are in the loop already try:

$row

instead of $event

Many thanks
Tony

JEvents Club members can get priority forum support at the Support Forum. As well as access to a variety of custom JEvents addons and benefits. Join the JEvents club today!Join the JEvents club today!

6 years ago
·
#209148
Accepted Answer
0
Votes
Undo
Hello,

That's just an example of how we do it. You would also need to change $event as they is likely not defined in the event view.


If you are in the loop already try:

$row

instead of $event

Many thanks
Tony

JEvents Club members can get priority forum support at the Support Forum. As well as access to a variety of custom JEvents addons and benefits. Join the JEvents club today!Join the JEvents club today!

6 years ago
·
#209145
0
Votes
Undo
Thanks alot!

I am getting a Call to a member function ev_id() on null error. I can't find the table _categories in db :o
6 years ago
·
#209133
0
Votes
Undo
This is the query we use to load in ALLCATEGORIES




$db = JFactory::getDbo();
$arr_catids = array();
$catsql = "SELECT cat.id, cat.title as name, cat.params FROM #__categories as cat WHERE cat.extension='com_jevents' ";
$db->setQuery($catsql);
$allcat_catids = $db->loadObjectList('id');

$db = JFactory::getDbo();
$db->setQuery("Select catid from #__jevents_catmap WHERE evid = " . $event->ev_id());
$allcat_eventcats = $db->loadColumn();

$allcats = array();
foreach ($allcat_eventcats as $catid)
{
if (isset($allcat_catids[$catid]))
{
$allcats[] = $allcat_catids[$catid]->name;
}
}
$categories = implode(", ", $allcats);



$categories should then output a comma seperated list.

JEvents Club members can get priority forum support at the Support Forum. As well as access to a variety of custom JEvents addons and benefits. Join the JEvents club today!Join the JEvents club today!

6 years ago
·
#209068
0
Votes
Undo
For multiple :)
6 years ago
·
#209061
0
Votes
Undo
Hello,

Is this for multiple or single category support on the events?

Many thanks
Tony

JEvents Club members can get priority forum support at the Support Forum. As well as access to a variety of custom JEvents addons and benefits. Join the JEvents club today!Join the JEvents club today!

  • Page :
  • 1
There are no replies made for this post yet.

Members Area

Show your support

Unlike many Joomla calendars we do not charge to download JEvents - please show your support for this project by becoming a member of the JEvents Club Club members get access to early releases, exclusive member support forums, and Silver and Gold members can use many exciting JEvents addons

Your membership will ensure that JEvents continues to be the best events calendar for Joomla.