There is a task to remove background-image from the weather informer code. The problem is that if you remove the class="booked-wzs-160-110" from the HTML code, the actual weather data stops loading, the informer hangs. Tried to prescribe in front of the class style="background-image: none !important;" But whatever I wrote in this style, nothing changes - for some reason the background-color: #transparent; always constantly written background-color: #transparent; and not going anywhere. I'm not strong in javascript, maybe something needs to be registered in it?
< script type = "text/javascript" charset = "UTF-8" src = "http://widgets.booked.net/weather/info?action=get_weather_info&ver=4&cityID=18901&type=1&scode=124<id=3539&domid=589&cmetric=1&wlangID=20&color=transparent&wwidth=250&header_color=ffffff&text_color=333333&link_color=08488D&border_form=1&footer_color=ffffff&footer_text_color=333333&transparent=0" > < /script> <script type="text/javascript "> var css_file=document.createElement(" link "); css_file.setAttribute(" rel "," stylesheet "); css_file.setAttribute(" type "," text / css "); css_file.setAttribute(" href ",'//s.bookcdn.com/css/w/booked-wzs-widget-160.css?v=0.0.1'); document.getElementsByTagName(" head ")[0].appendChild(css_file); function setWidgetData(data) { if(typeof(data) != 'undefined' && data.results.length > 0) { for(var i = 0; i < data.results.length; ++i) { var objMainBlock = document.getElementById('m-booked-bl-simple-7511'); if(objMainBlock !== null) { var copyBlock = document.getElementById('m-bookew-weather-copy-'+data.results[i].widget_type); objMainBlock.innerHTML = data.results[i].html_code; if(copyBlock !== null) objMainBlock.appendChild(copyBlock); } } } else { alert('data=undefined||data.results is empty'); } } </script> <div style=" position: absolute; right: 13px; top: -148px; z-index: 999;" id="m-booked-bl-simple-7511"> <a href="//nochi.com/weather/tbilisi-18901" style="background-image: none !important;" class="booked-wzs-160-110"> <div class="booked-wzs-160-data wrz-01"> <div class="booked-wzs-160-right"> <div class="booked-wzs-day-deck"> <div class="booked-wzs-day-val"> <div class="booked-wzs-day-number"><span class="plus">+</span>21</div> <div class="booked-wzs-day-dergee"> <div class="booked-wzs-day-dergee-val">°</div> <div class="booked-wzs-day-dergee-name">C</div> </div> </div> <div class="booked-wzs-day"> <div class="booked-wzs-day-d"><span class="plus">+</span>21°</div> <div class="booked-wzs-day-n"><span class="plus">+</span>7°</div> </div> </div> <div class="booked-wzs-160-city">Тбилиси</div> <div class="booked-wzs-160-date">Воскресенье, 24</div> </div> </div> <div class="booked-wzs-center"> <span class="booked-wzs-bottom-l">Прогноз на неделю</span> </div> </a> </div> <!-- weather widget end --> Now add the inspector code.
element.style { background-color: #transparent; } .booked-wzs-160-110 { background-image: url('//s.bookcdn.com/images/we160x110.png') !important; background-repeat: no-repeat !important; border-radius: 10px !important; display: block !important; margin: 0 auto !important; padding: 0 !important; width: 160px !important; height: 110px !important; overflow: hidden !important; color: #fff !important; font: normal 11px/11px verdana, sans-serif !important; text-decoration: none !important; border: none !important; text-align: left !important; <div style=" position: absolute; right: 13px; top: -148px; z-index: 999;" id="m-booked-bl-simple-7511"> <a href="//nochi.com/weather/tbilisi-18901" class="booked-wzs-160-110" style="background-color:#transparent;"> <div class="booked-wzs-160-data wrz-18"> <div class="booked-wzs-160-right"> <div class="booked-wzs-day-deck"> <div class="booked-wzs-day-val"> <div class="booked-wzs-day-number"><span class="plus">+</span>21</div> <div class="booked-wzs-day-dergee"> <div class="booked-wzs-day-dergee-val">°</div> <div class="booked-wzs-day-dergee-name">C</div> </div> </div> <div class="booked-wzs-day"> <div class="booked-wzs-day-d"><span class="plus">+</span>22°</div> <div class="booked-wzs-day-n"><span class="plus">+</span>14°</div> </div> </div> <div class="booked-wzs-160-city">Тбилиси</div> <div class="booked-wzs-160-date">Понедельник, 25</div> </div> </div> <div class="booked-wzs-center"> <span class="booked-wzs-bottom-l">Прогноз на неделю</span> </div> </a> </div>
styleattribute, but to describe them in a css file, with the same!importantmodifier. Then they will take precedence over the styles added by the script, unless they are also used!important- VenZellCSSandhtml- Vasily Barbashev