Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Web and WebWorks Development

Reply
Developer
Posts: 166
Registered: ‎02-15-2012
My Device: Playbook 16GB
My Carrier: Bags are useful

Back button not working bbui

Hi,

 

I've got a problem where my back button doesn't work:

<!DOCTYPE HTML>
<script src="js/play.js"></script>
<div style="background-color: #252525" data-bb-type="screen" data-bb-effect="fade">
<div data-bb-type="title" data-bb-caption="Sounds" data-bb-back-caption="Back"></div>

      	<div data-bb-type="round-panel"> 
		<div data-bb-type="panel-header">Sound Test:</div>
		<div data-bb-type="label-control-container">
		<div align="center">
        <div class="center" id="actind" data-bb-type="activity-indicator" data-bb-size="large"></div>
        <div id="audio"></div>
        <div data-bb-type="button" data-bb-style="stretch" onclick="playSound('sounds/test.mp3');" >PLAY</div>
        <div data-bb-type="button" data-bb-style="stretch" onclick="stopsound();" >STOP</div>
        </div>
        
        </div>
	</div>

 My back button works perfectly before I press Play. Once the button has been pressed, you cant go back even if you press stop.

 

Here is my play.js:

function playSound(soundfile) {
 document.getElementById("audio").innerHTML=
 "<embed src=\""+soundfile+"\" hidden=\"true\" autostart=\"false\" loop=\"false\" />";
 document.getElementById('actind').show();
 
 }

function stopsound() {
document.getElementById("audio").innerHTML="";
document.getElementById('actind').hide();
}

 Any help appreciated thanks,

If any post helps you please click the Like Button below the post(s) that helped you.
2. Please resolve your thread by marking the post "Solution?" which solved it for you!

Developer
Posts: 322
Registered: ‎08-06-2012
My Device: Dev Alpha / Playbook / Curve 9300

Re: Back button not working bbui

Are there any error messages in the web inspector?

 

Code looks clean though...  Have you tried posting this at the bbui issues on github?

If it helped you, click like. :smileyhappy:
Developer
Posts: 166
Registered: ‎02-15-2012
My Device: Playbook 16GB
My Carrier: Bags are useful

Re: Back button not working bbui

Here is the exact error I get when I press the back buton in the google chrome ripple emulator:

 

  1. Uncaught Error: NETWORK_ERR: XMLHttpRequest Exception 101  -  ripple.js:484

 

    1. (anonymous function)  -  ripple.js:484
    2. bb.loadScreen  -  bbui-0.9.6.js:290
    3. bb.popScreen  -  bbui-0.9.6.js:733
    4. (anonymous function)  -  bbui-0.9.6.js:4503
       
       
       

If any post helps you please click the Like Button below the post(s) that helped you.
2. Please resolve your thread by marking the post "Solution?" which solved it for you!