Add iPhone reporting to AWStats
Seeing as we run an iPhone centric website at return7.com, I thought it would be useful for awstats to report on the percentage of iPhone/iPod touch users browsing our site. In order to do this, you need to make a few changes to your browsers.pm file (on ubuntu it’s at /usr/share/awstats/lib/browsers.pm).
First, in @BrowsersSearchIDOrder add the following lines before ’safari’:
'ipod',
'iphone',
Next, add these lines in %BrowsersHashIDLib:
'ipod','iPod',
'iphone','iPhone',
Finally, add these lines in %BrowsersHashIcon:
'ipod','safari',
'iphone','safari',
This will add both an iPod and an iPhone to your browser listings. If you only want one new entry for both iPods and iPhones, then only use the latter of the two lines and all matches will be listed under iPhone. Enjoy.
No Comments »
RSS feed for comments on this post. TrackBack URL