UK WEB HOSTING FORUM FOR DISCUSSION ON WEB HOSTING SERVICE AND SUPPORT
LINUX HOSTING WINDOWS HOSTING PACKAGES SHOPPING CART OSCOMMERCE ZEN CART AGORA
ECOMMERCE HOSTING ASP MSSQL FRONTPAGE HOSTING PHP MYSQL HOSTING DISCUSSION FORUM
CPANEL RESELLER HOSTING DEDICATED SERVER VPS HOSTING PLESK VIRTUOZZO
Quick Search
Your forum announcement here!

  UK Web Hosting | Dedicated Server Windows and Linux VPS Forum > Web Hosting and Domains > PHP Hosting

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 19-07-2007, 21:58
new member
 
Join Date: Jul 2007
Posts: 7
Unhappy Using browscap

Hi, I've just set up a new account (Linux shared hosting account)... I'm currently transferring my old website (that I know works... at least, on my old host). However, I can't get my php system to find my browscap.ini...

For example, in my pages I get an error

Code:
Warning: get_browser() [function.get-browser]: 
browscap ini directive not set. in 
/home/mattx/includes/webcounter.inc on line 105
I have tried to set the location in .htaccess, using

Code:
php_value browscap "/home/mattx/includes/browscap.ini"
(Hmm... bad idea to post full paths?)

Anyway, other directives in .htaccess work properly, so I'm not sure there's a problem with visibility...

Does anyone have any obvious suggestions as to what I might be doing wrong?... Or, how to fix this?

Thanks.

>> Edit:

I notice this is also broken on the EUKHost's page http://webtools.eukhost.com/browser_details.php

Last edited by mattx : 19-07-2007 at 22:17.
Reply With Quote
  #2 (permalink)  
Old 19-07-2007, 23:31
eUKhost.com's Avatar
Chief Marketing Officer
 
Join Date: Sep 2005
Posts: 4,261
Send a message via AIM to eUKhost.com Send a message via MSN to eUKhost.com
Default

Hello Matt,

Solution for this problem is available at http://blog.eukhost.com/2007/05/14/g...owser-details/

One of our system administrator has fixed this error on http://webtools.eukhost.com/browser_details.php

I am not sure how google got this URL indexed as we've not yet linked webtools section anywhere on our website and work is incomplete right now.
__________________
UK Web Hosting || Business Hosting || eUKhost Knowledgebase
Toll Free : 0808 262 0255 || MSN : mark @ eukhost.com || AIM : eukmark
A bunch of Sheep led by a Lion is better than a bunch of Lions led by a Sheep.
__________________________________________________

Great Opportunity :: Join our Affiliate Program for FREE and earn 20% commission on each referral.
Reply With Quote
  #3 (permalink)  
Old 19-07-2007, 23:33
new member
 
Join Date: Jul 2007
Posts: 7
Default

Ah, I see the issue (after reading php.net): I can't set browscap in .htaccess, by law, I had to set it using a custom php.ini on my old website (host)...

Sorry for that confusion

Now, that begs the question, is it possible to use get_browser() at all on my account??... I guess I'll contact support...

Last edited by mattx : 19-07-2007 at 23:41.
Reply With Quote
  #4 (permalink)  
Old 19-07-2007, 23:36
new member
 
Join Date: Jul 2007
Posts: 7
Default

You must have typed that while I was typing mine...

Do I actually have an editable php.ini, seeing as tho I'm on a shared host thing... I can't find one anywhere, can I create my own? On my old host I could create one and put it into /home/mattx/etc (or, the equivalent of)...

Sorry about digging up that page....

Last edited by mattx : 19-07-2007 at 23:42.
Reply With Quote
  #5 (permalink)  
Old 20-07-2007, 04:00
AndyD's Avatar
Member
 
Join Date: Apr 2007
Posts: 52
Default

Hello,

Quote:
mattx :: Do I actually have an editable php.ini, seeing as tho I'm on a shared host thing... I can't find one anywhere, can I create my own? On my old host I could create one and put it into /home/mattx/etc (or, the equivalent of)...
You being having a shared account and thus being a normal user on the server, do not have access to the global php.ini file on the server. But you can go ahead and create a custom php.ini under the public_html folder of your account and put in a line as:
browscap = /home/mattx/includes/browscap.ini
there to enable the browscap feature for your website coz this would override the browscap value set in global php.ini for your user.
Hope this works out for you. Good Luck!!!
__________________
@= EukHost =@
Linux / Windows Dedicated Servers || Linux VPS Hosting || Windows VPS Hosting

