mIRC Home    About    Download    Register    News    Help

Print Thread
Page 1 of 2 1 2
#172423 09/03/07 10:44 PM
Joined: Jul 2006
Posts: 6
K
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
K
Joined: Jul 2006
Posts: 6
Hi there. I've recently installed Windows Vista. My default browser is Firefox. However, when I open a link in mIRC, it opens in Internet Explorer. How can I change this? Thanks.

Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
Search the forums for Vista and you'll find the answer. In short, it's an issue with how mIRC checks for the default browser and how it's different in Vista. Until the next version of mIRC, you're basically stuck.


Invision Support
#Invision on irc.irchighway.net
Joined: Jul 2006
Posts: 6
K
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
K
Joined: Jul 2006
Posts: 6
I had searched before asking but it looks like I didn't do a good job. Sorry about that.

Thanks.

Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
No problem. I just didn't want to try and rewrite that thread, so suggested searching for it and gave a quick summary as well.


Invision Support
#Invision on irc.irchighway.net
Joined: Jul 2006
Posts: 6
K
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
K
Joined: Jul 2006
Posts: 6
I just wrote a little script to fix it temporarily until the next version comes out:

on ^*:HOTLINK:www.*:*:{
}
on ^*:HOTLINK:$(http $+ $chr(58) $+ *):*:{
}
on ^*:HOTLINK:$(ftp $+ $chr(58) $+ *):*:{
}

on *:HOTLINK:*:*:{
run "C:\Program Files\Mozilla Firefox\firefox.exe" $1
}

Joined: Mar 2007
Posts: 2
S
Bowl of petunias
Offline
Bowl of petunias
S
Joined: Mar 2007
Posts: 2
how do i add this script into mIRC ??

what's the best way since i'm a script novice.

Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
Alt-R > Alt-R > File > New

Copy/Paste it in there and hit OK.


Invision Support
#Invision on irc.irchighway.net
Joined: Oct 2003
Posts: 3,918
A
Hoopy frood
Offline
Hoopy frood
A
Joined: Oct 2003
Posts: 3,918
Originally Posted By: klanga2049
I just wrote a little script to fix it temporarily until the next version comes out:


Yours may work for you, but it anyone else using your script should know that the above code will break their other ON HOTLINK events, if they have any. You have to use the same check in both hotlink events to make sure it will only trigger for that hotlink, otherwise you'll be running firefox a lot more than you need to.

