Post by bryan942 » Tue Jun 15, 2010 12:08 pm

Hi,

I am running OpenCart version 1.4.7 and I am having problems any time i add code or text into any of the text boxes in the admin area.

A few examples...

I am trying to use this code and embed a youtube video into an information page...

Code: Select all

<object width="560" height="340">
<param name="movie" value="http://www.youtube.com/v/hBYNlykw_Xo&hl=en_US&fs=1&rel=0&hd=1"></param>
<param name="allowFullScreen" value="true"></param>
<param name="allowscriptaccess" value="always"></param>
<embed src="http://www.youtube.com/v/hBYNlykw_Xo&hl=en_US&fs=1&rel=0&hd=1" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="560" height="340"></embed>
</object>
So i enter the admin area for the information page I want to work with...go into the description area..., and then change to SOURCE mode.

I then paste the above code in and hit save. When viewing the live information page, I get nothing. When I go back into the admin area to view the code...this is what appears under SOURCE

Code: Select all

<p>
	<object height="\"340\"" width="\"560\""> <param name="\"movie\"" value="\"http://www.youtube.com/v/hBYNlykw_Xo&hl=en_US&fs=1&rel=0&hd=1\"" /> <param name="\"allowFullScreen\"" value="\"true\"" /> <param name="\"allowscriptaccess\"" value="\"always\"" /> <embed allowfullscreen="\"true\"" allowscriptaccess="\"always\"" height="\"340\"" src="%5C%22http://www.youtube.com/v/hBYNlykw_Xo&hl=en_US&fs=1&rel=0&hd=1%5C%22" type="\"application/x-shockwave-flash\"" width="\"560\""></embed> </object></p>
It appears opencart or something server side is doing some sort of processing on the code and putting in special characters and so forth.

Am I doing something wrong or is there just something I am missing?

Newbie

Posts

Joined
Sat Mar 13, 2010 5:24 am

Post by Qphoria » Tue Jun 15, 2010 12:20 pm

After clicking source and pasting, don't switch back. Just save it. ckeditor tries to "fancy" it up and it can sometimes break things

Image


User avatar
Administrator

Posts

Joined
Tue Jul 22, 2008 3:02 am

Post by bryan942 » Tue Jun 15, 2010 7:25 pm

Not switching back from SOURCE view yields the exact same results for me.

Here is a snippet from opening up my webpage and viewing the source code...

Code: Select all

<div class="middle"><object width="\"560\"" height="\"340\""><param name="\"movie\"" value="\"http://www.youtube.com/v/hBYNlykw_Xo&hl=en_US&fs=1&rel=0&hd=1\""><param name="\"allowFullScreen\"" value="\"true\""><param name="\"allowscriptaccess\"" value="\"always\""><embed src="%5C%22http://www.youtube.com/v/hBYNlykw_Xo&hl=en_US&fs=1&rel=0&hd=1%5C%22" type="\"application/x-shockwave-flash\"" allowscriptaccess="\"always\"" allowfullscreen="\"true\"" width="\"560\"" height="\"340\""></object>    <div class="buttons">

Newbie

Posts

Joined
Sat Mar 13, 2010 5:24 am

Post by kotysoft » Mon Jun 11, 2012 3:00 am

I made this:

admin/view/javascript/ckeditor/config.js
Modify, or if not available, insert this line:

Code: Select all

	config.entities = true;

--------------------------------------

catalog/view/theme/ ACTIVE THEME FOLDER /template/information/information.tpl
find this line:

Code: Select all

  <?php echo $description; ?>
and modify to:

Code: Select all

  <?php echo html_entity_decode($description, ENT_QUOTES, 'UTF-8'); ?>
------------------------------------

Flashes, scripts working for me in OC 1.5.2.1
(hopefully AdSense codes, too; but ATM My AdSense account still not approved, so i don't know yet)

New member

Posts

Joined
Sat Feb 06, 2010 10:01 pm
Who is online

Users browsing this forum: Bing [Bot] and 99 guests