During the template creation process, some pages cannot use the $ CATEGORYS variable. The following code checks whether the $ CATEGORYS variable exists. If not, declare the variable .? Phpif (! Isset ($ CATEGORYS) {$ CATEGORYSgetcache (category_content _. $ siteid, commons );}? Generally, I am used to putting it in general
During the template creation process, some pages cannot use the $ CATEGORYS variable. The following code checks whether the $ CATEGORYS variable exists. If not, declare the variable .? Php if (! Isset ($ CATEGORYS) {$ CATEGORYS = getcache ('category _ content _ '. $ siteid, 'commons ');}? Generally, I am used to putting it in general
During the template creation process, some pages cannot use the $ CATEGORYS variable. The following code checks whether the $ CATEGORYS variable exists. If not, declare the variable. Generally, I am used to directly put it in a general header template. In this way, the page that calls the header will have the variable of $ CATEGORYS.
Original article address: phpcms $ CATEGORYS variable. Thank you for sharing it with the original author.