Answers.Body: <p>Welcome to SE! Check you have the latest versions of the extension and CiviCRM. The error relates to Smarty 4: there was a <a href="https://lab.civicrm.org/extensions/grantapplications/-/merge_requests/202" rel="nofollow noreferrer">fix</a> relating to that a few months ago which is included in release 2.1</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2024-11-08T13:21:28.633Z
Answers.Text: Thanks, that's great. However I upgrade CiviCRM this morning and all plugins, thinking that would resolve the issue. I found the fix too.
  
  I am now on version 2.1 of the plugin, but the issue persists.
Answers.UserDisplayName: Ben Atkinson
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2024-11-08T13:45:41.877Z
Answers.Text: Not sure if it is related but when trying to edit any grant application pages from within the grants dashboard I now get this error:
  
  
  [error] 
  $Fatal Error Details = array:3 [
    "message" => "Unrecognized entity type: GrantModel"
    "code" => null
    "exception" => CRM_Core_Exception {#11082
      #message: "Unrecognized entity type: GrantModel"
      #code: 0
      #file: "wp-content/plugins/civicrm/civicrm/CRM/UF/Page/ProfileEditor.php"
      #line: 207
Answers.UserDisplayName: Ben Atkinson
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2024-11-11T05:01:47.693Z
Answers.Text: @BenAtkinson have you cleared your Civi caches?
Answers.UserDisplayName: Coleman
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2024-11-11T08:38:02.537Z
Answers.Text: @Coleman as far as I know, yes. Following the instructions during the upgrade.
Answers.UserDisplayName: Ben Atkinson
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2024-11-11T14:13:05.540Z
Answers.Text: @BenAtkinson and can you confirm the CiviGrant extension is enabled?
Answers.UserDisplayName: Coleman
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2024-11-08T12:24:42.720Z
Answers.LastActivityDate: 2024-11-08T12:24:42.720Z
Answers.UserDisplayName: Aidan
Body: <p>I've been struggling for a month or so now with an error when viewing certain grant application pages (using the Grand Application Pages Extension: <a href="https://civicrm.org/extensions/grant-application-pages" rel="nofollow noreferrer">https://civicrm.org/extensions/grant-application-pages</a>), but I think this relates to core CiviCRM rather than the extension.</p>
  <p>Error is thrown on public facing pages on WordPress:</p>
  <p>Uncaught TypeError: Unsupported operand types: string - string in /wp-content/uploads/civicrm/templates_c/en_US/d6/24/4c/d6244c46f741d0a95614f2886a1c2e9f44e810c3_0.file.Main.tpl.php:61 Stack trace: #0 public_html/wp-content/plugins/civicrm/civicrm/packages/smarty4/vendor/smarty/smarty/libs/sysplugins/smarty_template_resource_base.php(123): content_672deaf990ba15_67238194(Object(Smarty_Internal_Template))</p>
  <p>Have tried a lot of approaches to fix, now have the latest version of CiviCRM and all extensions are updated. The issue still persists? There are custom fields on the application page, but only text fields as far as I know.</p>
  <p>Any thoughts?</p>
  
Tags: <wordpress><civigrant><grant>
Title: Error with grant application pages
ThreadText: # Error with grant application pages
  
  (Asked by: username_0 on 2024-11-08)
  
  I've been struggling for a month or so now with an error when viewing certain grant application pages (using the Grand Application Pages Extension: <https://civicrm.org/extensions/grant-application-pages>), but I think this relates to core CiviCRM rather than the extension.
  
  Error is thrown on public facing pages on WordPress:
  
  Uncaught TypeError: Unsupported operand types: string - string in /wp-content/uploads/civicrm/templates\_c/en\_US/d6/24/4c/d6244c46f741d0a95614f2886a1c2e9f44e810c3\_0.file.Main.tpl.php:61 Stack trace: #0 public\_html/wp-content/plugins/civicrm/civicrm/packages/smarty4/vendor/smarty/smarty/libs/sysplugins/smarty\_template\_resource\_base.php(123): content\_672deaf990ba15\_67238194(Object(Smarty\_Internal\_Template))
  
  Have tried a lot of approaches to fix, now have the latest version of CiviCRM and all extensions are updated. The issue still persists? There are custom fields on the application page, but only text fields as far as I know.
  
  Any thoughts?
  
  **Tags:** wordpress, civigrant, grant
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2024-11-08. Score: 2
  
  Welcome to SE! Check you have the latest versions of the extension and CiviCRM. The error relates to Smarty 4: there was a [fix](https://lab.civicrm.org/extensions/grantapplications/-/merge_requests/202) relating to that a few months ago which is included in release 2.1
  
  > **Comments:**
  > **username_0**: Thanks, that's great. However I upgrade CiviCRM this morning and all plugins, thinking that would resolve the issue. I found the fix too.  I am now on version 2.1 of the plugin, but the issue persists.  
  > **username_0**: Not sure if it is related but when trying to edit any grant application pages from within the grants dashboard I now get this error:   [error]  $Fatal Error Details = array:3 [   "message" => "Unrecognized entity type: GrantModel"   "code" => null   "exception" => CRM_Core_Exception {#11082     #message: "Unrecognized entity type: GrantModel"     #code: 0     #file: "wp-content/plugins/civicrm/civicrm/CRM/UF/Page/ProfileEditor.php"     #line: 207  
  > **username_2**: @BenAtkinson have you cleared your Civi caches?  
  > **username_0**: @username_2 as far as I know, yes. Following the instructions during the upgrade.  
  > **username_2**: @BenAtkinson and can you confirm the CiviGrant extension is enabled?  
  
  ---
  
  