We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 34084 ☆ A M B ☆
    • 756 Posts
    When loading a page I get the following error, where the tvc.contentid is empty (’’) and that TV no longer exist. I’ve cleared cache and tries to do an re-install update with no luck. Any pointers on how to remove this parse error?

    « MODx Parse Error »
    MODx encountered the following error while attempting to parse the requested resource:
    « Execution of a query to the database failed - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1 »
          SQL: SELECT tv.*, IF(tvc.value!='',tvc.value,tv.default_text) as value FROM `iaopc_cms_modx`.`modx_site_tmplvars` tv INNER JOIN `iaopc_cms_modx`.`modx_site_tmplvar_templates` tvtpl ON tvtpl.tmplvarid = tv.id LEFT JOIN `iaopc_cms_modx`.`modx_site_tmplvar_contentvalues` tvc ON tvc.tmplvarid=tv.id AND tvc.contentid = '' WHERE tv.name IN ('encryption') AND tvtpl.templateid = 
    


    cheers
      Evo Revo // Ubuntu, CentOS, Win // Apache 2x, Lighttp (Lighty)
      Visit CharlesMx.com for latest news and status updates.
      • 26714
      • 2 Posts
      Same issue... Nobody?
        • 26714
        • 2 Posts

        Quick fix.

        File manager/includes/document.parser.class.inc.php

        after row #1958 in function getTemplateVars

        add this : if (!$docRow) return false;


        ******************************************************

        #1956 if ($docid == "") {
        #1957 $docid= $this->documentIdentifier;
        #1958 $docRow= $this->documentObject;

        >>>>
        if (!$docRow)
        return false;
        >>>>

        ******************************************************

        I don’t know it is right or no. It works.


        Modx Evolution 1.0.5;
        Linux Apache;
        PHP 5.2.9 CGI;
        MySQL 5.0.24