Direct links to events are not working every time

  • Peter Mayer
  • Topic Author
  • Offline
  • New Member
  • New Member
More
9 years 5 months ago - 9 years 5 months ago #88895 by Peter Mayer
Hallo,

I have a strange problem. I want to link from a weekly timetable out on the respective dates of a series of events. Unfortunately, this only works sometimes and not at all the events. For events of a group it works sometimes and sometimes does not. If it doesn't work, it shows a list of the categories.

To create the links with a php script, I use the category and the alias from the table "events". How can I get that it always points to the correct date.

You can find the timetable at :
www.yoga-therapie-prien.de/index.php/stundenplan-temp?&W=45

Thanks a lot for your help
Last edit: 9 years 5 months ago by Peter Mayer.

Please Log in or Create an account to join the conversation.

More
9 years 5 months ago #88920 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Direct links to events are not working every time
Hi Peter

The easiest way would be go to Events Booking -> Configuration, look at SEF router settings tab, find the config option Insert Event ID, set it to Yes

Then check it again. It should help solving the issue

Regards,

Tuan

Please Log in or Create an account to join the conversation.

  • Peter Mayer
  • Topic Author
  • Offline
  • New Member
  • New Member
More
9 years 5 months ago #88962 by Peter Mayer
Replied by Peter Mayer on topic Direct links to events are not working every time
Thanks for your help!

This attempt does not was I appear... Check the link of an future date:

www.yoga-therapie-prien.de/index.php/stundenplan-temp?&W=46

Has anyone another Idea?

Please Log in or Create an account to join the conversation.

More
9 years 5 months ago #88981 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Direct links to events are not working every time
Hi Peter

So you are writing custom PHP script (not using Joomla code / running inside Joomla). If so, I am not sure if we can help as the link is really depends on Joomla core routing

Maybe you can attach the code you wrote here and give me same links which don't work so that I can look at it to see whether I can help with anything?

Tuan

Please Log in or Create an account to join the conversation.

  • Peter Mayer
  • Topic Author
  • Offline
  • New Member
  • New Member
More
9 years 5 months ago #89138 by Peter Mayer
Replied by Peter Mayer on topic Direct links to events are not working every time
Hi Tuan,

yes, you are right, I wrote an external script to display the time table. The script is included with costumPHP...
I believe that the essential point of the script is:

$content = "<a href='/index.php/component/eventbooking/$cat/$eventID-".$alias."' target=blank style='display:block; height:100%;'>$title</a>";

The variables are self explaning.

Thanks a lot for your help!
Peter

Please Log in or Create an account to join the conversation.

More
9 years 5 months ago #89171 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Direct links to events are not working every time
Hi Peter

That won't work due to the way Events Booking routing work. I would suggest that:

1. You create a hidden menu item, something called events or upcoming events to display list of events. Access to that page to see the format of links

2. The link will has this format:

/index.php/events/category-alias/event-alias (or /index.php/events/category-alias/EVENT_ID-event-alias

(events is the alias of the menu item you created)

3. Each time you add new event to the system, you will need to access to the above menu item again so that the links for the events will be generate

4. Modify the code to have the links in that format above

(The step #3 is important, sorry for that limitation but the code for Events Booking routing is difficult with other extensions router)

The other option is using none-sef routing. So the link will be index.php?option=com_eventbooking&view=event&id=ID_OF_EVENT

Tuan
The following user(s) said Thank You: Peter Mayer

Please Log in or Create an account to join the conversation.

Moderators: Tuan Pham Ngoc