doudan5136 2019-02-27 12:06
浏览 93
已采纳

wordpress插件如何保存设置信息? [重复]

This question already has an answer here:

How does a WordPress plugin save settings information ?

For example, where does it keep the template information that we enter in WordPress panel ?

In a database or in define functions? What is the best way?

</div>
  • 写回答

1条回答 默认 最新

  • dongmacuo1193 2019-02-27 12:37
    关注

    The best way is that you can register, save and read the extra information using with wordpress Plugin settings with form.

    You have to follow the steps as mentioned in articles with birfe information.

    First Step, You can "add form to WordPress plugin page" in functions.php file as mentioned in article file. - Save WordPress plugin settings with form

    Second Step, you can register the Register WordPress plugin settings to database - Register WordPress plugin settings to database

    Third Step, you can implement to read WordPress plugin settings from database - Read WordPress plugin settings from database

    Hope it's useful !!

    Thanks!

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥15 PADS Logic 原理图
  • ¥15 PADS Logic 图标
  • ¥15 电脑和power bi环境都是英文如何将日期层次结构转换成英文
  • ¥20 气象站点数据求取中~
  • ¥15 如何获取APP内弹出的网址链接
  • ¥15 wifi 图标不见了 不知道怎么办 上不了网 变成小地球了