我想使用php form builder class 。但我无法上这个类。 我使用如下(来自 example page ):
<?php
session_start();
require_once 'PFBC/Form.php';
$form = new Form("webeditors", 650);
$form->addElement(new Element_Hidden("form", "webeditors"));
$form->addElement(new Element_TinyMCE("TinyMCE:", "TinyMCE"));
$form->addElement(new Element_CKEditor("CKEditor:", "CKEditor"));
$form->addElement(new Element_Button);
$form->render();
?>
上述代码的结果:
但必须如下:
PHP Designer 7 结果:
Javascript错误控制台的输出:
Failed to load resource: the server responded with a status of 404 (Not Found) http://localhost/PFBC/Resources/tiny_mce/tiny_mce.js
Failed to load resource: the server responded with a status of 404 (Not Found) http://localhost/PFBC/Resources/ckeditor/ckeditor.js
Uncaught ReferenceError: tinyMCE is not defined
问题出在哪里。我听不懂。
同时,我正在使用 AppServ AppServ 2.5.10
有人说你需要下载tinymce和ckeditor并针对你的项目进行优化。但pfbc已经拥有了一切。
最佳答案
请包含生成的 HTML 输出以及 JavaScript 控制台中的任何错误。我的猜测是,您的页面中没有正确包含所需的 JavaScript/CSS 文件,或者它们未配置为定位所需的元素。
关于php - 为什么 php 表单生成器类没有运行?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11592866/