Joomla 1.6 – Adding iFrame to Articles

by Elaine on February 2, 2011

Using Joomla 1.6, I was trying to add iframe code into my article and was having problems the other day.   I was able to do this perfectly in Joomla 1.5 and now Joomla 1.6 is stripping the code.   Why can’t I add my embedded <HTML> or google Adsense code to my articles anymore??!  Should I throw out my editor?  I was getting extremely frustrated.  After a day of monkeying around with the options, I finally found out where to make changes in the Joomla 1.6 administrator backend to enable embedded codes or iframe in my articles.

With Joomla 1.6, you can control text and links that users use to enter articles into your website.  With your different ACL’s now, you can restrict some users from being able to enter in any HTML tags and thereby managing the type of content users can submit to your website.  You can be as strict or as liberal as you require to suit your site needs. The text filtering is optional and the default settings provide good protection against any HTML markup commonly associated with Web site attacks.

Here are steps on how you can modify the settings for your “Super Users” account to have access to add iFrame code into articles:

1.  Log in to your Joomla Administrator panel

2.  Click on ‘Content’,’Article Manager, and click on the button ‘Options

3.  Click on the ‘Text Filters‘ tab.

4.  Go to the ‘Super Users’ and select from the dropdown – ‘No Filtering’.

5.  Save the options and refresh your site.

6.  If you are using TinyMCE editor, go to the editor options – Extensions menu > Plug-in Manager > Editor-TinyMCE  (Tip provided by John)

7.  Disable “clean up on save”.  (Tip provided by Adam.)

Refreshing your site and create a new article.  There is no need to throw out or change your Joomla 1.6 editor.  You should be able to add iframe or any embedded html codes and the editor will not strip your code.  I love Joomla again.

 Joomla 1.6   Adding iFrame to Articles

Elaine

Elaine is the founder of CmsMind, an online blog providing Joomla and Wordpress tutorials. Elaine lives in Toronto and when she is not online, she is either Marathon and Triathlon training or travelling and racing somewhere in the world. Find her also at: Save Money, Premium Themes and Templates, and at Webhosting Tips.

More Posts - Website

{ 64 comments… read them below or add one }

William Wells February 12, 2011 at 11:00 am

Greetings… upon taking the steps you mentioned above… completely closing down my browser… and starting from scratch (just to make sure)… my editor still strips the code… any thoughts?

Reply

William Wells February 12, 2011 at 11:30 am

Greetings Again… my apologies for taking up your time with my question… I did a little more digging and had to make some modifications to the editor plug-in as well…

As a result… all is well! Thanks!

Reply

Enzolina February 12, 2011 at 11:34 am

Hi William,

Thanks for visiting my site. Congrats on fixing your problem. Just curious, Which editor plugin are you using and what modifications did you make?

Thanks,
Elaine

Reply

Scott Jarvis February 15, 2011 at 10:10 pm

Thank you for this information. I was going crazy trying to figure this out and really didn’t have the patience tonight to review the documentation to determine if this was a bug.

I’m up and running in no time at all thanks to Elaine.

Your trash filter post was another that helped me. Keep the good tips coming.

Much Appreciated,
Scott

Reply

Enzolina February 15, 2011 at 10:33 pm

Hi Scott,

Thanks for your visit! I’m glad my posts helped you.

elaine

Reply

Adam February 17, 2011 at 11:04 am

Hi! Thanks to your advice i was able to embedd google maps iFrame in my Joomla 1.6 website! Thanks alot. One thing i must mention. I have disabled “clean-up on save” in TinyMCE editor options.

Reply

Enzolina February 17, 2011 at 11:07 am

Hi Adam, np! Thanks for your visit. Oh, thanks for the TinyMCE editor tip as well. I’ll add that in to the post. Hopefully it will help others as well.
-elaine

Reply

Starky February 18, 2011 at 3:11 pm

Made the “No Filtering” change and same problem.

