Forums / Templates, Stylesheets, Page Layout / How to add a Youtube to the product description page

How to add a Youtube to the product description page

Views: 1,625

Results 1 to 12 of 12
8 Nov 2014, 2:51 PM
#1
jodean avatar

jodean

Totally Zenned

Join Date:
May 2011
Location:
Tennessee
Posts:
511
Plugin Contributions:
0

How to add a Youtube to the product description page

I added the following code to the description of a product page. It draws a empty frame and that's all that it does. I want the Youtube to display its first part of the video image and allow me to play, pause, etc.

"<iframe width="853" height="510" src="//www.youtube.com/embed/CdXcMpS53pE" frameborder="0" allowfullscreen></iframe>"

Does any one have any ideas?

8 Nov 2014, 6:42 PM
#2
stevesh avatar

stevesh

Black Belt

Join Date:
Feb 2005
Location:
Lansing, Michigan USA
Posts:
19,793
Plugin Contributions:
2

Re: How to add a Youtube to the product description page

That link works for me in my test site, on the product info page (though it's much too wide). If you're expecting it to show up in the product listing, Zencart strips HTML from the description there. You can overcome that by searching the forums for zen_clean_html, but it may not be a good idea anyway.

8 Nov 2014, 8:10 PM
#3
jodean avatar

jodean

Totally Zenned

Join Date:
May 2011
Location:
Tennessee
Posts:
511
Plugin Contributions:
0

Re: How to add a Youtube to the product description page

When the page is displayed it detects that the script is unauthenticated.

Here is the message.

"This page includes script from an unauthenticated source."

Then if I load the unsafe script the YouTube is displayed.

Do you have any ideas to get around this?

8 Nov 2014, 8:20 PM
#4
stevesh avatar

stevesh

Black Belt

Join Date:
Feb 2005
Location:
Lansing, Michigan USA
Posts:
19,793
Plugin Contributions:
2

Re: How to add a Youtube to the product description page

No. What browser are you using and is your site running under SSL? A link to the page on your site would help us see the problem, too.

8 Nov 2014, 8:38 PM
#5
jodean avatar

jodean

Totally Zenned

Join Date:
May 2011
Location:
Tennessee
Posts:
511
Plugin Contributions:
0

Re: How to add a Youtube to the product description page

stevesh:

No. What browser are you using and is your site running under SSL? A link to the page on your site would help us see the problem, too.

I am using Google. Yes the site is running under SSL.

Here is the link

<iframe allowfullscreen="" frameborder="0" height="510" src="http://www.youtube.com/embed/CdXcMpS53pE" width="853"></iframe>
8 Nov 2014, 8:52 PM
#6
stevesh avatar

stevesh

Black Belt

Join Date:
Feb 2005
Location:
Lansing, Michigan USA
Posts:
19,793
Plugin Contributions:
2

Re: How to add a Youtube to the product description page

I meant a link to a product page on your site where you have the YouTube video inserted. My guess is that it's some sort of SSL thing. The iframe link may have to be https too.

Why is your whole site under SSL?

8 Nov 2014, 8:57 PM
#7
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: How to add a Youtube to the product description page

I tossed this on a product and tested a secure URL:

<iframe allowfullscreen="" frameborder="0" height="255" src="https://www.youtube.com/embed/CdXcMpS53pE" width="341"></iframe>

NOTE: sizes are reduced 50% so if fit my page ...

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

8 Nov 2014, 9:10 PM
#8
jodean avatar

jodean

Totally Zenned

Join Date:
May 2011
Location:
Tennessee
Posts:
511
Plugin Contributions:
0

Re: How to add a Youtube to the product description page

stevesh:

I meant a link to a product page on your site where you have the YouTube video inserted. My guess is that it's some sort of SSL thing. The iframe link may have to be https too.

Why is your whole site under SSL?

I changed the link to https and it displays the YouTube now. However the browser still sees the script coming from an unauthenticated source.

I set up the SSL according to the tips in the forum.

Here is the link https://tennesseetraditionalflies.com/index.php?main_page=product_info&products_id=846&cPath=8_75

8 Nov 2014, 9:32 PM
#9
jodean avatar

jodean

Totally Zenned

Join Date:
May 2011
Location:
Tennessee
Posts:
511
Plugin Contributions:
0

Re: How to add a Youtube to the product description page

stevesh:

I meant a link to a product page on your site where you have the YouTube video inserted. My guess is that it's some sort of SSL thing. The iframe link may have to be https too.

Why is your whole site under SSL?

Steve I think I found the code that was causing the problem. I had downloaded the You Tube Plugin from one of the forums that added a You Tube field and code to the product pages. When I turn the plugin off the link appears to work and not give the unauthenticated message. I do not understand exactly what caused the problem. I am going to back out the You Tube code field changes and the display problem should be fixed.

If you have any recommendations regarding the SSL setup I would like to hear them.

8 Nov 2014, 9:52 PM
#10
stevesh avatar

stevesh

Black Belt

Join Date:
Feb 2005
Location:
Lansing, Michigan USA
Posts:
19,793
Plugin Contributions:
2

Re: How to add a Youtube to the product description page

There's no reason to use that plugin that I'm aware of, so you should be good.

No recommendations, but I don't see any compelling reason to secure the whole site. Zencart secures the pages which require it, and securing the whole thing can cause page load time issues. I'm aware Google claims to prefer SSL on all sites, but the slow loading of their own site is one of the things that led me to use Bing for search.

8 Nov 2014, 10:17 PM
#11
jodean avatar

jodean

Totally Zenned

Join Date:
May 2011
Location:
Tennessee
Posts:
511
Plugin Contributions:
0

Re: How to add a Youtube to the product description page

stevesh:

There's no reason to use that plugin that I'm aware of, so you should be good.

No recommendations, but I don't see any compelling reason to secure the whole site. Zencart secures the pages which require it, and securing the whole thing can cause page load time issues. I'm aware Google claims to prefer SSL on all sites, but the slow loading of their own site is one of the things that led me to use Bing for search.

Steve,

Thanks for your help. I have gone back to before the plugin was added and the YouTube link works.

8 Nov 2014, 10:20 PM
#12
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: How to add a Youtube to the product description page

You appear to have something redirecting all links to SSL pages ... that should be controlled by the settings in your:
/includes/configure.php
/your_secret_admin/includes/configure.php

and not by any rewrites or redirects in .htacess etc.

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!