Fck editor image upload no longer works in 1.0.4

For questions and problems with the CMS core. This board is NOT for any 3rd party modules, addons, PHP scripts or anything NOT distributed with the CMS made simple package itself.
Post Reply
vandal
New Member
New Member
Posts: 8
Joined: Fri Jan 12, 2007 11:41 pm

Fck editor image upload no longer works in 1.0.4

Post by vandal »

When you use the WYSWYG Fck editor and click the image button, then click the upload tab within the pop-up and then search for an image and send it to the server it says it worked just fine but the image never gets uploaded. The file browser still works for uploading but most of my end users are used to using this feature.

Does anyone have a fix for this?

Thanks,

van
casidougal
Forum Members
Forum Members
Posts: 98
Joined: Tue Jun 06, 2006 10:08 pm

Re: Fck editor image upload no longer works in 1.0.4

Post by casidougal »

I'm having the exact same issue. A work around is not having the users go to the upload tab on the Image Properties window but rather to hit the "browse server" button on the default image info tab and upload the image that way.

It is an annoyance however as it adds an element of confusion for the "simple" non-technical users for whom CMSMS caters.

I would be interested to find a solution to the upload tab as well.

BTW. I think this issue has always been around, not something new to 1.0.4
Last edited by casidougal on Tue Feb 20, 2007 6:56 pm, edited 1 time in total.
vandal
New Member
New Member
Posts: 8
Joined: Fri Jan 12, 2007 11:41 pm

Re: Fck editor image upload no longer works in 1.0.4

Post by vandal »

I know 100% it worked in 1.0.2. and pretty sure it worked in 1.0.3.

So it is a recent issue. It is confusing using the browse server button for an end user. There must be someone out there that knows how to fix this.

Thanks,

van
casidougal
Forum Members
Forum Members
Posts: 98
Joined: Tue Jun 06, 2006 10:08 pm

Re: Fck editor image upload no longer works in 1.0.4

Post by casidougal »

Interesting...I've used CMSMS quite a while but I've not relied much on uploading content through FCK. I'm paying more attention to FCK now since I'm trying to utilize CMSMS for my clients blog posting.

Regarding the prior versions, I do know for sure that I've run into this same issue intermittently with versions going back to .13 . . . I just really never paid that much attention.

Just out of curiosity, do you have any modules installed in this current application of CMSMS that you didn't typically use in the past?  I've found that modules, or combinations of them, then to be culprits for the weird quirks I run into every once in a while within CMSMS.
Last edited by casidougal on Tue Feb 20, 2007 7:36 pm, edited 1 time in total.
vandal
New Member
New Member
Posts: 8
Joined: Fri Jan 12, 2007 11:41 pm

Re: Fck editor image upload no longer works in 1.0.4

Post by vandal »

I have some custom modules I wrote, but it only began doing this when I upgraded the changed files to 1.0.4

I have an old 0.13 install around too and confirmed that the upload works just fine.
carasmo
Power Poster
Power Poster
Posts: 506
Joined: Thu Feb 08, 2007 6:11 pm

Re: Fck editor image upload no longer works in 1.0.4

Post by carasmo »

Since the browse server and that upload function works and I don't have the chops to figure out how to make it work the normal way. I commented out the tabs in these files:

/modules/FCKeditorX/FCKeditor/editor/dialog/fck_image/fck_image.js


Lines 30 - 49

Code: Select all

// Set the dialog tabs.
window.parent.AddTab( 'Info', FCKLang.DlgImgInfoTab ) ;

if ( !bImageButton && !FCKConfig.ImageDlgHideLink )
	window.parent.AddTab( 'Link', FCKLang.DlgImgLinkTab ) ;

//if ( FCKConfig.ImageUpload )//
//	window.parent.AddTab( 'Upload', FCKLang.DlgLnkUpload ) //;

if ( !FCKConfig.ImageDlgHideAdvanced )
	window.parent.AddTab( 'Advanced', FCKLang.DlgAdvancedTag ) ;

