Wednesday 15 January 2014

javascript - IFrame src video change issue -


Trying to load an ITube video in an iframe and when a button is clicked, it will replace the src of the video and

Then change the video in iframe I have tried some methods and SRC changes, but the initial video remains exactly the same.

All my javascript and jquery here

  & lt; Script & gt; $ (Document) .ready (function () {$ .xx ({url: '/seller/videooad?videocategory='+'@Model.VideoCategory', Type: 'Post', Content Type: 'Application / Jason', Async: False, Success: Work {var video2 = document.getElementById ('video2); video 2.src = data; alert (video2.src);}}); $ (function () {$ (' Text Alert ("Test"); $ (this) .attr ("src", $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ (This) .attr ("name"); Warning ($ (this) .attr ("src"));});});});   < P> And here's the iphome and where the button is full that changes the iframe video  
   Rame style = "float: left" width = "500" height = "315" id = "video2" & gt; & gt; / iframe & gt; @wrench (Video in model. Video list) {var url = Video value; & lt; input type = "button" class = "text" name = "@ video value" value = "@ video. Text" /> 

Why does not creation occur while changing source? And is there any way to change it? Thanks in advance

Do not want to replace the source of iframe?

    

No comments:

Post a Comment