• Resolved john_unlimited

    (@john_unlimited)


    Is it possible to modify the URL field so it outputs something a little more user friendly?

    For example if I put in a link in the URL field, the page text, instead of displaying the full link, would say ‘Click here for more information’ instead?

    Thanks,
    John

Viewing 12 replies - 1 through 12 (of 12 total)
  • Plugin Author Joe Dolson

    (@joedolson)

    I’m not sure exactly what you’re trying to do; what template tag are you using right now? There’s a lot of flexibility on what you can display, but it depends on your choice of template tag.

    Thread Starter john_unlimited

    (@john_unlimited)

    Thanks for replying. This is the template code:

    [my_calendar_upcoming category="3,4" template="{image} {title} , {date}, {time} {description} {link}" type="month" order="asc"]

    So for example if I put ‘www.link-example-to-more-information.co.uk/’ in the URL field, I would like the the output HTML to be linked text simply saying ‘More Information’, instead of outputting the the whole www… link. does that make sense?

    John

    Plugin Author Joe Dolson

    (@joedolson)

    Then I’d suggest using HTML to wrap the link, e.g.

    <a href='{link'}>More information</a>, or using one of the links with HTML, such as {details} or {link_title}.

    You can review the list of template tags on the Help screen for other options, as well.

    Thread Starter john_unlimited

    (@john_unlimited)

    I Think I might have been going at the wrong. I’ve been trying to add HTML within the shortcode, instead of creating a new template. Thanks Joe.

    Plugin Author Joe Dolson

    (@joedolson)

    It’s definitely considerably easier to handle templates created through the template manager!

    Thread Starter john_unlimited

    (@john_unlimited)

    I’ve got the templates woirking, but still not quite doing what I’d like :/

    I’d like the URL link to appear when the a link input in the event creator, but not when there isn’t one.

    For Example If I entered a link into the URL field, the ‘more information’ text would appear, but if I did not populate the URL field, then nothing is displayed. The the moment using HTML will just generate a dead/non link. Can it be made more dynamic?

    John

    Plugin Author Joe Dolson

    (@joedolson)

    You can use {link before=”More Information“}. Or, you can use the {details} shortcode, which has configurable text by going to My Calendar > Settings > Text > Event details link text

    Thread Starter john_unlimited

    (@john_unlimited)

    Cheers for your help Joe.

    It’s an awesome plugin, and does a great job, i just can’t get it to do what I need.

    I was trying to use the URL field as a ticket link field, but I can understand why it would not be set up to do that in the free version.

    Thanks for your help.
    john

    Plugin Author Joe Dolson

    (@joedolson)

    There’s no reason you can’t do that, as far as I can understand, but perhaps there’s something I don’t understand about what you’re trying to do.

    Thread Starter john_unlimited

    (@john_unlimited)

    Ok, here’s what I’ve got it doing, and what I’m trying to do. it does seem simple, I just cant find a workign method…

    Plugin Author Joe Dolson

    (@joedolson)

    I’m pretty sure that what I suggested above will work; but I can see that it got munged by the forum software, so what you see above doesn’t actually look right.

    But what you need is to include the link wrapper in your before and after attributes. Template tags only render before and after attributes if the tag is returning content, so they won’t render if there’s no link.

    Let’s see if this renders correctly:

    {link before="<a href='" after="'>Click to Book Tickets</a>"}

    Thread Starter john_unlimited

    (@john_unlimited)

    That works, thanks for your patience and understanding Joe.

Viewing 12 replies - 1 through 12 (of 12 total)
  • The topic ‘Can I modify the details template to make a user friendly URL field?’ is closed to new replies.