javascript - JS using ele.style.backgoundImage = '' ='none' to cancel the background image is invalid
高洛峰
高洛峰 2017-07-05 10:44:32
0
6
1164

Using ele.style.backgoundImage = '' ='none' in JS to cancel the background image is invalid. What method should be used to cancel the background image in JS?

高洛峰
高洛峰

拥有18年软件开发和IT教学经验。曾任多家上市公司技术总监、架构师、项目经理、高级软件工程师等职务。 网络人气名人讲师,...

reply all (6)
三叔

Changed to
bgNode.style.backgroundImage = "none";

    迷茫

    style.backgroundImage = 'none';

      世界只因有你

      ele.style.backgroundImage='none'; After the page is loaded, execute $(function(){)};

        typecho

        ele.style.backgoundImage = 'none' is fine, no need to add an extra equal sign

          漂亮男人

          First make sure to decide whether to leave or not.

            typecho

            $(ele).css('background-image','none');

              Latest Downloads
              More>
              Web Effects
              Website Source Code
              Website Materials
              Front End Template
              About us Disclaimer Sitemap
              php.cn:Public welfare online PHP training,Help PHP learners grow quickly!