【问题标题】:how to save form template in database built by formbuilder如何将表单模板保存在formbuilder构建的数据库中
【发布时间】:2018-12-11 14:49:11
【问题描述】:

我在我的网站上使用https://formbuilder.online/ 从表单生成器 jquery 插件制作表单,我想将表单模板保存在数据库中

我添加表单生成器插件成功http://pro1.wealthbyhealth.in/formbuilder/demo.php

如何将表单模板保存在数据库中?

【问题讨论】:

  • 很有趣....如果我们需要从模板中创建相同的表结构在mysql(数据库)上怎么办?

标签: php jquery mysql jquery-plugins formbuilder


【解决方案1】:

我们实际上有同样的问题,我的问题仍然没有得到解决。但我知道一种可能对您有所帮助的方法。

为了将表单模板保存在mysql数据库中,您应该创建一个包含这样一个字段的表>>

Table Fields screenshot

当用户保存表单时,它将像这样保存在数据库中>>

Sample Text Input screenshot

现在,当谈到检索我们之前保存的“表单模板”时。您可以在 php.ini 中使用 if else 语句。例如,

if(type == "text"){
  statement that you will create a text input here
} else if (type == "password"){
  statement that you will create a password input here
}

等等……

告诉我这是否有帮助

【讨论】:

  • 我认为我们需要从表单模板中遍历并相应地创建表结构......你怎么看,@Elliot?
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2021-10-28
  • 2021-04-26
  • 2015-05-03
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多