"The secret of greatness is simple: do better work than any other man in your field - and keep on doing it"
Reply With Quote
  #6 (permalink)  
Old 20-07-2007, 12:56
new member
 
Join Date: Jul 2007
Posts: 7
Default

Have you got experience of this working, for you? Because I just tried it and nothing happened....
Reply With Quote
  #7 (permalink)  
Old 20-07-2007, 13:42
DPS Computing's Avatar
Premium Member
 
Join Date: Apr 2007
Location: Manchester, United Kingdom
Posts: 4,473
Send a message via ICQ to DPS Computing Send a message via AIM to DPS Computing Send a message via MSN to DPS Computing Send a message via Yahoo to DPS Computing Send a message via Skype™ to DPS Computing
Default

Maybe support might be able to implement it on your behalf?
__________________
David Smith
DPS Computing
http://www.dpscomputing.com (Computing, Reviews, News) - New site / new polls / new stories! With many more to follow!
NEW LAUNCH! http://djdavid.dpscomputing.com (My DJ Website)
NEW LAUNCH! http://davidsmith.dpscomputing.com (My Personal Website)
Reply With Quote
  #8 (permalink)  
Old 20-07-2007, 13:47
new member
 
Join Date: Jul 2007
Posts: 7
Default

Yeah, they've done that now...
Reply With Quote
  #9 (permalink)  
Old 20-07-2007, 13:48
DPS Computing's Avatar
Premium Member
 
Join Date: Apr 2007
Location: Manchester, United Kingdom
Posts: 4,473
Send a message via ICQ to DPS Computing Send a message via AIM to DPS Computing Send a message via MSN to DPS Computing Send a message via Yahoo to DPS Computing Send a message via Skype™ to DPS Computing
Default

Glad to see you got it sorted then .
__________________
David Smith
DPS Computing
http://www.dpscomputing.com (Computing, Reviews, News) - New site / new polls / new stories! With many more to follow!
NEW LAUNCH! http://djdavid.dpscomputing.com (My DJ Website)
NEW LAUNCH! http://davidsmith.dpscomputing.com (My Personal Website)
Reply With Quote
  #10 (permalink)  
Old 01-08-2007, 04:18
AndyD's Avatar
Member
 
Join Date: Apr 2007
Posts: 52
Default

Bravo Support Again!!! But can anybody let others on this Forum know how they went doing this for Matt? So that anybody else facing the same would be able to do it by himself (if it's within his limit at all)
__________________
@= EukHost =@
Linux / Windows Dedicated Servers || Linux VPS Hosting || Windows VPS Hosting

"The secret of greatness is simple: do better work than any other man in your field - and keep on doing it"
Reply With Quote
  #11 (permalink)  
Old 01-08-2007, 11:00
new member
 
Join Date: Jul 2007
Posts: 7
Default

You just speak to support and say "My browscap setting doesn't work", and then they update it on your server...

Although I'm not sure how recent the browscap.ini actually is, since it doesn't recognise a lot of the current msn and yahoo robots.

I think I'll just have to use one of the custom get_browser() scripts on php.net ;/
Reply With Quote
  #12 (permalink)  
Old 02-08-2007, 01:38
AndyD's Avatar
Member
 
Join Date: Apr 2007
Posts: 52
Default

Well Matt, I'm not a PHP guru so couldn't really get what you are planning to do with your browscap utility
Well, I think you should refer http://browsers.garykeith.com/downloads.asp for more help on latest browscap.ini updates
__________________
@= EukHost =@
Linux / Windows Dedicated Servers || Linux VPS Hosting || Windows VPS Hosting

"The secret of greatness is simple: do better work than any other man in your field - and keep on doing it"
Reply With Quote
  #13 (permalink)  
Old 02-08-2007, 10:35
new member
 
Join Date: Jul 2007
Posts: 7
Default

Well they set the browscap setting to 'extra/browscap.ini', which isn't in my own path, so I can't modify (and update) the file.

The browscap.ini is just a normal .ini file so you can in principle use php functions to parse one yourself (php.net has some sample scripts for this).

At the moment I'm using it to detect robots in some visitor-counters, and to hide some parts of my website from them.
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


All times are GMT. The time now is 16:19.

 

Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
LinkBacks Enabled by Web Hosting 3.1.0
Copyright © 2001-2008, eUKhost.com. All rights reserved.

 
Site Map

knowledgebase articles

popular blog categories