Answers.Body: <p>If you are on CiviCRM 5.70.x then it's a known issue which is fixed in the recent version. You can either apply the below patch and do db changes or upgrade CiviCRM to 5.72.x</p>
  <ol>
  <li>Patch file CRM/Event/DAO/Event.php</li>
  </ol>
  <pre><code>diff --git a/CRM/Event/DAO/Event.php b/CRM/Event/DAO/Event.php
  index 32de78e3325c..de7379737b04 100644
  --- a/CRM/Event/DAO/Event.php
  +++ b/CRM/Event/DAO/Event.php
  @@ -6,7 +6,7 @@
    *
    * Generated from xml/schema/CRM/Event/Event.xml
    * DO NOT EDIT.  Generated by CRM_Core_CodeGen
  - * (GenCodeChecksum:d63c53d10f2e09895a19061ea9d51093)
  + * (GenCodeChecksum:193894c0362eb3c7360ad8245e303fcf)
    */
   
   /**
  @@ -542,7 +542,7 @@ class CRM_Event_DAO_Event extends CRM_Core_DAO {
     /**
      * Number of hours prior to event start date to allow self-service cancellation or transfer.
      *
  -   * @var int|string|null
  +   * @var int|string
      *   (SQL type: int)
      *   Note that values will be retrieved from the database as a string.
      */
  @@ -1994,6 +1994,7 @@ public static function &amp;fields() {
             'type' =&gt; CRM_Utils_Type::T_INT,
             'title' =&gt; ts('Self-service Cancellation or Transfer Time'),
             'description' =&gt; ts('Number of hours prior to event start date to allow self-service cancellation or transfer.'),
  +          'required' =&gt; TRUE,
             'usage' =&gt; [
               'import' =&gt; FALSE,
               'export' =&gt; FALSE,
  </code></pre>
  <ol start="2">
  <li>Run below query</li>
  </ol>
  <pre><code>UPDATE civicrm_event SET selfcancelxfer_time = 0 WHERE selfcancelxfer_time IS NULL;
  
  ALTER TABLE civicrm_event MODIFY COLUMN selfcancelxfer_time int(11) DEFAULT 0 NOT NULL COMMENT 'Number of hours prior to event start date to allow self-service cancellation or transfer.';
  
  
  </code></pre>
  <ol start="3">
  <li>Clear CiviCRM cache</li>
  </ol>
  <p>HTH</p>
  <p>Pradeep</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2024-05-02T11:49:56.133Z
Answers.Text: Thanks Pradeep, this patch works for CiviCRM 5.70.2
Answers.UserDisplayName: Kurund Jalmi
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2024-05-02T12:36:54.787Z
Answers.Text: Thank you Pradeep, we upgraded CiviCRM to 5.72.3
Answers.UserDisplayName: FullStack-Dev
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2024-07-31T22:21:55.017Z
Answers.Text: Thanks, but this is NOT working using v 5.70.1.  Any suggestions?  My plan was to update to ESR 5.75.1 when it comes out.
Answers.UserDisplayName: Rob Brandt
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2024-05-01T15:40:10.407Z
Answers.LastActivityDate: 2024-05-01T15:40:10.407Z
Answers.UserDisplayName: Pradeep Nayak
Body: <p>Event registration fails with below error</p>
  <pre><code>ParseError: syntax error, unexpected token &quot;&gt;&quot; in Smarty-&gt;_eval() (line 610 of /var/www/html/drupal/vendor/civicrm/civicrm-packages/Smarty/Smarty.class.php(2018) : eval()'d code).
  </code></pre>
  <p>The error only appears when send confirmation email is set for an event.</p>
  
Tags: <civievent>
Title: Event registration fails with an error
ThreadText: # Event registration fails with an error
  
  (Asked by: username_0 on 2024-05-01)
  
  Event registration fails with below error
  ParseError: syntax error, unexpected token ">" in Smarty->_eval() (line 610 of /var/www/html/drupal/vendor/civicrm/civicrm-packages/Smarty/Smarty.class.php(2018) : eval()'d code).
  
  The error only appears when send confirmation email is set for an event.
  
  **Tags:** civievent
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2024-05-01. Score: 3
  
  If you are on CiviCRM 5.70.x then it's a known issue which is fixed in the recent version. You can either apply the below patch and do db changes or upgrade CiviCRM to 5.72.x
  
  Patch file CRM/Event/DAO/Event.php
  
  diff --git a/CRM/Event/DAO/Event.php b/CRM/Event/DAO/Event.php
  index 32de78e3325c..de7379737b04 100644
  --- a/CRM/Event/DAO/Event.php
  +++ b/CRM/Event/DAO/Event.php
  @@ -6,7 +6,7 @@
    *
    * Generated from xml/schema/CRM/Event/Event.xml
    * DO NOT EDIT.  Generated by CRM_Core_CodeGen
  - * (GenCodeChecksum:d63c53d10f2e09895a19061ea9d51093)
  + * (GenCodeChecksum:193894c0362eb3c7360ad8245e303fcf)
    */
   
   /**
  @@ -542,7 +542,7 @@ class CRM_Event_DAO_Event extends CRM_Core_DAO {
     /**
      * Number of hours prior to event start date to allow self-service cancellation or transfer.
      *
  -   * @var int|string|null
  +   * @var int|string
      *   (SQL type: int)
      *   Note that values will be retrieved from the database as a string.
      */
  @@ -1994,6 +1994,7 @@ public static function &fields() {
             'type' => CRM_Utils_Type::T_INT,
             'title' => ts('Self-service Cancellation or Transfer Time'),
             'description' => ts('Number of hours prior to event start date to allow self-service cancellation or transfer.'),
  +          'required' => TRUE,
             'usage' => [
               'import' => FALSE,
               'export' => FALSE,
  
  
  Run below query
  
  UPDATE civicrm_event SET selfcancelxfer_time = 0 WHERE selfcancelxfer_time IS NULL;
  
  ALTER TABLE civicrm_event MODIFY COLUMN selfcancelxfer_time int(11) DEFAULT 0 NOT NULL COMMENT 'Number of hours prior to event start date to allow self-service cancellation or transfer.';
  
  
  
  
  Clear CiviCRM cache
  
  HTH
  Pradeep
  
  > **Comments:**
  > **username_2**: Thanks Pradeep, this patch works for CiviCRM 5.70.2  
  > **username_0**: Thank you Pradeep, we upgraded CiviCRM to 5.72.3  
  > **username_3**: Thanks, but this is NOT working using v 5.70.1.  Any suggestions?  My plan was to update to ESR 5.75.1 when it comes out.  
  
  ---
  
  