New Umbraco user here. I am trying to create a Document Type that accepts a youtube < iframe > code as a parameter, to embed on a page. I've seen quite a few examples of youtube-macros, but i'd like to use it as a stand-alone 'object' on the page, not as a macro used in a content-area.
I assume i would need a template that looks something like
And then create a new document type that accepts a textstring as a parameter for the url, but I cant seem to get it to work. Can anyone tell me if im going in the right direction? :) Thanks!
Thanks for ur quick reply. I've looked at that package, I forgot to mention that I am working with Umbraco version 4.0.4.1, which i unfortunately cannot update at the time (not my decision). The uTube package is for versions 4.5 and higher it seems. I have to come up with some custom made solution i think.
The end user can now embed a Youtube video with a Document Type that takes 3 parameters: urlVideo (textstring), positionWidth (numeric) and positionHeight (numeric).
Youtube video as Document Type?
Hello all,
New Umbraco user here. I am trying to create a Document Type that accepts a youtube < iframe > code as a parameter, to embed on a page. I've seen quite a few examples of youtube-macros, but i'd like to use it as a stand-alone 'object' on the page, not as a macro used in a content-area.
I assume i would need a template that looks something like
And then create a new document type that accepts a textstring as a parameter for the url, but I cant seem to get it to work. Can anyone tell me if im going in the right direction? :) Thanks!
You might want to have a look at the uTube package. That might help.
Jeroen
Hi Jeroen,
Thanks for ur quick reply. I've looked at that package, I forgot to mention that I am working with Umbraco version 4.0.4.1, which i unfortunately cannot update at the time (not my decision). The uTube package is for versions 4.5 and higher it seems. I have to come up with some custom made solution i think.
To be more specific:
When I use a template like this:
It renders the video fine, but once i try to send the video url through a Document Type like this:
it renders the output like this:
<object width="560" height="340"><param name="movie" value="http://www.youtube.com/v/MD5nU7kt7pg?version=3&hl=nl_NL&fs=1&rel=0"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/MD5nU7kt7pg?version=3&hl=nl_NL&fs=1&rel=0" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="560" height="340"></embed></object>
Also, version 4.0.4.1 does not support iframes yet?
This following code renders an error System.Xml.XmlException: '>' is an unexpected token. The expected token is '='.
Hi, for anyone that would like to achieve the same, here's my working solution:
The end user can now embed a Youtube video with a Document Type that takes 3 parameters: urlVideo (textstring), positionWidth (numeric) and positionHeight (numeric).
is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.