Advertisement
Guest User

Untitled

a guest
Mar 30th, 2017
51
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.58 KB | None | 0 0
  1. $.getJSON("../api/routes/", function(result) {
  2. var options = $("#options");
  3. //don't forget error handling!
  4. $.each(result, function(item) {
  5. options2.append($("<option />").val(this.name).text(this.name));
  6.  
  7.  
  8.  
  9. });
  10. });
  11.  
  12. $.getJSON("../api/routes/", function (result) {
  13. $("#options").on("change", function () {
  14. var heatFrameView = $("#heatFrame");
  15. heatFrameView.append($('<iframe src="'+this.game.heat_link+'">''</iframe>'));
  16. });
  17. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement