LinkedIn follow company button showing blank page

前端 未结 2 1738
眼角桃花
眼角桃花 2021-01-18 04:11

I copied the code from this link by giving company name and clicking the Get Code button. It generated the code given below



        
2条回答
  •  夕颜
    夕颜 (楼主)
    2021-01-18 04:17

    Well it appears that you are just invoking the JavaScript. You must place the JavaScript into an HTML Document and then have an element that corresponds with that script.

    Remember you also have to have a full structured HTML Document before you can just place Script tags into it, you need html, body, head, tags, etc.

    Try creating an HTML Document and placing this within the .html file.

    
    
    
    
    Untitled Document
    
    
    
    
    
    
    
    
    
    

    Tips to remember:

    • A lot of scripts require an element to correspond with.
    • You may either place the script within the script tags in the body tags or the head tags, depending on if you may or may not be selecting an element on the page.
    • Each HTML document requires the correct mark-up before a browser can render it.

    Hope this helps!

    EDIT: Just upload it to a server, once you do that, it will work. I cannot explain why though.

提交回复
热议问题