For example, classification information, content page default is generated static, if you need to set to dynamic access, you can refer to the following methods:
ARCLISTSG tag, document list invocation tag for single-table standalone model
Method One:
In the Arclist label use, its corresponding to the main table dede_archives has a field ismake field, its role you should know that the value is 1 when dynamic, our method is to imitate this.
Single table model creation, the default is no Ismake field, because we manually create a Ismake field, set its value to 1.
Note: When you create a model, you can add a ismake field. If not, you can add the query field by adding it directly in the corresponding table and adding the ismake field to the ListFields in the Dede_channeltype table. If the last step is finished, found that does not work, you can query ListFields whether there is Ismake
Modify the source code:
First, ARCLISTSG source, about 264 lines, find $row[' Arcurl ' This, Getfileurl () "This function in helpers/channelunit.helper.php", is to obtain the URL address, There is a ismake parameter which is interesting to look at this function.
Our goal is to change the 1[$row [' title '] in the Getfileurl () parameter to $row[' Ismake ')
Note: If you only need the ARCLISTSG label to display the dynamic, then this step will be
Second, modify arc.sglistview.class.php, about 760 lines, will $row[' ismake '] = 1; Comment out, under its next few lines, have $row[' arcurl '] = Getfileurl () have the code in the first step, Change to the same as in the first step
In this case, you can basically implement dynamic browsing, but when you add or modify an HTML file, the corresponding Publisher or modification program will generate the HTML code comment.
Method Two:
In fact, and method one is a reason, if do not want to establish ismake field, the corresponding local law is modified to 1 can be, but this does not good compatibility, suggested method one
http://www.bkjia.com/PHPjc/626612.html www.bkjia.com true http://www.bkjia.com/PHPjc/626612.html techarticle For example, classification information, content page default is generated static, if you need to set to dynamic access, you can refer to the following methods: ARCLISTSG tags, single-table independent model of the document list ...