Okay here we go...
Here is my folder setup:
www/
cms/
fckeditor/
*all of the fckeditor files from tar.gz*
fckeditor.php
Here is my code for fckeditor:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Sethtrain :: Home</title>
<link rel="stylesheet" href="styles-cms.css" type="text/css" />
<script type="text/javascript" src="fckeditor/fckeditor.js"></script>
<script type="text/javascript">
window.onload = function()
{
var oFCKeditor = new FCKeditor( 'body' ) ;
oFCKeditor.ReplaceTextarea() ;
}
</script>
</head>
<body>
<!-- Begingin div for container -->
<div id="container">
<!-- Top Navigation bar with "Home", "Sitemap" and "Search" links -->
<div id="topnavbar">
<ul id="topnav">
<li><a href="search.php">Search</a> </li>
<li><a href="sitemap.php">Sitemap</a> </li>
<li><a href="index.php">Home</a> </li>
</ul>
</div>
<!-- Top Banner -->
<div id="banner">
<img src="images/logo.jpg" alt="sethtrain.gotdns.com" width="750" height="139" align="right"/>
</div>
<!-- Main navigation bar that is right under the orange banner -->
<div id="mainnav">
<ul>
<li><a href="http://sethtrain.gotdns.com/">Home</a></li>
<li><a href="/about.php">The Team</a></li>
<li><a href="/client/index.php">Clients</a></li>
<li><a href="/contact.php">Contact Us</a></li>
</ul>
</div>
<!-- Side Navigation located on the left -->
<div id="leftnav">
<h2>CMS Navigation</h2>
<ul>
<li><a href="index.php">CMS Home</a></li>
<li><a href="addart.php">Add Article</a></li>
<li><a href="addauth.php">Add Author</a></li>
<li><a href="addcat.php">Add Category</a></li>
<li><a href="editart.php">Edit Article</a></li>
<li><a href="editauth.php">Edit Author</a></li>
<li><a href="editcat.php">Edit Category</a></li>
</ul>
</div>
<div id="leftnews">
<h2>News</h2>
</div>
<div id="leftarts">
<h2>Recent Articles</h2>
</div>
<!-- Main Text -->
<div id="maincontent">
<form action="addart.php" method="post">
<table width="100%">
<tr>
<td><label for="title">Title:</label></td>
<td><input type="text" name="title"></td>
</tr>
<tr>
<td><label for="category">Category</label></td>
<td><select name="category" size="0"></select></td>
</tr>
<tr>
<td valign="top"><label for="body">Body:</label></td>
<td><textarea id="body" name="body" style="width:100%" rows="24" cols="125"></textarea></td>
</tr>
<tr>
<td colspan="2" align="center"><input type="submit" name="submit" value="Submit"> <input type="reset" name="reset" value="Reset"></td>
</tr>
</table>
</form>
</div>
<!-- Footer Information and Navigation -->
<div id="footer">
<a href="http://www.lattelayouts.com">Home</a> |
<a href="http://validator.w3.org/check/referer">XHTML Validation</a> |
<a href="http://jigsaw.w3.org/css-validator/check/referer">CSS Validation</a> <br />
<p>Copyright © 2004 sethtrain.gotdns.com. All Rights Reserved.<br />
<a href="http://www.lattelayouts.com">Web Development by Latte Layouts, Kentucky, USA.</a> - <a href="http://www.htmlarea.com">Content Management System using htmlArea</a></p>
</div>
<!-- Ending div for container -->
</div>
</body>
</html>
I am getting:
Not Found
The requested URL /fckeditor/editor/fckeditor.html was not found on this server.
<b>NOTE: I CAN view the samples files...</b> (http://sethtrain.gotdns.com/cms/fckedit ... fault.html) but not in Firefox.
So to solve this issue I thought I would change the basepath:
<script type="text/javascript" src="fckeditor/fckeditor.js"></script>
<script type="text/javascript">
window.onload = function()
{
var oFCKeditor = new FCKeditor( 'body' ) ;
oFCKeditor.ReplaceTextarea() ;
}
oFCKeditor.BasePath = "fckeditor/" ;
</script>
</head>
I am still getting:
Not Found
The requested URL /fckeditor/editor/fckeditor.html was not found on this server.
Apache/2.0.52 (Unix) PHP/5.0.2 Server at sethtrain.gotdns.com Port 80
Can you help me? I humbly ask...
Thu, 11/04/2004 - 10:45
#1
RE: Can't seem to get it to work...
I haven't used the replace textarea method myself, but I'll try and give you some hints:
1) If you look at the sample02.html code you'll see that the basepath is defined *before* your call to the replace textarea function. Would this have been done for a reason ? I should think so, so try this:
<script type="text/javascript">
window.onload = function()
{
var oFCKeditor = new FCKeditor( 'body' ) ;
oFCKeditor.BasePath = "fckeditor/" ;
oFCKeditor.ReplaceTextarea() ;
}
</script>
2) As I mentioned in my other post (did you read it ?): DO NOT CALL THE SUBMIT BUTTON "SUBMIT".
I completely agree that this is very confusing and a very difficult one to find out.
However if you would have done a search in the forum on "toolbar" (as in "toolbar not showing") you *would* have found that answer as I posted it only a week or two ago after *I* found it searching through all the information here, so even before my post on it, the answer *was* already available.
So change:
<input type="submit" name="submit" value="Submit">
to:
<input type="submit" name="ivelearnedtoread" value="Submit">
(or whatever else you want to call it)
3) Althought I don't know whether it will make a difference or whether it even matters, I consider it good practice to *never* name or id any part of code by a name which could be confusing... so calling your textarea "body" while an important HTML tag is also called body *could* be causing problems.
Do let us know whether these comments helped.
RE: Can't seem to get it to work...
Thanks again,
Sethtrain
RE: Can't seem to get it to work...
I prefer FF myself as well, but well, the customer I've been implementing it for prefers IE.. silly people...
I do use the IFRAME method though, never even tried the textarea replace one. IFRAME works fine in FF.
RE: Can't seem to get it to work...
Thanks for your help,
Sethtrain
RE: Can't seem to get it to work...
Glad to have been of help.
Quote: "It has something to do with my release of FF."
Please post what other problem you found and in which release and which release solved it, so that others can benefit from your experience.
Quote: "except for my position of the form, which has something to do with IE standards"
Again, please post your findings so other people can benefit from them.
Thx, Jrf
RE: Can't seem to get it to work...
What I did to fix the problem in Firefox was to download the latest nightly build (http://ftp28f.newaol.com/pub/mozilla.or ... test-0.11/). My release (RC1) doesn't have some kind of javascript capabilities that earlier releases have had. The release I downloaded was RC2.