{"id":927247,"date":"2014-12-31T12:32:55","date_gmt":"2014-12-31T20:32:55","guid":{"rendered":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-date-format\/"},"modified":"2015-01-22T16:01:02","modified_gmt":"2015-01-23T00:01:02","slug":"change-date-format","status":"closed","type":"topic","link":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-date-format\/","title":{"rendered":"Change date format"},"content":{"rendered":"<p>Hi,<\/p>\n<p>Sorry for my English. I hope you understand me .<br \/>\n(I use Google Traduction)<\/p>\n<p>I&#8217;ll try to explain my problem.<br \/>\nI have a real issue about the date format.<br \/>\nI installed the search bar on my home page.<\/p>\n<p><strong>1 &#8211;<\/strong><\/p>\n<li>Here&#8217;s the code to integrate the search bar : (on the homepage) <\/li>\n<pre><code>&lt;div id=&quot;tribe-events-bar&quot;&gt;\n\n\t\t\t&lt;form id=&quot;tribe-bar-form&quot; class=&quot;tribe-clearfix&quot; name=&quot;tribe-bar-form&quot; method=&quot;get&quot; action=&quot;&lt;?php bloginfo(&#039;url&#039;); ?&gt;\/evenements\/&quot;&gt;\n\n\t\t\t\t&lt;!-- Mobile Filters Toggle --&gt;\n\n\t\t\t\t&lt;div id=&quot;tribe-bar-collapse-toggle&quot; &lt;?php if ( count( $views ) == 1 ) { ?&gt; class=&quot;tribe-bar-collapse-toggle-full-width&quot;&lt;?php } ?&gt;&gt;\n\t\t\t\t\t&lt;?php _e( &#039;Find Events&#039;, &#039;tribe-events-calendar&#039; ) ?&gt;&lt;span class=&quot;tribe-bar-toggle-arrow&quot;&gt;&lt;\/span&gt;\n\t\t\t\t&lt;\/div&gt;\n\n\t\t\t\t&lt;div class=&quot;tribe-bar-filters&quot;&gt;\n\t\t\t\t\t&lt;div class=&quot;tribe-bar-filters-inner tribe-clearfix&quot;&gt;\n\t\t\t\t\t\t\t&lt;div class=&quot;tribe-bar-date-filter&quot;&gt;\n\t\t\t\t\t\t\t\t&lt;label for=&quot;tribe-bar-date&quot; class=&quot;label-tribe-bar-date&quot;&gt;Date&lt;\/label&gt;\n\t\t\t\t\t\t\t\t&lt;input type=&quot;text&quot; placeholder=&quot;Date&quot; value=&quot;&quot; id=&quot;tribe-bar-date&quot; data-date-format=&quot;mm-dd-yyyy&quot; style=&quot;position: relative; z-index:10000&quot; name=&quot;tribe-bar-date&quot;&gt;\n\t\t\t\t\t\t\t\t&lt;input type=&quot;hidden&quot; value=&quot;&quot; class=&quot;tribe-no-param&quot; id=&quot;tribe-bar-date-day&quot; name=&quot;tribe-bar-date-day&quot;&gt;\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t&lt;\/div&gt;\n\t\t\t\t\t\t\t&lt;div class=&quot;tribe-bar-search-filter&quot;&gt;\n\t\t\t\t\t\t\t\t&lt;label for=&quot;tribe-bar-search&quot; class=&quot;label-tribe-bar-search&quot;&gt;Search&lt;\/label&gt;\n\t\t\t\t\t\t\t\t&lt;input data-bind=&quot;label&quot; type=&quot;text&quot; placeholder=&quot;Snorkeling, Dinner Cruise, Ibiza Party&quot; onfocus=&quot;this.placeholder = &#039;&#039;&quot; onblur=&quot;this.placeholder = &#039;&#039;&quot; value=&quot;&quot; id=&quot;tribe-bar-search&quot; name=&quot;tribe-bar-search&quot;&gt;\t\n\n\t\t\t\t\t\t\t&lt;\/div&gt;\n\t\t\t\t\t\t&lt;div class=&quot;tribe-bar-submit&quot;&gt;\n\t\t\t\t\t\t\t&lt;input class=&quot;tribe-events-button tribe-no-param&quot; type=&quot;submit&quot; name=&quot;submit-bar&quot; value=&quot;&lt;?php _e( &#039;Find Events&#039;, &#039;tribe-events-calendar&#039; ) ?&gt;&quot; \/&gt;\n\t\t\t\t\t\t&lt;\/div&gt;&lt;!-- .tribe-bar-submit --&gt;\n\t\t\t\t\t&lt;\/div&gt;&lt;!-- .tribe-bar-filters-inner --&gt;\n\t\t\t\t&lt;\/div&gt;&lt;!-- .tribe-bar-filters --&gt;\n\n\t\t\t&lt;\/form&gt;&lt;!-- #tribe-bar-form --&gt;\n\n&lt;\/div&gt;&lt;!-- #tribe-events-bar --&gt;<\/code><\/pre>\n<p><strong>2 &#8211;<\/strong> <\/p>\n<li>And here the code (in fucntions.php) <\/li>\n<p>(According to <a href=\"http:\/\/gregorypearcey.com\/blog\/add-tribe-events-search-bar-home-page\/http:\/\/\" target=\"_blank\">Greg<\/a>)<\/p>\n<pre><code>\/\/Add these scripts to only the front page\nfunction tribehome_enqueue_front_page_scripts() {\n    if( is_front_page() )\n    {\n\t   \n\t    \/\/Add the stylesheet into the header\n\t\twp_enqueue_style(&quot;tribe.homepage&quot;,WP_PLUGIN_URL.&quot;\/the-events-calendar\/resources\/tribe-events-full.css&quot;);\n\t\t\n\t\twp_enqueue_style(&quot;tribe.homepage.date&quot;,WP_PLUGIN_URL.&quot;\/the-events-calendar\/vendor\/bootstrap-datepicker\/css\/datepicker.css&quot;);\n\t\twp_enqueue_style(&quot;tribe.homepage.date&quot;,WP_PLUGIN_URL.&quot;\/the-events-calendar\/vendor\/bootstrap-datepicker\/css\/datepicker3.css&quot;);\n\t\t\n\t\t\/\/Add the scripts in the footer\n\t\twp_enqueue_script(&quot;jquery&quot;);\n\t\t\n\t\twp_enqueue_script(\n\t\t&quot;tribe.homepage.bar&quot;, WP_PLUGIN_URL.&quot;\/the-events-calendar\/resources\/tribe-events-bar.js&quot;,\n\t\tarray(&quot;jquery&quot;), &quot;1.3.1&quot;,1);\n\t\t\n\t\twp_enqueue_script(\n\t\t&quot;tribe.homepage.events&quot;, WP_PLUGIN_URL.&quot;\/the-events-calendar\/resources\/tribe-events.js&quot;,\n\t\tarray(&quot;jquery&quot;), &quot;1.3.1&quot;,1);\n\t\t\n\t\twp_enqueue_script(\n\t\t&quot;tribe.homepage.datepicker&quot;, WP_PLUGIN_URL.&quot;\/tribe-homepage-search\/js\/bootstrap-datepicker.js&quot;,\n\t\tarray(&quot;jquery&quot;), &quot;1.3.1&quot;,1);\n\t\t\n\t\twp_enqueue_script(\n\t\t&quot;tribe.homepage.footer&quot;, WP_PLUGIN_URL.&quot;\/tribe-homepage-search\/js\/footer.js&quot;,\n\t\tarray(&quot;jquery&quot;), &quot;1.3.1&quot;,1);\n\n\t}\n}\nadd_action( &#039;wp_enqueue_scripts&#039;, &#039;tribehome_enqueue_front_page_scripts&#039; );<\/code><\/pre>\n<p>No integration problem, but rather a problem when I decide to change the date format.<br \/>\nI want to change the format &#8220;mm-dd-yyyy&#8221; to &#8220;dd-mm-yyyy&#8221;<br \/>\nI changed this line ( on my home page):<br \/>\n<code>&lt;input type=&quot;text&quot; placeholder=&quot;Date&quot; value=&quot;&quot; id=&quot;tribe-bar-date&quot; data-date-format=&quot;&lt;strong&gt;mm-dd-yyyy&lt;\/strong&gt;&quot; style=&quot;position: relative; z-index:10000&quot; name=&quot;tribe-bar-date&quot;&gt;<\/code><\/p>\n<li>Here is the result ! :<\/li>\n<p><img decoding=\"async\" src=\"http:\/\/goo.gl\/IHxjFb\" alt=\"Capture 1\" \/><\/p>\n<p><img decoding=\"async\" src=\"http:\/\/goo.gl\/TjSFPp\" alt=\"Capture 2\" \/><\/p>\n<p>The search is done correctly , but the display of the date is wrong.<br \/>\n&#8220;12-07-2016&#8221; instead of &#8220;31-12-2014&#8221;<\/p>\n<li>Here are some screenshots:<\/li>\n<p><img decoding=\"async\" src=\"http:\/\/goo.gl\/Coco0t\" alt=\"Screenshot WP- 1\" \/><\/p>\n<p><img decoding=\"async\" src=\"http:\/\/goo.gl\/i95mwL\" alt=\"Screenshot-WP- 2\" \/><\/p>\n<p><img decoding=\"async\" src=\"http:\/\/goo.gl\/j7vs7J\" alt=\"Screenshot WP- 3\" \/><\/p>\n<p>I hope to have a precise answer to my problem.<br \/>\nSVP.<\/p>\n<p>Regards<\/p>\n","protected":false},"template":"","class_list":["post-927247","topic","type-topic","status-closed","hentry"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v25.2 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Change date format -<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-date-format\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Change date format -\" \/>\n<meta property=\"og:description\" content=\"Hi, Sorry for my English. I hope you understand me . (I use Google Traduction) I&#8217;ll try to explain my problem. I have a real issue about the date format. I installed the search bar on my home page. 1 &#8211; Here&#8217;s the code to integrate the search bar : (on the homepage) &lt;div id=&quot;tribe-events-bar&quot;&gt; [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-date-format\/\" \/>\n<meta property=\"article:modified_time\" content=\"2015-01-23T00:01:02+00:00\" \/>\n<meta property=\"og:image\" content=\"http:\/\/goo.gl\/IHxjFb\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data1\" content=\"3 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-date-format\/\",\"url\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-date-format\/\",\"name\":\"Change date format -\",\"isPartOf\":{\"@id\":\"https:\/\/theeventscalendar.com\/support\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-date-format\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-date-format\/#primaryimage\"},\"thumbnailUrl\":\"http:\/\/goo.gl\/IHxjFb\",\"datePublished\":\"2014-12-31T20:32:55+00:00\",\"dateModified\":\"2015-01-23T00:01:02+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-date-format\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-date-format\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-date-format\/#primaryimage\",\"url\":\"http:\/\/goo.gl\/IHxjFb\",\"contentUrl\":\"http:\/\/goo.gl\/IHxjFb\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-date-format\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/theeventscalendar.com\/support\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Topics\",\"item\":\"https:\/\/theeventscalendar.com\/support\/topics\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Calendar Products\",\"item\":\"https:\/\/theeventscalendar.com\/support\/forums\/forum\/events\/\"},{\"@type\":\"ListItem\",\"position\":4,\"name\":\"Events Calendar PRO\",\"item\":\"https:\/\/theeventscalendar.com\/support\/forums\/forum\/events\/events-calendar-pro\/\"},{\"@type\":\"ListItem\",\"position\":5,\"name\":\"Change date format\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/theeventscalendar.com\/support\/#website\",\"url\":\"https:\/\/theeventscalendar.com\/support\/\",\"name\":\"\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/theeventscalendar.com\/support\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Change date format -","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-date-format\/","og_locale":"en_US","og_type":"article","og_title":"Change date format -","og_description":"Hi, Sorry for my English. I hope you understand me . (I use Google Traduction) I&#8217;ll try to explain my problem. I have a real issue about the date format. I installed the search bar on my home page. 1 &#8211; Here&#8217;s the code to integrate the search bar : (on the homepage) &lt;div id=&quot;tribe-events-bar&quot;&gt; [&hellip;]","og_url":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-date-format\/","article_modified_time":"2015-01-23T00:01:02+00:00","og_image":[{"url":"http:\/\/goo.gl\/IHxjFb","type":"","width":"","height":""}],"twitter_card":"summary_large_image","twitter_misc":{"Est. reading time":"3 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-date-format\/","url":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-date-format\/","name":"Change date format -","isPartOf":{"@id":"https:\/\/theeventscalendar.com\/support\/#website"},"primaryImageOfPage":{"@id":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-date-format\/#primaryimage"},"image":{"@id":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-date-format\/#primaryimage"},"thumbnailUrl":"http:\/\/goo.gl\/IHxjFb","datePublished":"2014-12-31T20:32:55+00:00","dateModified":"2015-01-23T00:01:02+00:00","breadcrumb":{"@id":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-date-format\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-date-format\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-date-format\/#primaryimage","url":"http:\/\/goo.gl\/IHxjFb","contentUrl":"http:\/\/goo.gl\/IHxjFb"},{"@type":"BreadcrumbList","@id":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/change-date-format\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/theeventscalendar.com\/support\/"},{"@type":"ListItem","position":2,"name":"Topics","item":"https:\/\/theeventscalendar.com\/support\/topics\/"},{"@type":"ListItem","position":3,"name":"Calendar Products","item":"https:\/\/theeventscalendar.com\/support\/forums\/forum\/events\/"},{"@type":"ListItem","position":4,"name":"Events Calendar PRO","item":"https:\/\/theeventscalendar.com\/support\/forums\/forum\/events\/events-calendar-pro\/"},{"@type":"ListItem","position":5,"name":"Change date format"}]},{"@type":"WebSite","@id":"https:\/\/theeventscalendar.com\/support\/#website","url":"https:\/\/theeventscalendar.com\/support\/","name":"","description":"","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/theeventscalendar.com\/support\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"}]}},"_links":{"self":[{"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/topic\/927247","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/topic"}],"about":[{"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/types\/topic"}],"version-history":[{"count":2,"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/topic\/927247\/revisions"}],"predecessor-version":[{"id":927880,"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/topic\/927247\/revisions\/927880"}],"wp:attachment":[{"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/media?parent=927247"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}