php - 为什么 php 表单生成器类没有运行?

标签 php javascript oop tinymce ckeditor

我想使用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();
?>

上述代码的结果:

HTML codes .

enter image description here

但必须如下:

enter image description here

PHP Designer 7 结果:

enter image description here

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已经拥有了一切。

enter image description here

最佳答案

请包含生成的 HTML 输出以及 JavaScript 控制台中的任何错误。我的猜测是,您的页面中没有正确包含所需的 JavaScript/CSS 文件,或者它们未配置为定位所需的元素。

关于php - 为什么 php 表单生成器类没有运行?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11592866/

相关文章:

javascript - 使用 PHP 和 AJAX 从表中加载数据

oop - 小说/书籍面向对象的设计方法

java - Java 枚举值如何用作真正的静态常量

php - 如何在 while 循环中为每个表单分配电子邮件地址

PHP - Shell_exec 和 exec 在运行时返回 false

javascript - Jquery 选择 DOM 元素并访问内部元素

javascript - 如何在 native Javascript 中创建一个元素并将现有元素移动到其中?

Python:在多重继承中调用多个初始化

php - 自动测试等同于 PHP?

php - 从两个或多个脚本访问/更新一个表的最佳方法?