{"id":1896511,"date":"2019-10-18T13:19:18","date_gmt":"2019-10-18T17:19:18","guid":{"rendered":"https:\/\/theeventscalendar.com\/knowledgebase\/adding-content-above-or-below-community-events-pages\/"},"modified":"2026-04-09T15:11:45","modified_gmt":"2026-04-09T19:11:45","slug":"customizing-community-pages","status":"publish","type":"post","link":"https:\/\/theeventscalendar.com\/knowledgebase\/customizing-community-pages\/","title":{"rendered":"Customizing Community Events Pages"},"content":{"rendered":"\n<p>See also: <a href=\"https:\/\/theeventscalendar.com\/knowledgebase\/customizing-community-events-submission-form\/\">Customizing the Community Event Submission Form<\/a><\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"template-tags\">Adding Content Above or Below Community Events Elements<\/h2>\n\n\n\n<p>You may want to include some instructions for your users at the top of the Community Events submission form, or add some notes or sponsor information at the <em>bottom<\/em> of the &#8220;My Events&#8221; page. But the Community Events submission form and &#8220;My Events&#8221; pages are not <em>actual<\/em> WordPress pages, so to add content above or below these pages, you&#8217;ll need to do some customization. If you want to add content above or below Community Events pages and <strong>only<\/strong> above these pages, not any other calendar pages, then using template tags may be a great solution.<\/p>\n\n\n\n<p>There are four main template tags that would work well in this situation, which are as follows:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><kbd>tribe_events_community_form_before_template<\/kbd>\n<ul class=\"wp-block-list\">\n<li>A template tag for adding content above the Community Events submission page.<\/li>\n<\/ul>\n<\/li>\n\n\n\n<li><kbd>tribe_events_community_form_after_template<\/kbd>\n<ul class=\"wp-block-list\">\n<li>A template tag for adding content below the Community Events submission page.<\/li>\n<\/ul>\n<\/li>\n\n\n\n<li><kbd>tribe_ce_before_event_list_top_buttons<\/kbd>\n<ul class=\"wp-block-list\">\n<li>A template tag for adding content above the &#8220;My Events&#8221; page.<\/li>\n<\/ul>\n<\/li>\n\n\n\n<li><kbd>tribe_ce_after_event_list_table<\/kbd>\n<ul class=\"wp-block-list\">\n<li>A template tag for adding content below the &#8220;My Events&#8221; page.<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n\n\n\n<p>You can use the same callback function a number of times, which will be exemplified as follows: Let&#8217;s say you wanted to add a simple bit of text, like &#8220;Sponsored by The Events Calendar&#8221; at the top the Community Events <strong>submission<\/strong> page only. You could write a code snippet like this to do just that:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: php; title: ; notranslate\" title=\"\">\nfunction tribe_add_community_sponsor_message() {\n    echo &#039;Sponsored by &lt;a href=&quot;https:\/\/theeventscalendar.com&quot;&gt;The Events Calendar&lt;\/a&gt;&#039;;\n}\n\nadd_action( &#039;tribe_events_community_form_before_template&#039;, &#039;tribe_add_community_sponsor_message&#039; );\n\ufeff\n<\/pre><\/div>\n\n\n<p>\u261d\ufe0f This would add the sponsor text above the submission page, but no place else.<\/p>\n\n\n\n<p>If you wanted to add this bit of content to <strong>all four<\/strong> locations, then you would just tie the callback function (which is <code>tribe_add_community_sponsor_message<\/code>, in the case of this example) to <strong>all four<\/strong> template tags, like this:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: php; title: ; notranslate\" title=\"\">\nfunction tribe_add_community_sponsor_message() {\n    echo &#039;Sponsored by &lt;a href=&quot;https:\/\/theeventscalendar.com&quot;&gt;The Events Calendar\/a&gt;&#039;;\n}\n\n\/\/ Above the submission page content.\nadd_action( &#039;tribe_events_community_form_before_template&#039;, &#039;tribe_add_community_sponsor_message&#039; );\n\n\/\/ Below the submission page content.\nadd_action( &#039;tribe_events_community_form_after_template&#039;, &#039;tribe_add_community_sponsor_message&#039; );\n\n\/\/ Above the &quot;My Events&quot; list page content.\nadd_action( &#039;tribe_ce_before_event_list_top_buttons&#039;, &#039;tribe_add_community_sponsor_message&#039; );\n\n\/\/ Below the &quot;My Events&quot; list page content.\nadd_action( &#039;tribe_ce_after_event_list_table&#039;, &#039;tribe_add_community_sponsor_message&#039; );\n\n<\/pre><\/div>\n\n\n<p>To implement the change, you need to add the code snippet to your WordPress site (see&nbsp;<a href=\"https:\/\/theeventscalendar.com\/knowledgebase\/best-practices-for-implementing-custom-code-snippets\/\">Using Custom Code Snippets<\/a>). Ensure to purge your site\u2019s cache after saving the changes.<\/p>\n\n\n\n<h4 class=\"wp-block-heading\" id=\"custom-templates\">Advanced Option: Custom Theme Templates<\/h4>\n\n\n\n<p>For a truly advanced level of control and customization ability, you may want to make custom theme templates for the Community Events templates outright. This would let you heavily customize the layout of these pages to suit your needs, and would allow for the easier addition of things like iFrames, video embeds, inline JavaScript, and complex HTML layouts of content.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"using-extension\">Modifying Community Events Page Titles<\/h2>\n\n\n\n<p>One of the most common questions we get from users of the Community Events add-on is, &#8220;How do I change the page title on the Community Pages?&#8221; &nbsp;We&#8217;ve compiled a couple of scenarios into one post and hopefully some of these code snippets will help you out! &nbsp;If what you&#8217;re needing isn&#8217;t here, feel free to open a new topic at our help desk, and we&#8217;ll help you out!<\/p>\n\n\n\n<p><strong>Changing the Event Submission page title<\/strong><\/p>\n\n\n\n<p>You can easily change the page title on the submission form using the <code>tribe_events_community_submit_event_page_title<\/code>&nbsp;filter. Just paste the following into your theme&#8217;s <code>functions.php<\/code> file:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: php; title: ; notranslate\" title=\"\">\nadd_filter( &#039;tribe_events_community_submit_event_page_title&#039;, &#039;change_the_title&#039; );\nfunction change_the_title() {\n\treturn &#039;Your New Title Goes Here&#039;;\n}\n<\/pre><\/div>\n\n\n<p><strong>Changing the My Events page title<\/strong><\/p>\n\n\n\n<p>You can also change the page title on the My Events page using the <code>tribe_events_community_event_list_page_title<\/code> filter. Just paste the following into your theme&#8217;s <code>functions.php<\/code> file:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: php; title: ; notranslate\" title=\"\">\nadd_filter( &#039;tribe_events_community_event_list_page_title&#039;, &#039;change_the_title&#039; );\nfunction change_the_title() {\n\treturn &#039;Your New Title Goes Here&#039;;\n}\n<\/pre><\/div>\n\n\n<h2 class=\"wp-block-heading\" id=\"h-displaying-all-events-associated-with-a-user-in-community-my-events\">Displaying All Events Associated with a User in Community: My Events<\/h2>\n\n\n\n<p>When using the Community plugin, you might notice that viewing the &#8220;My Events&#8221; tab only shows events that have been submitted through the frontend Community form, and you may want to change this. Events that have been added through the backend won&#8217;t show in &#8220;My Events&#8221;. This is the intended default behavior, as the plugin was designed to allow users to submit events through the frontend and contribute directly to the calendar.<\/p>\n\n\n\n<p>However, some customers have reached out to us with a need to add events on behalf of their users. They wanted these events to appear in &#8220;My Events&#8221; so the users could view them. If you would like to achieve the same and have events added through both the frontend and backend to appear in &#8220;My Events,&#8221; you can use the snippet below to accomplish this.<br><br>Paste this snippet within your themes function.php file or use this handy <a href=\"https:\/\/wordpress.org\/plugins\/code-snippets\/\" target=\"_blank\" rel=\"noreferrer noopener\">Code Snippets plugin<\/a>. You can learn more about using custom code snippets in our <a href=\"https:\/\/theeventscalendar.com\/knowledgebase\/k\/best-practices-for-implementing-custom-code-snippets\/\" target=\"_blank\" rel=\"noreferrer noopener\">knowledegebase<\/a>.<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: php; title: ; notranslate\" title=\"\">\nadd_filter(&#039;tribe_community_events_get_event_query&#039;, &#039;get_events&#039;, 15, 3);\n\n\/**\n * Retrieves events based on the provided arguments.\n *\n * @param mixed $data Data to filter.\n * @param array $args Query arguments.\n * @param bool  $full Whether to return the full query.\n *\n * @return \\WP_Query The filtered events query.\n *\/\nfunction get_events($data, $args, $full): \\WP_Query {\n    unset($args&#x5B;&#039;meta_query&#039;]);\n    return tribe_get_events($args, $full);\n}\n<\/pre><\/div>\n\n\n<p>That&#8217;s it! Now you will be able to see all of your events in Community: My Events.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>See also: Customizing the Community Event Submission Form Adding Content Above or Below Community Events Elements You may want to include some instructions for your users at the top of the Community Events submission form, or add some notes or sponsor information at the bottom of the &#8220;My Events&#8221; page. But the Community Events submission&#8230;<\/p>\n","protected":false},"author":3,"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":[24,120],"tags":[25,37,58],"stellar-product-taxonomy":[152],"class_list":["post-1896511","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-customizing","category-community-events","tag-customizations","tag-extension","tag-php","stellar-product-taxonomy-community-events"],"acf":[],"taxonomy_info":{"category":[{"value":24,"label":"Customizations"},{"value":120,"label":"Event Submissions"}],"post_tag":[{"value":25,"label":"Customizations"},{"value":37,"label":"Extension"},{"value":58,"label":"PHP"}],"stellar-product-taxonomy":[{"value":152,"label":"Community"}]},"featured_image_src_large":["https:\/\/images.theeventscalendar.com\/kb\/uploads\/2023\/02\/social-share-1024x538.png",1024,538,true],"author_info":{"display_name":"Jaime Marchwinski","author_link":"https:\/\/theeventscalendar.com\/knowledgebase\/author\/jaimetri-be\/"},"comment_info":0,"category_info":[{"term_id":24,"name":"Customizations","slug":"customizing","term_group":0,"term_taxonomy_id":24,"taxonomy":"category","description":"","parent":0,"count":157,"filter":"raw","term_order":"0","cat_ID":24,"category_count":157,"category_description":"","cat_name":"Customizations","category_nicename":"customizing","category_parent":0},{"term_id":120,"name":"Event Submissions","slug":"community-events","term_group":0,"term_taxonomy_id":120,"taxonomy":"category","description":"","parent":61,"count":13,"filter":"raw","term_order":"0","cat_ID":120,"category_count":13,"category_description":"","cat_name":"Event Submissions","category_nicename":"community-events","category_parent":61}],"tag_info":[{"term_id":25,"name":"Customizations","slug":"customizations","term_group":0,"term_taxonomy_id":25,"taxonomy":"post_tag","description":"","parent":0,"count":102,"filter":"raw","term_order":"0"},{"term_id":37,"name":"Extension","slug":"extension","term_group":0,"term_taxonomy_id":37,"taxonomy":"post_tag","description":"","parent":0,"count":3,"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":78,"filter":"raw","term_order":"0"}],"_links":{"self":[{"href":"https:\/\/theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/posts\/1896511","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/comments?post=1896511"}],"version-history":[{"count":6,"href":"https:\/\/theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/posts\/1896511\/revisions"}],"predecessor-version":[{"id":1968732,"href":"https:\/\/theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/posts\/1896511\/revisions\/1968732"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/media\/1955565"}],"wp:attachment":[{"href":"https:\/\/theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/media?parent=1896511"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/categories?post=1896511"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/tags?post=1896511"},{"taxonomy":"stellar-product-taxonomy","embeddable":true,"href":"https:\/\/theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/stellar-product-taxonomy?post=1896511"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}