{"id":1957586,"date":"2023-01-20T06:31:37","date_gmt":"2023-01-20T11:31:37","guid":{"rendered":"https:\/\/staging.theeventscalendar.com\/knowledgebase\/?post_type=post&#038;p=1954833"},"modified":"2023-01-20T06:31:37","modified_gmt":"2023-01-20T11:31:37","slug":"resolved-error-during-status-transition","status":"publish","type":"post","link":"https:\/\/staging.theeventscalendar.com\/knowledgebase\/resolved-error-during-status-transition\/","title":{"rendered":"Resolved: Error During Status Transition"},"content":{"rendered":"\n<p>When creating PDF tickets with Event Tickets and Event Tickets Plus, you may see the following error message: <code>Error during status transition. DirectoryIterator::__construct(\/tmp\/): failed to open dir: Permission denied<\/code><\/p>\n\n\n\n<p>This error message indicates that you don&#8217;t have access to the directory needed to create the PDF for your tickets. The good news is that we have a snippet to help you override these permissions and get your tickets working as expected in no time!<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-directory-access\">Directory access<\/h2>\n\n\n\n<p>As we mentioned, the above error indicates that you don&#8217;t have access to the\u00a0<code>\/tmp<\/code>\u00a0directory on your server: either the\u00a0<code>\/tmp<\/code>\u00a0directory doesn&#8217;t exist (it usually resides in the root folder of your server), or you don&#8217;t have privileges to write to this directory. With privileges -755, you should be able to work with this folder so the plugin can generate and save the QR codes for the ticket emails.<\/p>\n\n\n\n<p>As a first step, we recommend reaching out to your web host to see if they can provide you with access to this directory and\/or change the permissions on the directory for your website.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">The snippet<\/h2>\n\n\n\n<p>If the issue persists, you can add the following snippet to your <code>functions.php<\/code> file:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: php; title: ; notranslate\" title=\"\">\n&lt;?php\n\n\nadd_filter( &#039;tribe_ext_pdf_tickets_mpdf_args&#039;, function( $args ) {\n\t$upload_dir = wp_upload_dir();\n\t$args&#x5B;&#039;tempDir&#039;] = $upload_dir&#x5B;&#039;basedir&#039;] . &#039;\/tmp\/&#039;;\n\treturn $args;\n} );\n<\/pre><\/div>","protected":false},"excerpt":{"rendered":"<p>When creating PDF tickets with Event Tickets and Event Tickets Plus, you may see the following error message: Error during status transition. DirectoryIterator::__construct(\/tmp\/): failed to open dir: Permission denied This error message indicates that you don&#8217;t have access to the directory needed to create the PDF for your tickets. The good news is that we&#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":[40,124,59,79,93],"tags":[58],"stellar-product-taxonomy":[155,156],"class_list":["post-1957586","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-support-resources","category-google-search-console-errors","category-customizing-resources","category-snippets","category-errors","tag-php","stellar-product-taxonomy-event-tickets","stellar-product-taxonomy-event-tickets-plus"],"acf":[],"taxonomy_info":{"category":[{"value":40,"label":"Get Help"},{"value":124,"label":"Google Search Console Errors"},{"value":59,"label":"PHP &amp; Functions"},{"value":79,"label":"Snippets"},{"value":93,"label":"Troubleshooting"}],"post_tag":[{"value":58,"label":"PHP"}],"stellar-product-taxonomy":[{"value":155,"label":"Event Tickets"},{"value":156,"label":"Event Tickets Plus"}]},"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:\/\/staging.theeventscalendar.com\/knowledgebase\/author\/jaimetri-be\/"},"comment_info":0,"category_info":[{"term_id":40,"name":"Get Help","slug":"support-resources","term_group":0,"term_taxonomy_id":40,"taxonomy":"category","description":"","parent":0,"count":28,"filter":"raw","term_order":"0","cat_ID":40,"category_count":28,"category_description":"","cat_name":"Get Help","category_nicename":"support-resources","category_parent":0},{"term_id":124,"name":"Google Search Console Errors","slug":"google-search-console-errors","term_group":0,"term_taxonomy_id":124,"taxonomy":"category","description":"","parent":93,"count":6,"filter":"raw","term_order":"0","cat_ID":124,"category_count":6,"category_description":"","cat_name":"Google Search Console Errors","category_nicename":"google-search-console-errors","category_parent":93},{"term_id":59,"name":"PHP &amp; Functions","slug":"customizing-resources","term_group":0,"term_taxonomy_id":59,"taxonomy":"category","description":"","parent":24,"count":101,"filter":"raw","term_order":"0","cat_ID":59,"category_count":101,"category_description":"","cat_name":"PHP &amp; Functions","category_nicename":"customizing-resources","category_parent":24},{"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},{"term_id":93,"name":"Troubleshooting","slug":"errors","term_group":0,"term_taxonomy_id":93,"taxonomy":"category","description":"","parent":0,"count":67,"filter":"raw","term_order":"0","cat_ID":93,"category_count":67,"category_description":"","cat_name":"Troubleshooting","category_nicename":"errors","category_parent":0}],"tag_info":[{"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\/1957586","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\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/staging.theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/comments?post=1957586"}],"version-history":[{"count":1,"href":"https:\/\/staging.theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/posts\/1957586\/revisions"}],"predecessor-version":[{"id":1957754,"href":"https:\/\/staging.theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/posts\/1957586\/revisions\/1957754"}],"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=1957586"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/staging.theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/categories?post=1957586"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/staging.theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/tags?post=1957586"},{"taxonomy":"stellar-product-taxonomy","embeddable":true,"href":"https:\/\/staging.theeventscalendar.com\/knowledgebase\/wp-json\/wp\/v2\/stellar-product-taxonomy?post=1957586"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}