What other changes mut be made to the editior? I’m using TinyMCE.

Thanks

Reply

Enzolina February 18, 2011 at 9:36 pm

Hi Starky,
If you are using TinyMCE editor, go to your editor options and disable “clean up on save”.
Hope that helps!
Elaine

Reply

Brandala March 3, 2011 at 11:32 pm

This is great! Thank you for sharing. It worked like a treat.

Reply

Enzolina March 4, 2011 at 5:31 am

Hi Brandala,
Thanks for your visit. Glad the post was helpful.
Regards,
Elaine

Reply

deno March 5, 2011 at 11:17 pm

superb.. this instantly cure my headache :)

Reply

Enzolina March 6, 2011 at 5:57 pm

Hi Deno,

Thanks for your visit and I’m glad the post was useful to you.

Regards,
Elaine

Reply

Alan March 23, 2011 at 7:34 pm

Thanks so much for this! I was having problems and tried fixing it for about 2 hours including trying another editor. Then I found your article, followed your steps and bam! All fixed.

Reply

Elaine March 31, 2011 at 9:54 pm

Hi Alan,
No problem. Thanks for your visit!
Elaine

Reply

Mac March 24, 2011 at 10:31 am

I’m not using any editor and the javascript from my adsense is still being stripped….any suggestions?

Reply

Elaine March 31, 2011 at 10:08 pm

Hi Mac, I’m not too sure what you mean. Have you tried the steps in the post? It should work…Have you tried any other html codes to see if they get stripped from your post?
Let me know. Thanks for your visit.
elaine

Reply

Kess April 13, 2011 at 1:43 pm

Thanks a lot for this information. Saved me from installing a plugin for google maps.

Reply

Elaine April 13, 2011 at 1:45 pm

Hi Kess,
No Problem! Happy that my post helped you.
Thanks for your visit,
elaine

Reply

John April 15, 2011 at 3:42 pm

Where do I find the editor options so I can disable ‘cleanup on save’?

Reply

John April 15, 2011 at 3:58 pm

Nevermind, I found it.

Extensions menu > Plug-in Manager > Editor-TinyMCE

Everything is working perfectly now. Thanks.

Reply

Elaine April 15, 2011 at 3:59 pm

Hi John,
That’s great. I’ll add your tip to the post!
Thanks for your visit,
Elaine

Reply

nniiccoollee May 16, 2011 at 7:43 pm

Hi! Just wanted to say thank you for documenting this feature of Joomla 1.6! I assumed my editor was jiggy, but after a re-install and no-go, I was back to square 1 until I found your post!

THANK YOU!!!!

Reply

Elaine May 16, 2011 at 7:49 pm

Hi Nicole,
I’m glad my post helped you! :)
Thanks for your visit,
elaine

Reply

Peeyush Chandel May 19, 2011 at 7:55 am

Thanks you very much for the solution,it help me a lot :-)

Reply

Elaine May 19, 2011 at 11:43 am

Hi Peeyush,

No problem. Glad the post can help you.

Thanks for your visit,
elaine

Reply

Jon May 27, 2011 at 11:10 am

Hi guys,
I’ve been chasing this problem for weeks, I’ve just about read everything there is about this ‘Stripping of code” and tried everything without success.
I’m using:
XP Pro.
Joomla! 1.6.1
PHP Built On Linux cpanel28.per.syra.net.au 2.6.18-194.32.1.el5 #1 SMP Wed Jan 5 17:52:25 EST 2011 x86_64
Database Version 5.0.92-community
Database Collation utf8_general_ci
PHP Version 5.3.2
Web Server Apache/2.2.15 (Unix) mod_ssl/2.2.15 OpenSSL/0.9.8e-fips-rhel5 mod_bwlimited/1.4 mod_perl/2.0.4 Perl/v5.8.8
WebServer to PHP Interface cgi-fcgi
Joomla! Version Joomla! 1.6.1 Stable [ Onward ] 07-Mar-2011 23:00 GMT
User Agent Mozilla/5.0 (Windows NT 5.1; rv:2.0.1) Gecko/20100101 Firefox/4.0.1
It’s got to the point were I’m not game to update a page for fear of losing code.
I would really love to find a fix for this.
Cheers.

