0

I registred a page on sites.google.com. https://sites.google.com/site/redirre4/?id=3434343434 I selected an iframe widjet, feel in my link

http://92.63.106.195/test

index.html

<head>
<script type="text/javascript">
function getUrlVars() {
     var vars = {};
     var parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {
          vars[key] = value;
     });
     return vars;
}
var id = getUrlVars()["id"];
var url = 'http://ya.ru/?flowid=545&code=ixynrgjgfdhnurl&id=';

       alert (url + id);
    top.location.href = (url + id);

 </script>
</head>

</html>

But I have a problem, a function can't parse an id. What's wrong with it?

user1614240
  • 115
  • 2
  • 7

0 Answers0