Button link to #Respond
-
I’d like to have a button that links directly to the comment section of the post that is sent in the email. Basically the “Read more” URL with /#respond appended.
I’ve read the help section on Custom Shortcodes , but not sure how to access the post link to append to.
ie.. replacing example.comadd_filter('mailpoet_newsletter_shortcode_link', 'mailpoet_custom_shortcode_respond_link', 10, 4); function mailpoet_custom_shortcode_respond_link($shortcode, $newsletter, $subscriber, $queue) { // always return the shortcode if it doesn't match your own! if ($shortcode !== '[link:respond]') return $shortcode; $respond = '/#respond'; $respond_link = "<a href='http://example.com{$respond}'>Respond</a>"; return $respond_link; }Is there an easier way to go about doing this?
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
The topic ‘Button link to #Respond’ is closed to new replies.