Posted on: 02/22/06 09:51am
By: Robin
Maybe someone already has experienced this.
The integrated FCKeditor strips SCRIPT tags.
Basically, when you disable the advanced editor, script (Google adsense) works like a charm. When you enable the editor all you get is this:
<!--{PS..6}--> <!--{PS..7}-->
and this should look like
<script type="text/javascript"><!--
google_ad_client = "pub-0698042900796858";
google_ad_width = 468;
google_ad_height = 60;
google_ad_format = "468x60_as";
google_ad_type = "image";
google_ad_channel ="4837792290";
google_color_border = "DFF2FD";
google_color_bg = "DFF2FD";
google_color_link = "0000CC";
google_color_url = "008000";
google_color_text = "000000";
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js</script>
Please give me some insight please 'cause it drives me crazy and I've run out of ideas
Using GL 1.4.0
FF 1.5
Many TIA
FCKeditor strips script tags
Posted on: 02/22/06 10:04am
By: beewee
I've noticed that as well, and it should also effectthe PHP code in Static pages too I guess. Would it be possible to:
- Disable the advanced editor
- Make a separate block with the adsense code
- Enable the advanced editor
- Make any Static Page you want, but do NOT touch that Adsense block again!
I've tried several places for the Adsense banners, and found out it is best (at least at www.kampeerzaken.nl) to put the Adsense code in the templates: article.thtml, events.thtml, featuredstorytext.thtml (I'm rendering every first story as featured story).
FCKeditor strips script tags
Posted on: 02/22/06 10:38am
By: Robin
Thanks beewee for your reply.
The thing is that I would like to play with the ads and to put them into stories in different places.
FCK is a real blessing however in this case it's become a nightmare
FCKeditor strips script tags
Posted on: 02/23/06 03:47am
By: Robin
Anybody knows how to enable script tags under FCK?
It has to be somewhere in FCK but where? That is the question
FCKeditor strips script tags
Posted on: 02/23/06 04:36am
By: Anonymous (anon)
Are you sure this isn't caused by the allowable HTML settings in config.php?
FCKeditor strips script tags
Posted on: 02/23/06 06:06am
By: Robin
[QUOTE BY= anon] Are you sure this isn't caused by the allowable HTML settings in config.php?[/QUOTE]
That was my first suspicion. Then I added this
'script' => array('type' => 1, 'src' => 1)
to $_CONF['admin_html']
$_CONF['admin_html']['script'] = array('type' => 1, 'src' => 1);
to $_CONF['advanced_editor']
And nothing
Then I turned off
$_CONF['skip_html_filter_for_root'] = 1;
and still nothing
FCKeditor strips script tags
Posted on: 02/25/06 07:25am
By: Robin
Now I'm really confused :shock:
I'm not that sure now that this is FCK's fault that script tags don't work in regular stories, because at the same time they perfectly work in staticpages.
What I tested is making a static page with this piece of code
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
and it worked excellent.
Then I copied the source of the static page and pasted it into a story. Saved it and it didn't work. The code above was changed into something like this
<!--&#123;PS..1&#125;-->
As I mentioned earlier I added the script tag to config.thtml. I even switched off the html filtering for the root group.
So let me repeat this cry for help :helpme:
PS
I had to post it in txt mode because html mode strips it strangely
FCKeditor strips script tags
Posted on: 02/27/06 04:44am
By: Robin
It's me again Patiently waiting for solving this issue
FCKeditor strips script tags
Posted on: 02/27/06 07:45am
By: Blaine
I'm not sure we even want to be able to parse PHP in stories or comments.
FCKeditor strips script tags
Posted on: 02/27/06 08:17am
By: Robin
It's not about PHP but javascript
E.g.
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
FCKeditor strips script tags
Posted on: 02/28/06 04:49am
By: Robin
[QUOTE BY= Blaine] I'm not sure we even want to be able to parse PHP in stories or comments.[/QUOTE]
Further to this, you can parse this
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
in regular stories once the script html tag is enabled in config.php (with FCK disabled).
Once you enable the advanced editor the above stops working in stories, however it still does work in staticpages.
FCKeditor strips script tags
Posted on: 03/01/06 07:00am
By: Robin
More and more people use Google Adsense. In order to display the ads you have to add a piece javascript code within
<script> </script>
html tags.
After enabling, adding to the allowed html array, script tag, it is possible to include the code from google in stories. However this stops working, except for staticpages, once the advanced editor is enabled. So my question is whether this is:
FCKeditor related issue?
Geeklog related issue?
Can this be solved somehow?
Is it a bug?
Is it only me that experience this?
So many question and so little time
Thank you for your patience
FCKeditor strips script tags
Posted on: 03/01/06 11:24am
By: ByteEnable
You will have to disable the kses filter in config.php.
// When set to 1, disables the HTML filter for all users in the 'Root' group.
// Obviously, you should only enable this if you know what you're doing and
// when you can trust all the users in the 'Root' group not to use this for
// Cross Site Scripting, defacements, etc. USE AT YOUR OWN RISK!
$_CONF['skip_html_filter_for_root'] = 1;
Byte
LinuxElectrons[*1]
FCKeditor strips script tags
Posted on: 03/01/06 01:09pm
By: Robin
[QUOTE BY= ByteEnable] You will have to disable the kses filter in config.php.
[/QUOTE]
Actually I did it several posts ago
Thank you Byte. Does it work for you BTW?
FCKeditor strips script tags
Posted on: 03/05/06 02:49pm
By: Robin
This is so embarassing but I have to write this
Anyone?
PS
This is the last post as this question seems to be very sensitive one
Thanks everyone for your input.
FCKeditor strips script tags
Posted on: 03/07/06 08:52am
By: casper
This also happens with php-code AND normal text!
I try to edit in "source" mode, but when saving FCK converts all specialchars... For example, the letter Å are saved as &aring;
<=&lt; and so on...
Are there any way of fixing this, or do I have to remove the advanced-template for god and not be able to use on staticpages??
FCKeditor strips script tags
Posted on: 03/16/06 06:13pm
By: samstone
So far I don't need script on my stories yet, but I have upgraded to FCKeditor 2.2 and found it working much stabler.
Maybe you guys should consider upgrading it to 2.2 from the FCKeditor site. It works great for me, with the exception that they no longer use the previous file manager that shows image thumbnails, but only image file names. Good enough for me. The main benefit is that you get a much stabler program.
Sam