Here's a regular expression you can use in JavaScript or php:
(?:file%5B0%5D%5BremoteFileURL%5D|remoteFileURL)=(.+?)&
Since your example URL has a very strange form of naming the parameters, I included both that form and the usual way. It matches for file[0][remoteFile]
as well as remoteFile
and captures the value of that parameter.
In JavaScript you can do it like this, if there's a field containing the URL with the id URL
.
var url = document.getElementById('URL').value;
var myRegexp = /(?:file%5B0%5D%5BremoteFileURL%5D|remoteFileURL)=(.+?)\&/;
var match = myRegexp.exec(url);
alert(match[1]);