I need to know the url at which the user is currently (with firefox)
I was thinking of a keylogger to track the url,
but what when the user clicks the link?
The name is not enough, I need the full URL. This is easy with IE, but not with firefox. for IE I use:
private string GetUrlFromIE() { IntPtr windowHandle = GetForegroundWindow(); IntPtr childHandle; String strUrlToReturn = ""; //IE toolbar container childHandle = FindWindowEx(windowHandle,IntPtr.Zero,"WorkerW",IntPtr.Zero); if(childHandle != IntPtr.Zero) { //get a handle to address bar childHandle = FindWindowEx(childHandle,IntPtr.Zero,"ReBarWindow32",IntPtr.Zero); if(childHandle != IntPtr.Zero) { // get a handle to combo boxes childHandle = FindWindowEx(childHandle, IntPtr.Zero, "ComboBoxEx32", IntPtr.Zero); if(childHandle != IntPtr.Zero) { // get a handle to combo box childHandle = FindWindowEx(childHandle, IntPtr.Zero, "ComboBox", IntPtr.Zero); if(childHandle != IntPtr.Zero) { //get handle to edit childHandle = FindWindowEx(childHandle, IntPtr.Zero, "Edit", IntPtr.Zero); if (childHandle != IntPtr.Zero) { strUrlToReturn = GetText(childHandle); } } } } } return strUrlToReturn; }
any ideas?
source share