phpcms How to create a new model?
Log in to the PHPCMS backend, select management content (top navigation) - model management (bottom of left navigation)
Related recommendations: phpcms tutorial
Choose to add a model, a pop-up window will pop up, fill in according to your needs, here I write the test model, click OK to save
After the model is added, click Field Management--Add Field
and add the field name you need in the pop-up window. Enter the type and wait
#After clicking OK, you will see that the field has been added.
Then start modifying, click Content--Column Management, select the column whose model you want to change. Note here that the column model can only be modified when the data in the column is 0. Here I have added a new column of the content model
Select the column, modify it, select the newly added column model we just added in the column model drop-down tab, test the model, and confirm Save
OK, let’s add an article to this column to see if the new model is effective. See, the new model is effective
Notes
Note that when changing the column model, the column data must be 0 before changing.
Add moreinfo=1 when calling a custom model and call the model field in English
The above is the detailed content of How to create a new model in phpcms. For more information, please follow other related articles on the PHP Chinese website!