Page 1 of 1

how to access widget inside the panelwidget

Posted: Wed Oct 17, 2012 9:01 pm
by rammohan.acharyadasa

hi
i have panel widget type is "HTML".
i edited the html and added section . inside section i added etc..
How can i increase the width of the audio widget(id is "myad")
i tried audio widget using custom javascript like this
$('div[dsid="myad"]').css('height','300px')
but it does not work.


how to access widget inside the panelwidget

Posted: Wed Oct 17, 2012 10:24 pm
by maxkatz

You can use jQuery to select the element in the DOM.

I'm not sure why:
code
$('div[dsid="myad"]').css('height','300px')
/code

doesn't work. Look at the source and make sure you are selecting the right element.


how to access widget inside the panelwidget

Posted: Wed Oct 17, 2012 10:42 pm
by rammohan.acharyadasa

when itry
$('div[dsid="myad"]').length
it gives value as 0.


how to access widget inside the panelwidget

Posted: Wed Oct 17, 2012 10:46 pm
by rammohan.acharyadasa

this is what i have in
panelwidget:
"div id="pan1" data-role="header" data-position="fixed" min-width="100%"
audio id= "myad" controls="controls" preload="auto"
source src="[url=http://mywebsite.org\test.mp3]http://mywebsite.org\test.mp3[/url]" type="audio/mpeg"
/audio


note: as i can not type "opening tag" here, i just removed it

please let me know how to access myad in custom javascript


how to access widget inside the panelwidget

Posted: Thu Oct 18, 2012 2:01 am
by maxkatz

I don't see dsid in the generated source.. just use the id attribute.