Reply

Jon May 27, 2011 at 12:32 pm

Just to add, I have tried Chrome, IE8 and Safari without any luck.

Reply

Elaine May 28, 2011 at 11:11 am

Hi Jon,
Sorry for the late reply, I’m glad you were able to resolve your problem.
Thanks for your visit,
elaine

Reply

Ted May 30, 2011 at 12:47 pm

Hello – I am attempting to insert a donation button into a Joomla 1.6 site and have tried all options mentioned. This is what I have attempted so far but code still being altered: Using “no editor” – Using TinyMCE – removing code cleanup from plugin. JCE – Superadmin “No Filtering”… all continue to modify my code. Here is the code I am attempting to insert:

Using no editor for example after save this is what remains of the code:

As you can see – the method and post functions are being attacked and altered.

Can someone please offer an explanation to this problem and a suggested solution.

Much Thanks,

T

Reply

Ted May 30, 2011 at 12:52 pm

Funny – your site even stripped out the code… lol – here is the code mentioned above in quotes…

“”### (bracket) form name=”PrePage” method = “post” action = “https://Simplecheckout.authorize.net/payment/CatalogPayment.aspx”> </form(bracket)""##

Reply

Mercury June 4, 2011 at 10:39 am

I have followed all the steps above, even put the ‘no filtering’ on and still the javascript gets stripped in joomla 1.6

Reply

leo June 9, 2011 at 12:23 pm

tnx a lot. This is exactly the first part of my “headache”
But …
firebug help me for proof me, “the html (iframe) appear in the code”.
But the content whitin the iframe doesn’t appear…
arf

Life is beatifull…

Reply

Fiachra June 20, 2011 at 3:18 pm

Hi there,

I just spent quite a lot of time being frustrated trying to find a way to do this using various plug-ins and Google API nonsense (I was just trying to get a map in my article). Why they changed the nice and simple way of doing it from 1.5 I don’t know. Anyway thanks to your article I have now set it up in about 1 1/2 minutes! Thank you so much! You just saved a whole lot of mucking around with nonsense.

I really appreciate it!

Reply

Elaine June 20, 2011 at 3:34 pm

Hi Fiachra,
Yeah, the 1.5 editor was perfectly fine. lol Took me a while to figure it out too. Well I’m glad my post helped you!
Thanks for your visit,
elaine

Reply

Tom June 21, 2011 at 6:58 am

Hello, I tried Google maps paste the code as it is written here and you can not. Editor pastes, and is well visible, but after writing disappears and you can not see, do you know how to solve the problem? Yours

Reply

Tom June 21, 2011 at 7:32 am

