{"id":1896559,"date":"2019-10-18T13:19:28","date_gmt":"2019-10-18T17:19:28","guid":{"rendered":"https:\/\/staging.theeventscalendar.com\/knowledgebase\/make-organizer-email-a-mailto-field-2\/"},"modified":"2020-03-24T12:15:07","modified_gmt":"2020-03-24T16:15:07","slug":"make-organizer-email-a-mailto-field","status":"publish","type":"post","link":"https:\/\/staging.theeventscalendar.com\/knowledgebase\/make-organizer-email-a-mailto-field\/","title":{"rendered":"Link Organizer Email Address to a New Email"},"content":{"rendered":"\n<p>With this&nbsp;snippet, you can change the organizer email on the single event page to a clickable <kbd>mailto:<\/kbd> field. Interested visitors can click and contact the organizer from their email client of choice.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/images.theeventscalendar.com\/kb\/uploads\/2015\/04\/Screen-Shot-2015-04-28-at-4.23.42-PM-665x216.png\" alt=\"KB - organizer mailto 2\"\/><\/figure>\n\n\n\n<p>To add the <kbd>mailto:<\/kbd> you will need to setup a <a href=\"https:\/\/staging.theeventscalendar.com\/knowledgebase\/k\/customizing-template-files-2\/\" target=\"_blank\" rel=\"noreferrer noopener\" aria-label=\" (opens in a new tab)\">template override<\/a>. In this case, that means copying:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">plugins\/the-events-calendar\/src\/views\/modules\/meta\/organizer.php<\/pre>\n\n\n\n<p>To:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">themes\/YOUR_THEME\/tribe-events\/modules\/meta\/organizer.php<\/pre>\n\n\n\n<p>Then you need to make a small change. In your favorite editor, scroll down to around line 55. You should see this code:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: php; gutter: false; title: ; notranslate\" title=\"\">\n&lt;?php echo esc_html( $email ); &gt;\n<\/pre><\/div>\n\n\n<p>Simply replace this with:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: php; gutter: false; title: ; notranslate\" title=\"\">\n&lt;a href=&quot;mailto:&lt;?php echo esc_attr( $email ) ?&gt;&quot;&gt;&lt;?php echo esc_html( $email ); ?&gt;&lt;\/a&gt;\n<\/pre><\/div>\n\n\n<p>That&#8217;s it, you&#8217;re done!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>With this&nbsp;snippet, you can change the organizer email on the single event page to a clickable mailto: field. Interested visitors can click and contact the organizer from their email client of choice. To add the mailto: you will need to setup a template override. In this case, that means copying: plugins\/the-events-calendar\/src\/views\/modules\/meta\/organizer.php To: themes\/YOUR_THEME\/tribe-events\/modules\/meta\/organizer.php Then you&#8230;<\/p>\n","protected":false},"author":2,"featured_media":1955565,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"_kad_blocks_custom_css":"","_kad_blocks_head_custom_js":"","_kad_blocks_body_custom_js":"","_kad_blocks_footer_custom_js":"","_swpsp_post_exclude":false,"_kad_post_transparent":"","_kad_post_title":"","_kad_post_layout":"","_kad_post_sidebar_id":"","_kad_post_content_style":"","_kad_post_vertical_padding":"","_kad_post_feature":"","_kad_post_feature_position":"","_kad_post_header":false,"_kad_post_footer":false,"ep_exclude_from_search":false,"footnotes":""},"categories":[79],"tags":[115,25,58],"stellar-product-taxonomy":[161],"class_list":["post-1896559","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-snippets","tag-classic-editor","tag-customizations","tag-php","stellar-product-taxonomy-the-events-calendar"],"acf":[],"taxonomy_info":{"category":[{"value":79,"label":"Snippets"}],"post_tag":[{"value":115,"label":"Classic editor"},{"value":25,"label":"Customizations"},{"value":58,"label":"PHP"}],"stellar-product-taxonomy":[{"value":161,"label":"The Events Calendar"}]},"featured_image_src_large":["https:\/\/images.theeventscalendar.com\/kb\/uploads\/2023\/02\/social-share-1024x538.png",1024,538,true],"author_info":{"display_name":"zach","author_link":"https:\/\/staging.theeventscalendar.com\/knowledgebase\/author\/zach\/"},"comment_info":0,"category_info":[{"term_id":79,"name":"Snippets","slug":"snippets","term_group":0,"term_taxonomy_id":79,"taxonomy":"category","description":"","parent":0,"count":136,"filter":"raw","term_order":"0","cat_ID":79,"category_count":136,"category_description":"","cat_name":"Snippets","category_nicename":"snippets","category_parent":0}],"tag_info":[{"term_id":115,"name":"Classic editor","slug":"classic-editor","term_group":0,"term_taxonomy_id":115,"taxonomy":"post_tag","description":"","parent":27,"count":18,"filter":"raw","term_order":"0"},{"term_id":25,"name":"Customizations","slug":"customizations","term_group":0,"term_taxonomy_id":25,"taxonomy":"post_tag","description":"","parent":0,"count":177,"filter":"raw","term_order":"0"},{"term_id":58,"name":"PHP","slug":"php","term_group":0,"term_taxonomy_id":58,"taxonomy":"post_tag","description":"","parent":20,"count":128,"filter":"raw","term_order":"0"}],"_links":{"self":[{"href":"https:\/\/staging.theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/posts\/1896559","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/staging.theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/staging.theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/staging.theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/staging.theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/comments?post=1896559"}],"version-history":[{"count":1,"href":"https:\/\/staging.theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/posts\/1896559\/revisions"}],"predecessor-version":[{"id":1956255,"href":"https:\/\/staging.theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/posts\/1896559\/revisions\/1956255"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/staging.theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/media\/1955565"}],"wp:attachment":[{"href":"https:\/\/staging.theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/media?parent=1896559"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/staging.theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/categories?post=1896559"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/staging.theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/tags?post=1896559"},{"taxonomy":"stellar-product-taxonomy","embeddable":true,"href":"https:\/\/staging.theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/stellar-product-taxonomy?post=1896559"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}