Events Made Easy Forums How do I … #_ATTribute in Location

Tagged: 

Viewing 15 posts - 1 through 15 (of 15 total)
  • Author
    Posts
  • #53517
    Anonymous
    Inactive

    Single event show format is like see picture.
    The attribute ‘Web’ is set in location, see picture.
    The result in event display shoud be an URL pointing to value of ‘Web’. But it does not point there but to the event itself,
    see picture.
    What is wrong? Or what is the right way to achieve this?
    Thank you.

    #53519
    Franky
    Keymaster

    Because the #_ATT{Web} is an attribute for an event, not for a location, meaning that you need to define it when creating an event, not a location.
    Although in your case: why not just use #_LOCATION in your single event format, and point the linked location to the external url?

    #53525
    Anonymous
    Inactive

    Franky: “why not just use…” – let me try to explain:
    1. When displaying event details I add some basic details about location – i.e. Address, Town, some short Description and Directions. This data tells the user how to get there.
    2. On other place of my web I supply list of locations. Click on an list entry shows the same data as above <b>plus list of all events for that location</b> (both past and future) by means of ‘[events_list scope=all limit=0 location_id=this_location]‘.
    Only when the user wants to see more about location he can go to the location’s website. And this was the field #_ATT{Web} which I wanted to use as location’s website url.
    That’s it. In other words it would be useful if in location settings was another placeholder called e.g. #_LOCATION_WEBSITE.
    BTW, I am using your plugin for about 4 years to my satisfaction. The events are golf tournaments, the locations are golf courses. I keep nearly seven hundreds of events and more than 1 hundred of locations and these figures are growing.
    Josef

    #53527
    Franky
    Keymaster

    Well ok, but my explanation stands 🙂
    In your case: you refer to an attribute for a location in the single event format: the event doesn’t know #_ATT{Web} belongs to a location, so it tries to find it’s own value for it (which is empty): empty link results in same page …
    So, for now: you need to define the location website when creating the event by adding the attribute value there, if you really want them to directly jump to an external site.
    The extra placeholder for the location is useless: #_LOCATION already points to the external url if you fill that in when creating the location, but of course then you can’t show the location details, since clicking on a location list will forward you to the external site.

    I’ll add a placeholder #_MYLOCATIONATT{xx} to get the relevant location att inside the event, that will make things easier in the next version 🙂
    See this change: https://plugins.trac.wordpress.org/changeset/1094471/

    #53528
    Franky
    Keymaster

    Btw: if you like EME, please post a link in the Showcase forum, so everybody can take a look at your work!

    #53531
    Anonymous
    Inactive

    Thank you, I understand your explanation. As to

    So, for now: you need to define…

    this is tedious as there might be many events at one location.
    Now I am trying to understand the proposed #_MYLOCATIONATT{xx}: does it mean that if one defines an attribute in location, say ‘Web’ with some value, then #_MYLOCATIONATT{Web} pulls the Web’s value into event?
    As to Show case, I will post the link to my website there. The weak point is that it is in Czech language which is spoken by about 0.14 % of overall population.

    #53532
    Franky
    Keymaster

    Concernong the new placeholder; yes, that will be the case.

    #53534
    Anonymous
    Inactive

    Thank you, this sounds good, looking forward.

    #53540
    Anonymous
    Inactive

    Franky, I have good news!

    I’ll add a placeholder #_MYLOCATIONATT{xx} to get the relevant location att inside the event, that will make things easier in the next version 🙂
    See this change: https://plugins.trac.wordpress.org/changeset/1094471/

    I tested (on a local website) the solution you proposed applying the code change to events-manager.php and can tell you that IT WORKS SUPERBLY!!! In location I declare #_ATTribute ‘Web’ value of which is URL of location and on event page I define
    <a href="#_MYLOCATIONATT{Web}">location website</a>
    Thank you very much.

    #59389
    Anonymous
    Inactive

    Hi Franky,

    I see you referenced #_LOCATION here, but it is not listed under the Event Placeholders in the relevant doc page at https://www.e-dynamics.be/wordpress/category/documentation/7-placeholders/7-2-events/. Please add it for future users 🙂

    #59392
    Franky
    Keymaster

    See the doc on event placeholders:

    Location placeholders
    Every location placeholder can be used inside an event as well, see the doc for location placeholders.
    If you have enabled the Google Map integration, you can use #_MAP to display a map. It is also possible to use #_MAP in the events list page.

    #59398
    Anonymous
    Inactive

    Lol I can’t believe I missed that!

    You might want to add a link at that spot in the Event Placeholders doc. 🙂

    #59399
    Anonymous
    Inactive

    Actually, #_LOCATION isn’t listed on the Location Placeholders page either. I suppose it’s the same as #_LOCATIONNAME? That’s how it worked for me.

    #59402
    Franky
    Keymaster

    This is a post from 2015, #_LOCATION might have been correct at that time but the doc is the correct place to look for placeholders.

    #59404
    Anonymous
    Inactive

    Thanks Franky 🙂

Viewing 15 posts - 1 through 15 (of 15 total)
  • The forum ‘How do I …’ is closed to new topics and replies.
Scroll to Top