Support » Plugin: WpDevArt Social comments » How can I get the post url inside shortcode?

  • Resolved eduardofrd

    (@eduardofrd)


    I’m using the Facebook comments shortcode in posts, but I want to “curent_url” attribute get the post url by itself.

    Something like that:

    [wpdevart_facebook_comment curent_url=”GET THE POST URL BY ITSELF” title_text=”Facebook Comment” order_type=”social” title_text_color=”#000000″ title_text_font_size=”22″ title_text_font_famely=”monospace” title_text_position=”left” width=”100%” bg_color=”#d4d4d4″ animation_effect=”random” count_of_comments=”2″ ]

    How can I do this?

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author wpdevart

    (@wpdevart)

    Hi dear user.

    Try this code –

    <?php echo do_shortcode( '[wpdevart_facebook_comment curent_url="'.get_permalink().'" order_type="social" title_text="Facebook Comment" title_text_color="#000000" title_text_font_size="22" title_text_font_famely="monospace" title_text_position="left" width="100%" bg_color="#d4d4d4" animation_effect="random" count_of_comments="3" ]' ); ?>

    Thanks.

    Thanks! Do I have to put this code in the theme or directly in the posts?

    did not work :/

    Plugin Author wpdevart

    (@wpdevart)

    Hi dear user.

    You should insert it from the code. Also, try this shortcode in your post/page –

    [wpdevart_facebook_comment curent_url="'.get_permalink().'" order_type="social" title_text="Facebook Comment" title_text_color="#000000" title_text_font_size="22" title_text_font_famely="monospace" title_text_position="left" width="100%" bg_color="#d4d4d4" animation_effect="random" count_of_comments="3" ]

    Thanks.

    nops, did not work 🙁

    I´m using elementor theme builder, if this information is useful

    Plugin Author wpdevart

    (@wpdevart)

    Dear user.

    We can’t say if it will work for elementor theme builder, but it’s a standard WordPress shortcode and should work with a standard theme.

    Thanks.

Viewing 6 replies - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.