Jump to content

Recommended Posts

Posted

Those of you who knew my old website probably remember that if you visited it using Internet Explorer, you'd be redirected to a page explaining why you shouldn't use Internet Explorer and that my site isn't tested with it, so if anything was broken you'd know why and if you still wanted to see my website, you should switch browsers. Some people even got scared, because at first I had a message on that page saying "you have been hijacked", or something like that :oops:

 

Well, since I installed Drupal, that "feature" has not been present. I decided it was time for me to correct that glitch and try my hand at writing a Drupal module.

 

The result is "Stop IE 0.5", a very simple module that uses Gary White's PHP browser detection class to check if you're using IE and if so, it redirects you to that nice page I mentioned above, just like my old site used to do.

 

For now, the page it redirects you to (/msie) is hard-coded into the stop_ie.module code but I'm planning to make a settings page for it where that page can be specified.

 

I decided to put the module available here for download, in case someone wants to put it in a Drupal site. It has only been tested with Drupal 4.6.x but it should also work with 4.5.x and 4.4.x, I think.

 

If you have any comments or suggestions, feel free to post them here as a comment!

Posted

Hi Raul,

the first time I visited, I saw a white page with

 

Fatal error: Call to undefined function: drupal_goto() in /home/cpanelname/public_html/modules/stop_ie/stop_ie.module on line 58

 

then I refreshed and it was ok.

 

Of course in firefox, no problems :oops:

Posted

Thanks, Don!

 

I was using a Drupal function that sometimes could work in unexpected ways. I switched to a safe one and everything should be fine, now :oops:

  • 1 month later...
Posted

I just uploaded version 1.0 of "Stop IE", which now features a settings page, where you can configure cookie lifetime (how long before the user is once again redirected) and the URL the users are redirected to.

Posted

That's odd... it's working just fine, here... :|

 

Which page do you see, the one about the Drupal module or the one saying my site doesn't work well with IE?

Posted

One that starts with this text:

Those of you who knew my old website probably remember that if you visited it using Internet Explorer...

Sorry Raul that I cant be more specific, but I don´t know what the other page says. :)

Posted (edited)

That's the page about the Drupal module.

You should have seen the other one, if visiting with IE... I guess I'll have to do some more testing.

Thanks, Thomas!

 

Edit: By the way, could you tell me which version of IE you were using? Are you using anything (plugins, activeX controls, IE bars, etc) that could be changing the user agent string (the way IE identifies itself to the website)? Thanks again! :)

Edited by borfast
Posted

That's really strange... I thought it was working OK :(

Well, back to debugging, then.

Thanks for the help, Thomas! :)

Posted

I just visited http://borfast.com/ with both IE6.x and FF1.07 - the same page came up - here's the first 20 or so lines of text from the page I viewed in both browsers:

 

borfast.com is my home on the web.

 

This is where I'll keep my projects, my blog, my photos of UFOs and alien life forms, the usual top secret US government experiments and, occasionally, some useful stuff.

 

This site is also a constant experiment, since I use it to increase my knowledge about web programming - meaning that if sometimes you see broken links and stuff that doesn't work, it's probably because I'm playing around :)

 

Enjoy your stay.

Tue, 27/12/2005 - 18:03

Mr. Jones

Submitted by borfast on Tue, 27/12/2005 - 18:03.

Posted in | read more | 49 reads »

 

Mr. Jones will be a role-playing game which intends to recreate the spirit and feel of Sierra's classic "Jones In The Fast Lane", with some possible new features, such as a multiplayer mode and a cartoon-like style.

 

John

Posted

Thanks, John.

 

There's definitely something wrong, there. I'll be checking it out and I'll post here again when I fixed it.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...