Events Made Easy Forums How do I … Nice URLs/Permalinks

Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #42854
    Anonymous
    Inactive

    I have a problem handing over the nice URLs created by the plugin to Facebook Like and Send button.

    Currently, I’m using .urlencode(get_permalink($post->ID)). in that piece of FB code to get the URL of the post or page. On event listings made with Event Manager Extended that results in example.com/events/.

    What would the correct piece of PHP be to call the EME URLs?

    #47769
    Franky
    Keymaster

    For a single event:

    $event=eme_get_event($eventID);
    .urlencode(eme_event_url($event));

    If you want this inside a EME format setting, it’s easier:

    .urlencode(#_EVENTPAGEURL);

    #47770
    Anonymous
    Inactive

    Err, thanks Franky. Still can’t work it out (little wonder since I only know enough about PHP to be a thread to my own websites).

    This is the function I’m using to put the buttons on the end of posts and pages

    <br />
    function insertFootNote($content) {<br />
    if(!is_feed() && is_singular() && !is_page(array('events','wir'))) {<br />
    $content .= '<div class="fb-footnote"><fb:like href='.urlencode(get_permalink($post->ID)).' send="true" layout="button_count" width="450" show_faces="false" action="recommend" font="verdana"></fb:like></div>';<br />
    }<br />
    return $content;<br />
    }<br />
    add_filter ('the_content', 'insertFootNote');<br />

    Thinkable – if somebody is kind enough to give me the correct syntax – would be to amend this function with

    <br />
    if(is_page('envents')) {<br />
    $content .= '<div class="fb-footnote"><fb:like href='.urlencode(eme_event_url($event)).' send="true" BLA BLA<br />

    But I don’t get it to work. Tried several ideas like

    <br />
    if(is_page('events')) {<br />
    $event=eme_get_event($eventID);<br />
    $content .= '<div class="fb-footnote"><fb:like href='.urlencode(eme_event_url($event)).' send="true" BLA BLA<br />

    To no avail. I’m a comlplete PHP illiterate.

    Could you please help me?!

    #47771
    Franky
    Keymaster

    If coding this, you need to get the event ID. Look into the filters available for event lists: http://www.e-dynamics.be/wordpress/?cat=41

    #47772
    Anonymous
    Inactive

    I have exactly the same problem, FB like button doesn’t share the single event page, it does share (example.com/events/) only 🙁 Please, would tell us how to fix this?

    #47773
    Anonymous
    Inactive

    helloo? 🙁

    #47774
    Franky
    Keymaster

    What, hello? The facebook button issue is not related to the problem at hand here, hijacking a thread is not polite. Also: when searching old posts you’ll find a solution for this problem (I believe admintiger is the person who found a solution).

    #47775
    Anonymous
    Inactive

    Thanks for replying my politely! but again still cant find that post by admintiger ….would you post the link please!

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