A possible solution could be the following:
1) wrap the iframe with a div with class "w2p-video-container"
2) set your css rules by targeting div.w2p-video-container>iframe
For example:
in the view
<div class="w2p-video-container">
{{=XML(expand_one('http://www.youtube.com/watch?v=7yvt2Pt6LRA',cache.ram('mycache',lambda:dict(),3600)))}}
</div>
in the css file
div.w2p-video-container>iframe {width:800px !important; height:600px !
important;}
Il giorno domenica 9 marzo 2014 02:07:03 UTC+1, sasogeek ha scritto:
>
> Can you please give an example how? I tried altering the dimensions from
> the autolinks.py file and it didn't work, and really idk where else i can
> apply css since i don't see the rendering code until after it's rendered...
> what i write is {{=XML(expand_one(... , ...))}} Not sure where or how I can
> apply css to alter the width and height of the rendered iframe element
>
>
> On Thursday, 6 March 2014 13:54:29 UTC, Massimo Di Pierro wrote:
>>
>> You have to use CSS.
>>
>> On Wednesday, 5 March 2014 19:57:05 UTC-6, Samuel Sowah wrote:
>>>
>>> How can I resize the youtube or vimeo embed or google doc viewer
>>> whenever i call expand_one() on a url?
>>>
>>
--
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
---
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.