QloApps Forums
    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular

    Guardo formulario pero no puedo acceder por supuesto error de ruta a n archivo .tpl

    Bug Report
    2
    3
    241
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • M
      Marce 0 last edited by

      Al rellenar un formulario y hacer click en Guardar deberia guardarse en un archivo y da un error que mas abajo comparto.
      El fragmento de codigo es:
      " $this->content = $this->context->smarty->fetch(PS_MODULE_DIR . '/roominglist/views/templates/admin/rooming_list_grupo/detalle.tpl');
      $this->context->smarty->assign('content', $this->content); "

      y la ruta del archivo .tpl es:
      "roominglist/views/templates/admin/rooming_list_grupo/detalle.tpl"

      Error:
      Fatal error: Uncaught --> Smarty: Unable to load template 'file:/home/u863864733/domains/hotelpro.com.ar/public_html/modules/roominglist/views/templates/admin/detalle.tpl' <-- thrown in /home/u863864733/domains/hotelpro.com.ar/public_html/tools/smarty/sysplugins/smarty_internal_template.php on line 195

      Linea 195 del archivo "smarty_internal_template.php":
      " throw new SmartyException(
      "Unable to load template '{$this->source->type}:{$this->source->name}'" .
      ($this->_isSubTpl() ? " in '{$this->parent->template_resource}'" : '')
      ); "

      Si necesitan mas datos, pidanmelo, con gusto se los daré y si me pueden orientar o ayudar les estoy muy agradecido
      .

      A 1 Reply Last reply Reply Quote 0
      • A
        Aradhana Kumari Global Moderator @Marce 0 last edited by

        Hi @Marce-0 ,

        Regarding your issue — "Unable to load template":

        Based on the code you provided, we assume you are working on a custom module.

        From your code, we noticed that the template path is set as:

        roominglist/views/templates/admin/rooming_list_grupo/detalle.tpl
        

        However, it’s possible that elsewhere in your code, you might be trying to fetch the template using an incorrect path, such as:

        roominglist/views/templates/admin/detalle.tpl
        

        This mismatch is likely causing the fatal error.

        Please review your code and ensure that the template path is consistent and correct in all places.

        For reference, you can see our module development documentation:
        🔗 QloApps Module Development Guide

        M 1 Reply Last reply Reply Quote 0
        • M
          Marce 0 @Aradhana Kumari last edited by

          @Aradhana-Kumari
          Thank you so much. It's a sensible answer and has given me another perspective on the problem. I'll read the link you provided. Thanks!

          1 Reply Last reply Reply Quote 0
          • First post
            Last post