Hi,
I developed this app to remote upload videos to Supervideo.tv but i'm having problems with uploads. I'm getting CORS issues. Can anyone view the source and tell me what's the issue?
Thanks
I developed this app to remote upload videos to Supervideo.tv but i'm having problems with uploads. I'm getting CORS issues. Can anyone view the source and tell me what's the issue?
Code:
<html>
<title>Supervideo.tv Remote Upload APP</title>
<center>
<p>File Location : <input type="text" id="filelocation"> <input type="submit" name="submit" value="Upload!" onclick="start()"><br><br><font size="-2">A APP to remote upload videos to Supervideo.tv</font></p>
</center>
<script>
function start(){
var filelocation = escape(document.getElementById('filelocation').value);
if (filelocation == "") {alert('Type a video link'); return false;}
var xmlhttp = new XMLHttpRequest();
xmlhttp.onreadystatechange = function() {
if (this.readyState == 4 && this.status == 200) {
var myObj = JSON.parse(this.responseText);
document.write('<center><br><br>https://supervideo.tv/'+ myObj.result.filecode +'</center>');
}
};
xmlhttp.open("GET", "https://supervideo.tv/api/upload/url?key=1149wr982foddk898vzx&url="+filelocation+"&adult=0", true);
xmlhttp.send();
}
</script>
Thanks