A slightly improved version is the following, which also allows for https/ftps links and removes any trailing commas, periods or exclamation points people tend to use when linking URLs (Jonny says: check out this site http://yahoo.com!). It works pretty much like mIRC's internal one:

Code:
 
on $^*:HOTLINK:/^\W*(((?:https?|ftps?):\/\/|www\.)\S+)\b/:*:return
on $*:HOTLINK:/^\W*(((?:https?|ftps?):\/\/|www\.)\S+)\b/:*:run firefox.exe -new-tab $regml(1)


edited: absolute path to program files is not needed in vista, thanks steven!

edited again: links now load in tabs if your browser is already open (we all love tabs don't we? if you don't, remove the '-new-tab' argument)

Last edited by argv0; 25/03/07 07:55 PM.

- argv[0] on EFnet #mIRC
- "Life is a pointer to an integer without a cast"
Joined: Mar 2007
Posts: 2
S
Bowl of petunias
Offline
Bowl of petunias
S
Joined: Mar 2007
Posts: 2
thanks the script works well smile

i have done one tweak and removed the absolute path to firefox.exe and just used run "firefox.exe" $regml(1) so it works on both x86 and x64 versions of Vista

Joined: Jul 2006
Posts: 11
R
Pikka bird
Offline
Pikka bird
R
Joined: Jul 2006
Posts: 11
An alternative way to "fix" this (quotes due to it not really being a bug in mIRC), is to grab this simple, small program called SetBrowser.

I was having the same problem (I had set Opera as my default browser, but it kept opening links in IE). After I set Opera as my default browser using SetBrowser, they also opened correctly from mIRC (I guess that even though Vista uses a new way to do it, the old way is still supported, and this SetBrowser app lets you set the default browser the old way).

Joined: May 2007
Posts: 3
_
Self-satisified door
Offline
Self-satisified door
_
Joined: May 2007
Posts: 3
LOOL! WOW!

Here's how you fix it. NO PROGRAMS! NO HACKS/ADDONS! Just a minute of your time.

1. Go to Control Panel and double click on Default Programs, it's the first icon on the second row.
2. Click on Set program access and computer defaults at the bottom.
3. Double click Custom.
4. For Choose a default web browser select Mozilla Firefox and do NOT uncheck the "Enable access to this program".
If you absolutely HATE Internet Explorer like I do then you can select "Enable access to this program" and it'll remove IE from usage.

That's it!

No programs, no add-ons, no scripts... all right there in the OS for ya.

Peace guys,

-bi0h4z4rd


This was written by: bi0h4z4rd
Shouts to: argv[0], Metality, Hrung and rickcp

Joined: Dec 2002
Posts: 2,033
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Dec 2002
Posts: 2,033
I think you're missing the point. When both IE and FF are
available and FF is set as default, IE is still used by mIRC
by default when it should launch the browser that is set
as default.

Joined: May 2007
Posts: 3
_
Self-satisified door
Offline
Self-satisified door
_
Joined: May 2007
Posts: 3
not when you do what I posted.

Joined: Mar 2007
Posts: 218
V
Fjord artisan
Offline
Fjord artisan
V
Joined: Mar 2007
Posts: 218
Originally Posted By: _bi0h4z4rd_
not when you do what I posted.

Yeah that does fix it, but RoCk is hitting the nail on the head, it was never an issue before, but it is now.

Joined: May 2007
Posts: 3
_
Self-satisified door
Offline
Self-satisified door
_
Joined: May 2007
Posts: 3
I don't know why you guys keep debating this issue. You change the program defaults like I said and you'll NEVER have the issue again.

There's a reason vista has features like this, USE it. No if ands and butts. I registered on this forum simply to tell you guys that you are ALL wrong and that the method I show you fixes it... FOREVER AND EVER!

Instead of debating the issue and trying to prove me wrong just say thank you. Pretty please?

Joined: Dec 2002
Posts: 2,033
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Dec 2002
Posts: 2,033
It's amazing that it's still obviously over your head. Go away.

Joined: Mar 2007
Posts: 218
V
Fjord artisan
Offline
Fjord artisan
V
Joined: Mar 2007
Posts: 218
Ok lets try to break this down for you.
First off, i had this problem when i started using vista, so i did a search on here and got a solution from this thread.
When you use Firefox for the first time it asks you if you'd like this to be your default browser, Yes? when you click yes and click a link that's in mIRC, IE still opens! That's the problem right there, None of this going to control panel and settings etc, That's not what this thread is about. Yes we know (as you explained) Is a kind of fix, But it's not what the issue is about mIRC is still using IE even when you've clicked 'yes' to Firefox being the default browser.
And if you post a reply saying 'i've told you the solution' again, i hope this thread gets locked, as you are clearly missing the point to it. nuff said

Joined: Nov 2003
Posts: 1
V
Mostly harmless
Offline
Mostly harmless
V
Joined: Nov 2003
Posts: 1
The default thing suggested actually does not work for me on this particular computer (i'll have to try it at home).

The script however does work perfectly for channel windows. It doesn't work for the URL catcher though. Is there anything we could add to that script to include the URL catcher?

Void4ever

Joined: Jun 2004
Posts: 26
S
Ameglian cow
Offline
Ameglian cow
S
Joined: Jun 2004
Posts: 26
Originally Posted By: void4ever
The default thing suggested actually does not work for me on this particular computer (i'll have to try it at home).

It didn't for me either. reko_t's link to SetBrowser did however (after I remembered to run it as admin :D, thanks btw). I noticed that both he and I are Opera users, perhaps it's related to that, but I'm not going to download Firefox just to test it :p.

Joined: Dec 2002
Posts: 2,033
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Dec 2002
Posts: 2,033
It has been discussed many times over, some with Khaled himself involved in the discussion and he is working on resolving the issue for the next release if he hasn't already resolved it.

Here is one...
https://forums.mirc.com/ubbthreads.php?ub...true#Post167792

Joined: Jun 2010
Posts: 7
S
Nutrimatic drinks dispenser
Offline
Nutrimatic drinks dispenser
S
Joined: Jun 2010
Posts: 7
Code:
on ^*:HOTLINK:www.*:*:{
}
on ^*:HOTLINK:$(http $+ $chr(58) $+ *):*:{
}
on ^*:HOTLINK:$(ftp $+ $chr(58) $+ *):*:{
}

on *:HOTLINK:*:*:{
run "C:\Program Files\Mozilla Firefox\firefox.exe" $1
}


Thanks for this! Starting to use my FireFox and mIRC in Portable-Mode and this becomes now very handy!

/cheers


PS: There should be a Feature in the Portable-Version, to select a Portable-Browser ;-)

Joined: Feb 2006
Posts: 546
J
Fjord artisan
Offline
Fjord artisan
J
Joined: Feb 2006
Posts: 546
wow, old topic :P in case anyone's interested, and since i already had something similar lying around, here's a version of that snippet that more accurately reflects mIRC's own detection of URLs:

Code:
on ^*:hotlink:*:*:{
  if ($mouse.key !& 1) || (!$regex(url, $1, $urlre)) halt
}

on *:hotlink:*:*:{
  run "C:\Program Files\Mozilla Firefox\firefox.exe" $regml(url, 1)
}

alias urlre {
  return /(*UTF8) (?:^|[\ \x09]) [\Q '<([{" \E]* \K (                          $&
    (?: (?: (?# irc|gopher|telnet| ) https?|ftps?):// 	| (?:www|ftp)\. )      $&
    [^\ \x09]+\.[^\ \x09]+? ) (?= [\Q ')]}>"., \E]* (?:[\ \x09]|$) ) /giSx
}


"The only excuse for making a useless script is that one admires it intensely" - Oscar Wilde
Joined: Sep 2005
Posts: 2,881
H
Hoopy frood
Offline
Hoopy frood
H
Joined: Sep 2005
Posts: 2,881
If firefox is the default browser you don't need to specify the path on windows vista/7, not sure whether you do on earlier versions.

It looks like the system takes into account the default browser as well as any directories specified by %PATH% when trying to run a file with no path specified now.

Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
True, but the request that resurrected this topic was for when FF is in portable mode (not default).


Invision Support
#Invision on irc.irchighway.net
Joined: Apr 2010
Posts: 969
F
Hoopy frood
Offline
Hoopy frood
F
Joined: Apr 2010
Posts: 969
Not to get off subject BUT, jaytea, what does the (?# ... ) in your regex do?


I am SReject
My Stuff
Joined: Feb 2006
Posts: 546
J
Fjord artisan
Offline
Fjord artisan
J
Joined: Feb 2006
Posts: 546
mentioned on IRC but i'll re-iterate here: (?# ... ) is a comment in regex. i used it to comment out certain protocols that, while supported as a part of URLs by mIRC, should not be opened by a browser.


"The only excuse for making a useless script is that one admires it intensely" - Oscar Wilde
Page 1 of 2 1 2

Link Copied to Clipboard