Page 1 of 1

[Solved]Advice needed on adding videos to website

Posted: Sat Aug 03, 2013 4:08 am
by jasnick
Have searched the boards but not found much help on this topic. Have been trying to add some videos to a client site.Have downloaded the videos from YouTube and converted them to .flv.

I have tried using HTML5 Video and VideoLightBox and Viscom Web Player. No problem setting them up and they work on my computer. It is when I try to upload them in CMSMS that I run into problems. No matter what application I use I get the same error message as soon as I try to see the page online:

Error: at line 702 in file /home/sitename/public_html/lib/smarty/sysplugins/smarty_internal_templatecompilerbase.php:
Syntax Error in template "088661eaca01c321c4a45ed36819134e6e20377d" on line 8 "<style type="text/css">#videogallery a#videolb{display:none}</style>" - Unexpected ":", expected one of: "}" , " " , ATTR

Full trace:
#0 /home/sitename/public_html/lib/smarty/sysplugins/smarty_internal_templateparser.php(3144): Smarty_Internal_TemplateCompilerBase->trigger_template_error()
#1 /home/sitename/public_html/lib/smarty/sysplugins/smarty_internal_templateparser.php(3209): Smarty_Internal_Templateparser->yy_syntax_error(2, ':')
#2 /home/sitename/public_html/lib/smarty/sysplugins/smarty_internal_smartytemplatecompiler.php(105): Smarty_Internal_Templateparser->doParse(2, ':')
#3 /home/sitename/public_html/lib/smarty/sysplugins/smarty_internal_templatecompilerbase.php(192): Smarty_Internal_SmartyTemplateCompiler->doCompile('?<base href="ht...')
#4 /home/sitename/public_html/lib/smarty/sysplugins/smarty_internal_template.php(187): Smarty_Internal_TemplateCompilerBase->compileTemplate(Object(Smarty_Internal_Template))
#5 /home/sitename/public_html/lib/smarty/sysplugins/smarty_internal_templatebase.php(155): Smarty_Internal_Template->compileTemplateSource()
#6 /home/sitename/public_html/lib/classes/class.Smarty_CMS.php(323): Smarty_Internal_TemplateBase->fetch('string:?<base h...', 'p64', NULL, NULL, false, false, false)
#7 /home/sitename/public_html/plugins/function.metadata.php(63): Smarty_CMS->fetch('string:?<base h...')
#8 /home/sitename/public_html/tmp/templates_c/c8d427a3d6348d3d0ab2de86125a6d2fd0b30f22.tpl_head.23.php(30): smarty_function_metadata(Array, Object(Smarty_Internal_Template))
#9 /home/sitename/public_html/lib/smarty/sysplugins/smarty_internal_templatebase.php(180): content_51fc723f0e34a2_92422126(Object(Smarty_Internal_Template))
#10 /home/sitename/public_html/lib/classes/class.Smarty_CMS.php(323): Smarty_Internal_TemplateBase->fetch('tpl_head:23', 'p64', NULL, NULL, false, false, false)
#11 /home/sitename/public_html/index.php(241): Smarty_CMS->fetch('tpl_head:23')
#12 {main}

Line 702 = throw new SmartyCompilerException($error_text);

I have tried searching for template "088661eaca01c321c4a45ed36819134e6e20377d"

but cannot locate it.

Have been trying to do this for 3 days now - it looks like a simple tag not closed? but where?

I have even tried just embedding a video from YouTube - I can see the video in my editing page, even play it, but as soon as I click on submit and try to open it onine, I get the error message. I keep clearing the cache after trying each application, to no avail. Have tried this on another site with no problems so this is site specific.

Thanks

Re: Advice needed on adding videos to website

Posted: Sat Aug 03, 2013 8:23 am
by velden
c8d427a3d6348d3d0ab2de86125a6d2fd0b30f22.tpl_head refers to the <head></head> part of your template.

It looks like your pasting there some code with css stylesheet in it.

You should know that CMSMS uses the Smarty engine. Smarty uses { and } for the tags. CSS uses those too, so there is your conflict.

You could enclose the code within {literal} {/literal} smarty tags. That will make smarty ignore the code between those tags.

Smarty 3, used in the latest versions of cmsms, also ignores { and } IF there's at least one space before and after them.

Code: Select all

<style type="text/css">
{literal}
#videogallery a#videolb{display:none}
{/literal}
</__script>
or (if current version of cmsms)

Code: Select all

<style type="text/css">
#videogallery a#videolb { display:none } 
</__script>

Re: Advice needed on adding videos to website

Posted: Sat Aug 03, 2013 10:05 am
by jasnick
Thanks velden - YES! - I haven't had to use the {literal}{/literal} tags for a long while and had completely forgotten about them.

Thanks again! I'll mark this solved!