Javascript Running on JSFiddle but not on a webpage

后端 未结 6 2050
灰色年华
灰色年华 2021-01-26 12:18

Ok so I have a code that would show different forms based on dropdown selection
Here\'s the fiddle to that..

Well its always giving me Test1 which means its not cha

6条回答
  •  隐瞒了意图╮
    2021-01-26 12:45

    The best thing to do when such problem comes works in jsfiddle and not on webpage is to see the source of the fiddle page.

    Your source of the fiddle appears as:

    
    
    
      
       - jsFiddle demo
    
      
      
    
      
    
      
      
      
        
    
      
      
      
      
    

    Paste the above code directly and it will work.

    After pasting the code directly then you can remove unncecessary lines like below from the fiddle:

    
    
    

提交回复
热议问题