FCKEditor does not run with XAMPP

Problems with the Windows version of XAMPP, questions, comments, and anything related.

FCKEditor does not run with XAMPP

Postby killerwhale65 » 04. September 2007 12:06

Hello all,

I am having a (i think) javascript related problem with XAMPP.

I am trying to load a page with a WYSIWYG editor (http://www.fckeditor.net). Now the strange thing is that when i just open the file in internet explorer, it loads, and i can work with the editor. But when i go there via XAMPP (thus via http://127.0.0.1/...), i see the html but the editor is not showing and i see the javascript error icon in the bottom left of internet explorer.

Should i configur XAMPP somehow to work with javascripts?

thanks for your help,

Matt
killerwhale65
 
Posts: 17
Joined: 21. July 2006 18:48

Postby Izzy » 04. September 2007 12:46

If you go to http://localhost/xampp you should see the Welcome to XAMPP page unless you have changed things from the default setup.

In the left hand menu frame there is a list of menu items.

When you drag you mouse up and down on that list or you hover your mouse over a single item they change color to white and back again when you mouse off the items.

That's a javascript doing that called xampp.js

So if that is working fine then XAMPP and your browser are handling JavaScript correctly.

So if you are having problems with your editor's JavaScript then you should look to it for errors.
http://www.fckeditor.net/forums
might be a good place to ask about this error.

I don't use IE but in my browser if I click on the JavaScript error icon it puts up a window telling what the error is.

Have you tried that in your IE as your error needs to be defined with much more detail to even hazard a guess as to the cause.

Have you tried it with another browser like Firefox, SeaMonkey or Opera 9 ?
Izzy
 
Posts: 3344
Joined: 25. April 2006 17:06

Postby killerwhale65 » 04. September 2007 12:53

hi,

thanks for your quick answer. The XAMMP frontpage works well, the colors of the links (well at least the background color) do change.

I have the same problem in Firefox.

Clicking on the javascript error icon displays a popup. Depending on the sample page i try, i get errors like: object expected, 'FCKLang' is undefined, 'FCKBrowserInfo is undefined ...

The strange thing is that it works all very well when i just open the files from my harddisk in internet explorer (without going via XAMMP).
killerwhale65
 
Posts: 17
Joined: 21. July 2006 18:48

Postby Izzy » 04. September 2007 13:11

XAMPP is doing the right thing then with regard to handling JavaScript.

From your error message it looks like it may be a path or a configuration setting in your script that is not defined correctly.

When you activate the script from within the script's directory then all the paths should be correct.

When you activate the script through the server the path is not correct so you need to look at some configuration settings to correct this issue and my suggestion to ask in the script's forum might get you a quicker result.

JavaScript is a client side language not a server side language like php and perl etc.

So all the server does is locate the files in their respective directories you have configured and send them to your browser.

Your browser parses the script not the server.

If the server is not finding the files etc. that your JavaScript requires then you will get an error.

How to fix it in your scripts will be better answered in their forums as I don't believe it is XAMPP related except for an incorrect path configuration perhaps.

Sorry I can't be much more help.
Izzy
 
Posts: 3344
Joined: 25. April 2006 17:06

Postby killerwhale65 » 04. September 2007 15:23

hi,

i have uploaded the entire script to my website, and there it works! So this is also a server, XAMPP is a server, so i do not understand why it doesnt work in XAMPP. If it would be a path or config issue, it wouldnt work online also.
killerwhale65
 
Posts: 17
Joined: 21. July 2006 18:48

FCKEditor does run with XAMPP

Postby Izzy » 05. September 2007 04:56

FCKEditor does run with XAMPP - see the BTW comment.

In Firefox, there is a very nifty tool called "JavaScript console".
You can use it to debug your JavaScript.
It will give you much more useful error messages than IE's "object expected" (which can mean many things).

A *.js file is more than likely referred in your script's php or html pages by a relative path instead of an actual path which XAMPP is having trouble with.

This is a common problem in some scripts that rely on relative paths and can raise this issue in many ways and is often hard to track down.

You will need to track this down by looking at the top section, the header (the code between the <head> and the </head> html tags), of your php or html pages that call the JavaScripts and look for something like this:
Code: Select all
<script language="JavaScript" type="text/javascript" src="xampp.js"></script>

where xampp.js would be the file name of your particular script's something.js file.

If it doesn't have a path in front like the above, then the something.js file should be in the same folder as the html or php file calling it.

If it resides in it's own javascript directory as is often the case if there are many JavaScript files to a script then it may look like this:
Code: Select all
<script language="JavaScript" type="text/javascript" src="./folder/xampp.js"></script>
or something similar.

This may cause your issue when running on XAMPP but may not cause an issue on a Linux based commercial server or when you run the script from the script's directory, as in your case.

It all depends where you have located your editor script within the XAMPP htdocs tree.

The errors you are having are all script related to path locations within your editor directory and XAMPP's htdocs structure.

Do a Google for these specific key words and you may find a more suitable explanation for your particular situation.
1. FCKeditor object expected
2. 'FCKLang' is undefined
3. 'FCKLang' is undefined

In the results of the above searches you may find that your issues are not peculiar to your situation and you will more than likely get a better understanding of them.

From reading some of the replies myself from the first keywords above I notice that this was/is a bug in FCKeditor in how it handles paths.

As I said before, it is not a specific XAMPP problem only a path that XAMPP is not able to translate into a location.

For more help you will need to provide much more specific info like the location of your script within the XAMPP htdocs structure and any relevant JavaScript file's path locations in the relevant html or php files calling the scripts. Also more detailed JavaScript debug information (error messages).

----------------------------------------
BTW
I just downloaded the FCKeditor 2.4.3.zip and extracted it to my XAMPP's htdocs directory:
C:\xampp\htdocs\fckeditor

I then went to:
http://localhost/fckeditor/_samples/default.html

I had the fckeditor with a list of samples I could select with all of them working when I selected each individual sample, just as they should, with absolutely no errors whatsoever.

I did not change any configuration settings at all.

So for me this FCKeditor worked 'right out of the box' on XAMPP.

Conclusion:
There is nothing wrong with the way XAMPP handles fckeditor.

You have a problem with the way you installed it.

Try what I did above and see if you get the same result.

Visit:
http://wiki.fckeditor.net/Developer.s_G ... stallation

=================================================
Take a look at the new DeskTopXampp launch control posted by ridgewood:
http://community.apachefriends.org/f/viewtopi ... 967#103967

The DeskTopXampp launch control for XAMPP and XAMPPlite (DTX.exe)
is available here:
http://zedfiles.com/DTX/

I highly recommend DTX.
=================================================
Izzy
 
Posts: 3344
Joined: 25. April 2006 17:06

Postby killerwhale65 » 05. September 2007 12:08

hi,

As i do not seem to get any help in the FCKEditor forum, i have to return here, as this is the only place i seem to get help, for which a big big thank you!

i don't understand how it can work for you and not for me. FCKeditor does not need installing, just unzipping so i cant see anything go wrong with that.

here is where the folder fckeditor is located:
D:\business\webdesign\xampp\htdocs\xampp\docs\project CMS

here is how i access it in XAMPP:
http://127.0.0.1/xampp/docs/project%20C ... fault.html

nothing has changed in the fckeditor folder, all files are in the same place.

the javascript console in FF gives a lot of errors. Some errors:
Fout: unterminated string literal
Bronbestand: http://127.0.0.1/xampp/docs/project%20C ... e_gecko.js
Regel: 79

Fout: FCKConfig is not defined
Bronbestand: http://127.0.0.1/xampp/docs/project%20C ... kconfig.js
Regel: 28

Fout: FCKBrowserInfo is not defined
Bronbestand: http://127.0.0.1/xampp/docs/project%20C ... ar=Default
Regel: 58

Fout: FCKConfig_LoadPageConfig is not defined
Bronbestand: http://127.0.0.1/xampp/docs/project%20C ... ar=Default
Regel: 89
killerwhale65
 
Posts: 17
Joined: 21. July 2006 18:48

Postby Izzy » 05. September 2007 13:03

Sorry to hear you can't get any help from the FCKeditor forums.

I have just created your directory structure to try and reproduce these issues but like before it is working perfectly - very strange.

Tried it in Opera 9, IE6, Safari, Firefox and SeaMonkey and all load fine using 127.0.0.1 and localhost

I looked at the JavaScript code in the first Firefox report and unfortunately they have tried to obfuscate the code by putting everything on just a few lines. Which could be part of this problem due to corruption of the code.

This unterminated string literal is usually a script typo error - a comma out of place or spreading a string across multiple lines etc.

This alone leads me to wonder if during download and/or during unpacking the zip file there has been some corruption.

It is not uncommon for this to happen.

I have even known it happen to some XAMPP downloads people have experienced.

Might I suggest you delete that directory and download a fresh copy of the zip file and try again.

What zip proggy do you use?

I use the free 7zip http://www.7-zip.org to unpack zip files as XAMPP uses it to pack their distros.

A very reliable prog.

Unpack the fckeditor directory in the same place the zip file is in like the Desktop if you download it there.

Then drag the unpacked folder to it's project CMS directory as sometimes the space in a directory name can cause strange issues.

It has to be something wrong in the code in that directory.

What about translation issues if you are using a different language?

I am clutching at straws because I can't reproduce this problem you have and I seem to be exhausting my ideas (guesses). See how you go downloading a fresh zip unless you have tried that already.

=================================================
Take a look at the new DeskTopXampp launch control posted by ridgewood:
http://community.apachefriends.org/f/viewtopi ... 967#103967

The DeskTopXampp launch control for XAMPP and XAMPPlite (DTX.exe)
is available here:
http://zedfiles.com/DTX/

I highly recommend DTX.
=================================================
Izzy
 
Posts: 3344
Joined: 25. April 2006 17:06

Postby killerwhale65 » 05. September 2007 14:42

hi,

i did as you told, but still the same errors. I have tried both the nightly build and the stable one, but its always exactly the same.
killerwhale65
 
Posts: 17
Joined: 21. July 2006 18:48

FCKEditor not work on xampp

Postby Parikesit » 19. September 2007 21:27

Hi,

I install XAMPP 1.6.0a on my PC and my laptop. The FCKEditor work well on both machine.

When I need larger storage for my PC, I bought new hard-disk and install new windows (XP2). But bummm... after that, all FCKEditor not work on my PC.

All setting are same. XAMPP version are same. Why it's not works? :evil:

Anyway, fckeditor still work on my laptop with same XAMPP version.

IMHO... this is very strange error

Zaenal
Parikesit
 
Posts: 3
Joined: 19. September 2007 21:08

Re: FCKEditor not work on xampp

Postby Parikesit » 19. September 2007 22:03

Still no clue...

I just install WAMP and FCKEditor still not show up.
Parikesit
 
Posts: 3
Joined: 19. September 2007 21:08

FCKeditor Fixed

Postby Parikesit » 20. September 2007 00:21

:idea: Fixed...

Still not know what happen with my PC, but at least FCKEditor run well on my PC, both in IE and Firefox.

I do not know what exactly fix this problem, but you can try below steps:

1. Clear your cache, both IE or Firefox :?:
Maybe your file corrupted and still reside in your cache.

Try again to open FCKeditor in localhost. If the problem still there, so maybe it's come from your OS

2. update your windows
(That's what I did at the first time, before clearing the cache)

After you update your windows, back again to step 1.


Hope this help!

Best,
Zaenal
Parikesit
 
Posts: 3
Joined: 19. September 2007 21:08

Postby Izzy » 20. September 2007 01:25

You would of course receive more of a technical response to FCKEditor issues from their own Forum, perhaps.
http://www.fckeditor.net/forums


=================================================
Take a look at the new DeskTopXampp launch control for XAMPP and XAMPPlite (DTX.exe)
http://nat32.com/dtx/
posted by ridgewood:
http://community.apachefriends.org/f/viewtopi ... 967#103967
Also available here: http://zedfiles.com/DTX/
I highly recommend DTX.
=================================================
Izzy
 
Posts: 3344
Joined: 25. April 2006 17:06

Postby petran » 18. October 2007 17:36

Hello,
I'm new to this forum but I read your thread and this is exactly what is happening to my installation as well.

I'm using WAMP 5, and I have problems with both fckeditor and tinyMCE. It's very weird, opening the example files from both editors works fine when opening them from the filesystem, but not from the browser hitting my apache server.

What I did, is compare the SAME files from the filesystem, and the .js file apache served and discovered that they are different (the .js file served from apache had some text missing, and other parts repeating themselves which resulted to javascript errors)!

I used the default installation of WAMP and this does not seem to be a common problem, so I'm guessing that something weird is happening...

Anyway, I just wanted to share my experience in this..

Petros
petran
 
Posts: 2
Joined: 18. October 2007 17:24

Postby petran » 18. October 2007 19:27

To any other user with the same problem, these lines in httpd.conf will solve the problem:

EnableMMAP off
EnableSendfile off

Regards,
Petros
petran
 
Posts: 2
Joined: 18. October 2007 17:24

Next

Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 119 guests