// Function called when a dialog tag is selected.
function OnDialogTabChange( tabCode )
{
	ShowE('divInfo'		, ( tabCode == 'Info' ) ) ;
	ShowE('divLink'		, ( tabCode == 'Link' ) ) ;
	//ShowE('divUpload'	, ( tabCode == 'Upload' ) ) ;//
	ShowE('divAdvanced'	, ( tabCode == 'Advanced' ) ) ;
}
Now it's like it's not even there and doesn't confuse the end users.
casidougal
Forum Members
Forum Members
Posts: 98
Joined: Tue Jun 06, 2006 10:08 pm

Re: Fck editor image upload no longer works in 1.0.4

Post by casidougal »

Carasmo,

Thanks for the common sense approach and fix...much appreciated.
vandal
New Member
New Member
Posts: 8
Joined: Fri Jan 12, 2007 11:41 pm

Re: Fck editor image upload no longer works in 1.0.4

Post by vandal »

This isn't a fix but a workaround. Thanks though carasmo.

Does anyone have an actual fix?
casidougal
Forum Members
Forum Members
Posts: 98
Joined: Tue Jun 06, 2006 10:08 pm

Re: Fck editor image upload no longer works in 1.0.4

Post by casidougal »

This is an honest question...why would you need it to work if the fix, eh workaround, posted above works?  Is there something the upload function on that tab does differently?
vandal
New Member
New Member
Posts: 8
Joined: Fri Jan 12, 2007 11:41 pm

Re: Fck editor image upload no longer works in 1.0.4

Post by vandal »

After wading through the code I have a real fix.

open \modules\FCKeditorX\FCKeditor\editor\filemanager\upload\php\upload.php

add:

Code: Select all

require_once(dirname(dirname(dirname(dirname(dirname(dirname(dirname(dirname(__FILE__)))))))) . '/include.php');
check_login();
after the initial comments so the file looks like this

Code: Select all

<?php 
/*
 * FCKeditor - The text editor for internet
 * Copyright (C) 2003-2006 Frederico Caldeira Knabben
 * 
 * Licensed under the terms of the GNU Lesser General Public License:
 * 		http://www.opensource.org/licenses/lgpl-license.php
 * 
 * For further information visit:
 * 		http://www.fckeditor.net/
 * 
 * "Support Open Source software. What about a donation today?"
 * 
 * File Name: upload.php
 * 	This is the "File Uploader" for PHP.
 * 
 * File Authors:
 * 		Frederico Caldeira Knabben (fredck@fckeditor.net)
 */

require_once(dirname(dirname(dirname(dirname(dirname(dirname(dirname(dirname(__FILE__)))))))) . '/include.php');
check_login();

require('config.php') ;
require('util.php') ;
and now it works.
Last edited by vandal on Tue Feb 20, 2007 10:05 pm, edited 1 time in total.
carasmo
Power Poster
Power Poster
Posts: 506
Joined: Thu Feb 08, 2007 6:11 pm

Re: Fck editor image upload no longer works in 1.0.4

Post by carasmo »

Thanks!!!

Do you do freelance php programming? Ahh the real thing.
vandal
New Member
New Member
Posts: 8
Joined: Fri Jan 12, 2007 11:41 pm

Re: Fck editor image upload no longer works in 1.0.4

Post by vandal »

I'm actually not that great of programmer. I am just a decent problem solver. I compared all the files from the 1.0.2 version where this used to work and that line is very important and was missing from that file and of course adding back fixed it all up.

So short answer, you don't want me to write code for you unless it's xhtml/css.

:)
Ted
Power Poster
Power Poster
Posts: 3329
Joined: Fri Jun 11, 2004 6:58 pm

Re: Fck editor image upload no longer works in 1.0.4

Post by Ted »

Thanks for the fix!  It's in svn.
ethical
Forum Members
Forum Members
Posts: 45
Joined: Fri Jan 12, 2007 11:48 pm

Re: Fck editor image upload no longer works in 1.0.4

Post by ethical »

thanks for the fix.
Post Reply

Return to “CMSMS Core”