I set something wrong, now is a good excuse for a bad post: (

Reply

Elaine June 21, 2011 at 11:17 am

Hi Tom,
Sorry are you still having problems?
Thanks for your visit,
elaine

Reply

Beth July 5, 2011 at 5:00 pm

Thank you! This worked out great.

Reply

Elaine July 5, 2011 at 5:19 pm

Hi Beth,
Glad the post helped you. Thanks for your visit.
Elaine

Reply

Kiran August 12, 2011 at 1:21 pm

Hi there ,

Thanks your such valuable suggestions. I was struggling with my Tiny MCE but with your tips now I can insert any code in my article. Thanks A lot for your help !

Reply

Elaine August 12, 2011 at 1:26 pm

Hi Kiran,
No problem. Glad I could help!
Thanks for your visit,
elaine

Reply

Frank August 25, 2011 at 11:32 am

Thank’s.
You saved my day!

Reply

Elaine August 25, 2011 at 12:36 pm

Hi Frank,
No problem! Glad I could help.
Thanks for your visit,
elaine

Reply

Ricardo September 20, 2011 at 3:59 pm

THIS WAS SOOOOOOO HELPFUL… I was looking for the answer for so long. Thanks. I now have to see if this works for J 1.5… ??

GRACIAS !!!

Reply

Elaine September 20, 2011 at 10:31 pm

Hi Ricardo,
No problem! I’m glad i could help.
Thanks for your visit,
elaine

Reply

Deyse November 18, 2011 at 8:08 pm

Muito obrigado, eu estava para ficar doida já! O joola 1.7 é muito bom mas… tem muitas frescuras. Bjo

Reply

Orlando November 19, 2011 at 4:06 pm

Hi Elaine,

Thank´s for the tips, but is not working for me. I follow every single step, and still stripping my iframe code :/ any suggestion?

I´ve been trying another editors, but is always the same :(

Reply

CarolinaG November 30, 2011 at 11:07 pm

YOUR ARTICLE IS WONDERFUL !!!. THANK YOU FOR YOUR TIPS AND FOR YOUR TIME TO SHARE THEM. GREETINGS FROM MEXICO.

Reply

Elaine December 7, 2011 at 2:45 am

Hi Carolina,
Wow Mexico. No problem! Glad the post can help you.
Thanks for your visit,
Elaine

Reply

MarkusMettmann December 4, 2011 at 1:41 pm

Formatierungsfehler im Quelltext Seite wird nicht richtig angezeigt und bei der Seitwertpüfung ser viele Fehler

Reply

Elaine December 7, 2011 at 2:51 am

Hi Markus,
I don’t understand….I tried to use google translate as well, but don’t get the meaning. I’m sorry!
Thanks for your visit,
elaine

Reply

Phil December 10, 2011 at 5:40 pm

Hi evrybody,
I don’t find any “Clean before save” in Tiny MCE with Joomla 1.7 !…
where can I find it ??…
thank you for your help !…
phil

Reply

johny December 14, 2011 at 7:19 am

thank you so much your article had really worked for me

Reply

Elaine December 14, 2011 at 9:52 pm

Hi Johny,
No problem! I’m glad it worked for you!
Thanks for your visit,
elaine

Reply

cssmms January 3, 2012 at 1:05 pm

Bravoooooooo
After spending a lot of time to figure this out.. i found this article usefulll….
Good News for Joomla 1.7 ..
Joomla 1.7 > Admistration > Components > Plug-in Manager > Editor TinyMCE > does not have “Clean up data when save option”. You just have to REMOVE those texts available in “Basic Options>Prohibited Elements”
….just put any dummy text ..if you will leave it empty those text will come back….. just put a dummy text in Prohibited Element and SAVE and enjoy entering scripts… ;)

Thanks Elaine…nice job!!

Reply

Elaine January 3, 2012 at 7:53 pm

Hi,
Thanks so much for your update and glad the post was helpful to you.
Thanks for your visit and happy new year!
elaine

Reply

Daniel January 14, 2012 at 8:19 pm

oooo Thanks very much.
yuo save me :)

Reply

panos January 21, 2012 at 8:09 pm

Thank you my friend,
from Greece

Reply

Elaine January 22, 2012 at 4:46 am

Hi Panos,
No problem, glad my post helped you.
Thanks for your visit,
elaine

Reply

Roberto January 31, 2012 at 5:08 pm

Thanks!
It was very usefull to me!

Reply

Elaine February 1, 2012 at 12:05 am

Hi Roberto,
No problem. Glad my post was useful to you.
Thanks for your visit,
elaine

Reply

Nemanja July 16, 2012 at 7:40 pm

TnX Eliane! Perfect tip! It solved my problem!

Reply

mojgan November 11, 2012 at 7:25 am

Thanks for your useful content, which was a very big help in solving the problem site.

Reply

Leave a Comment

Captcha Captcha Reload

Older Post:

Newer Post: