Hi,
So is it possible when we are listing our events to link the url without it being the upcoming date url?
For example - /news-events/my-event/ instead of /news-events/my-event/view/2010-08-20
if so, how do I go about doing this?
John
This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.
Please use forum.silverstripe.org for any new questions
(announcement).
The forum archive will stick around, but will be read only.
You can also use our Slack channel
or StackOverflow to ask for help.
Check out our community overview for more options to contribute.
Hi,
So is it possible when we are listing our events to link the url without it being the upcoming date url?
For example - /news-events/my-event/ instead of /news-events/my-event/view/2010-08-20
if so, how do I go about doing this?
John
I think by default it will pull in the most recent date if you don't provide one in the URL, no?
Yeh by default, it does something like /news-events/my-event/view/2010-08-20
but I would like it just to do /news-events/my-event/
john
Sounds like you want to use the Event $Link function rather than the DateTime $Link. Remember that the Events control returns DateTime objects, not Events, so $Event.Link should do the trick. Just know that you've inhibited the scalability of your calendar in doing so because if you ever have more than one event on a given day, you'll lose a lot of features.
Excellent. Thanks!
I could be wrong in my thinking but here goes:
For SEO purposes I rather have an event that has multiple dates all point to a "master" event page (of that event). This way I am not having possibly tons of duplicate content and outdated that is indexed. For example, on one of our repeating events, the older date page got indexed into the search engine. And even though it listed the upcoming dates on that page, it was an "Outdated" event that was indexed. If that page was more of a "Master" event page then it wouldn't have been outdated.
On top of this all, all these event date links are producing a web of links to content that is not unique. A user who clicks on the date links will have a general expectation that there is something unique on the page they are going to. But will find that it is just same as the other date links for that event.
So, I am just changing it up a bit. I am not saying what you have setup is wrong in any way. I just have a different way of thinking. Keep up the amazing work UncleCheese! and thanks for your continuos help.