Results 1 to 6 of 6

Thread: Internet Explorer

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Oct 2000
    Location
    Chesterfield, UK
    Posts
    298

    Internet Explorer

    In Internet Explorer when someone types in a URL and clicks go or presses enter is there any way that I can intercept that action and differ internet explorer to another site of my choice.

    The reason for this is one of our clients wants to have restrictions placed on internet explorer so they can't go to site other than the ones that are specified, without using the content advisor.

    Or alternitively is there another program that you can think that would do the job.

    Regards,


    Matt.

  2. #2
    Frenzied Member dynamic_sysop's Avatar
    Join Date
    Jun 2003
    Location
    Ashby, Leicestershire.
    Posts
    1,142
    you could add a combo box to your form ( which holds specific urls ) then you can launch internet explorer without a toolbar like this... ( depending whether you add a reference to internet controls, so i've done an example with and 1 without ) ...
    VB Code:
    1. [COLOR=BLUE]Private[/COLOR] [COLOR=BLUE]Sub[/COLOR] Button1_Click([COLOR=BLUE]ByVal[/COLOR] sender [COLOR=BLUE]As[/COLOR] System.Object, [COLOR=BLUE]ByVal[/COLOR] e [COLOR=BLUE]As[/COLOR] System.EventArgs) [COLOR=BLUE]Handles[/COLOR] Button1.Click
    2.         [COLOR=BLUE]Dim[/COLOR] objBrowser [COLOR=BLUE]As[/COLOR] [COLOR=BLUE]Object[/COLOR] = CreateObject("InternetExplorer.Application")
    3.         [COLOR=BLUE]Dim[/COLOR] IE [COLOR=BLUE]As[/COLOR] SHDocVw.InternetExplorer = [COLOR=BLUE]DirectCast[/COLOR](objBrowser, SHDocVw.InternetExplorer)
    4.         [COLOR=GREEN]'/// reference to Microsoft Internet Controls required this way.
    5. [/COLOR]        [COLOR=BLUE]With[/COLOR] IE
    6.             .ToolBar = [COLOR=BLUE]False[/COLOR] [COLOR=GREEN]'/// no toolbar, so the user cant specify urls.
    7. [/COLOR]            .Height = 500
    8.             .Width = 500
    9.             .Visible = [COLOR=BLUE]True
    10. [/COLOR]            .Navigate(ComboBox1.Text)
    11.         [COLOR=BLUE]End[/COLOR] [COLOR=BLUE]With
    12.  
    13. [/COLOR]    [COLOR=BLUE]End[/COLOR] [COLOR=BLUE]Sub
    14.  
    15. [/COLOR]    [COLOR=BLUE]Private[/COLOR] [COLOR=BLUE]Sub[/COLOR] Button2_Click([COLOR=BLUE]ByVal[/COLOR] sender [COLOR=BLUE]As[/COLOR] System.Object, [COLOR=BLUE]ByVal[/COLOR] e [COLOR=BLUE]As[/COLOR] System.EventArgs) [COLOR=BLUE]Handles[/COLOR] Button2.Click
    16.         [COLOR=BLUE]Dim[/COLOR] objBrowser [COLOR=BLUE]As[/COLOR] [COLOR=BLUE]Object[/COLOR] = CreateObject("InternetExplorer.Application")
    17.         [COLOR=GREEN]'/// without a reference to Microsoft Internet Controls, may cause a problem with Option Strict On.
    18. [/COLOR]        [COLOR=BLUE]With[/COLOR] objBrowser
    19.             .ToolBar = [COLOR=BLUE]False[/COLOR] [COLOR=GREEN]'/// no toolbar, so the user cant specify urls.
    20. [/COLOR]            .Height = 500
    21.             .Width = 500
    22.             .Visible = [COLOR=BLUE]True
    23. [/COLOR]            .Navigate(ComboBox1.Text)
    24.         [COLOR=BLUE]End[/COLOR] [COLOR=BLUE]With
    25.  
    26. [/COLOR]    [COLOR=BLUE]End[/COLOR] [COLOR=BLUE]Sub[/COLOR]
    ~
    if a post is resolved, please mark it as [Resolved]
    protected string get_Signature(){return Censored;}
    [vbcode][php] please use code tags when posting any code [/php][/vbcode]

  3. #3
    Frenzied Member
    Join Date
    Oct 2002
    Location
    Gammapolis
    Posts
    1,474

    Re: Internet Explorer

    Originally posted by MattJH
    The reason for this is one of our clients wants to have restrictions placed on internet explorer so they can't go to site other than the ones that are specified, without using the content advisor.
    Why? Why? If i was there i would find lots of work arounds to bypass the restriction. Don't waste your time man.
    'Heading for the automatic overload'
    Marillion, Brave, The Great Escape, 1994

    'How will WE stand the FIRE TOMORROW?'
    Eloy, Silent Cries and Mighty Echoes, The Vision - Burning, 1979

  4. #4
    KrisSiegel.com Kasracer's Avatar
    Join Date
    Jul 2003
    Location
    USA, Maryland
    Posts
    4,985
    Just use the host file.

    All you do is write to it what sites you don't want the person to go to and where you want that url/ip to take the person too

  5. #5

    Thread Starter
    Hyperactive Member
    Join Date
    Oct 2000
    Location
    Chesterfield, UK
    Posts
    298

    Thanks

    Thanks for your help.

    I have used the PICS Rules, from within the content tab in internet options.

    Regards,


    Matt.

  6. #6
    KrisSiegel.com Kasracer's Avatar
    Join Date
    Jul 2003
    Location
    USA, Maryland
    Posts
    4,985

    Re: Thanks

    Originally posted by MattJH
    Thanks for your help.

    I have used the PICS Rules, from within the content tab in internet options.

    Regards,


    Matt.
    You could of used the hosts file though.

    It's in the system32 folder I think...

    You can just write to it what sites you want to go where and boom they can't get to it through ANY browser. Your way will probably allow them to get through if they just download netscape, opera, firdbird, ect...

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width