sidebar in home/post

Posted in: Newspaper
Post count: 28

Hello

I had special code developed for our site, at http://www.bubblear.com

Its called a “dolar blue widget”.

When I place the html widget in the right sidebar on the very bottom, no problem. When I place it at the top, it seems to gobble up everything below it. However, this only happens when you click a post. On the homepage it works. Any ideas?

home

post

Thanks!

Post count: 3343

Hi,

You say if you move up the widget, on post all widgets will disappear? Can you give me more details about the widget used? Can you give me the code to test it myself here on localhost?

Thanks for the message!

Post count: 28

<script type=”text/javascript”>
jQuery(function() {
jQuery.getJSON( “http://api.bluelytics.com.ar/v2/latest?callback=?&#8221;, function( data ) {
jQuery(‘#blue_bid’).text(data.blue.value_buy.toFixed(2));
jQuery(‘#blue_ask’).text(data.blue.value_sell.toFixed(2));
jQuery(‘#official_bid’).text(data.oficial.value_buy.toFixed(2));
jQuery(‘#official_ask’).text(data.oficial.value_sell.toFixed(2));
});
});
</script>

<aside class=”widget wbluedollar”>

<div id=”sus”>
<div class=”row”>

<div class=”span10 text-center” style=”text-align: right; color: rgb(0, 0, 187); font-size: 1em; font-weight: bold;”></div></div>
<div class=”row” style=”color:#0000bb; font-size:1.3em;”>
<div class=”span6 text-right”>Buy</div>
<div class=”span6 text-center” style=”font-size:1.6em;”><span id=”blue_bid”>-</span></div></div>
<div class=”row” style=”color:#0000bb; font-size:1.3em;”>
<div class=”span6 text-right”>Sell</div>
<div class=”span6 text-center” style=”font-size:1.6em;”><span id=”blue_ask”>-</span></div>
<div class=”span6 text-center” style=”font-size:1.6em;”> </div>
<div class=”span6 text-center” style=”font-size:1.6em;”><span id=”blue_ask”></span></div></div>
<div class=”row”>
<div class=”span10 text-center” style=”text-align: right; color: rgb(0, 187, 0); font-size: 1em; font-weight: bold;”></div></div>
<div class=”row” style=”color:#00bb00; font-size:1.3em;”>
<div class=”span6 text-right”>Buy</div>
<div class=”span6 text-center” style=”font-size:1.6em;”><span id=”official_bid”>-</span></div></div>
<div class=”row” style=”color:#00bb00; font-size:1.3em;”>
<div class=”span6 text-right”>Sell</div>
<div class=”span6 text-center” style=”font-size:1.6em;”><span id=”official_ask”>-</span></div></div>
<div class=”text-right”><small>Powered by Bluelytics</small></div></aside>

</div>
</div>

</aside>

Post count: 3343

Hi,
Sorry but the code provided not work for me: http://screencast.com/t/b9ko7E5or2W

Post count: 28

hello

did you implement the javascript above?

Post count: 28

hey

based on the picture it seems you didnt include the javascript which is necessary. Im not sure why nothing else worked

Post count: 6600

Hi,

Please use http://pastebin.com/ and provide the exact content of your text widget as I have also tested this and had the same result as Marius did.

Thanks

Post count: 28

note the “#sus {

margin-left: 30px;”

is placed in the style.css to properly indent the images.

<script type=”text/javascript”>
jQuery(function() {
jQuery.getJSON( “http://api.bluelytics.com.ar/v2/latest?callback=?&#8221;, function( data ) {
jQuery(‘#blue_bid’).text(data.blue.value_buy.toFixed(2));
jQuery(‘#blue_ask’).text(data.blue.value_sell.toFixed(2));
jQuery(‘#official_bid’).text(data.oficial.value_buy.toFixed(2));
jQuery(‘#official_ask’).text(data.oficial.value_sell.toFixed(2));
});
});
</script>

#sus {

margin-left: 30px;

<aside class=”widget wbluedollar”>

<div id=”sus”>
<div class=”row”>

<div class=”span10 text-center” style=”text-align: right; color: rgb(0, 0, 187); font-size: 1em; font-weight: bold;”></div></div>
<div class=”row” style=”color:#0000bb; font-size:1.3em;”>
<div class=”span6 text-right”>Buy</div>
<div class=”span6 text-center” style=”font-size:1.6em;”><span id=”blue_bid”>-</span></div></div>
<div class=”row” style=”color:#0000bb; font-size:1.3em;”>
<div class=”span6 text-right”>Sell</div>
<div class=”span6 text-center” style=”font-size:1.6em;”><span id=”blue_ask”>-</span></div>
<div class=”span6 text-center” style=”font-size:1.6em;”> </div>
<div class=”span6 text-center” style=”font-size:1.6em;”><span id=”blue_ask”></span></div></div>
<div class=”row”>
<div class=”span10 text-center” style=”text-align: right; color: rgb(0, 187, 0); font-size: 1em; font-weight: bold;”></div></div>
<div class=”row” style=”color:#00bb00; font-size:1.3em;”>
<div class=”span6 text-right”>Buy</div>
<div class=”span6 text-center” style=”font-size:1.6em;”><span id=”official_bid”>-</span></div></div>
<div class=”row” style=”color:#00bb00; font-size:1.3em;”>
<div class=”span6 text-right”>Sell</div>
<div class=”span6 text-center” style=”font-size:1.6em;”><span id=”official_ask”>-</span></div></div>
<div class=”text-right”><small>Powered by Bluelytics</small></div></aside>

</div>
</div>

</aside>

Post count: 6600

Hi,

That css shouldn’t affect the functionally of your code just it’s looks.
Make sure you have your code properly formatted and that you add your custom js code in theme panel custom js field like this: http://screencast.com/t/Xb1y6C1Xe

Thanks

Post count: 28

hey

if I put the custom JS in the theme panel, the widget doesn’t work. If I relocate the JS to the theme and remove from the widget, and relocate the widget to the top of the sidebar, the widgets beneath it on post pages still disappear.

The underlying problem is that if I relocate this widget to the top of the sidebar, it doesn’t stop the other widgets from appearing on the sidebar under it on the homepage, but on POST pages it does. I just have no idea what the problem is.

Nick

Post count: 28

sorry guys, the JS thing worked after i made some changes. I also fixed the other problem, it had some extra div, div, aside on it.

Thanks for your help yet again!

Viewing 11 posts - 1 through 11 (of 11 total)
The forum ‘Newspaper’ is closed to new topics and replies.