Support forums : Quickies

hit terminology question

A home for really quick one-liner thoughts about what we need to fix or do or whatever. If they spark discussion we move it, otherwise this is like post-it notes.

Moderator: Dracones

hit terminology question

Postby EdB » Fri Aug 17, 2012 5:24 pm

Related to the idea of putting mobile detection in place, I'm bumping into all sorts of terminology issues.
Code: Select all
$referer_type =  'search'|'blacklist'|'referer'|'direct'|'spam' |'admin' // this one gets used and logged

Maybe that is no problem but where does 'mobile' or 'tablet' fall in? Since mobile/tablet could be a search it obviously doesn't belong here.
Code: Select all
$agent_platform = ''|'win'|'mac' // does not get stored, gets used for admin page body tag id

"Platform" is more than just OS though right? Like, hardware+software = platform. In mobile detection class they group operating systems into a variable called $operatingSystems.
Code: Select all
$agent_type = 'rss'|'robot'|'browser'|'unknown'

mobile detection class doesn't have a parallel, but we could be a browser or an rss from mobile.
Code: Select all
$agent_name = ''|'lynx'|'firefox'|'gecko'|'msie'|'safari'|'opera'|'nav4'

In mobile detection they call the same type of thing "$userAgents".

I dunno how to reconcile this, but clearly if we go down the mobile detection path we need to make sure our variables are making sense. mobile detection gives us something we don't have a place to put which would be "device type" or something like that. mobile, tablet, desktop. They assume if it isn't a mobile or a tablet then it must be a desktop.
Code: Select all
$referer_device = 'mobile', 'tablet', 'desktop'
maybe?
Code: Select all
$referer_type =  'search'|'blacklist'|'referer'|'direct'|'spam' |'admin'
seems okay as-is?

Code: Select all
$agent_platform = ''|'win'|'mac'|'AndroidOS'|'BlackBerryOS'|'PalmOS'|'SymbianOS'|'WindowsMobileOS'|'iOS'|'badaOS'
covers both systems and if we store $referer_device we'll be able to make more sense of it later.

Code: Select all
$agent_name = ''|'lynx'|'firefox'|'gecko'|'msie'|'safari'|'opera'|'nav4'|'Chrome'|'Dolfin'|'Opera'|'Skyfire'|'IE'|'Firefox'|'Bolt'|'TeaShark'|'Blazer'|'Safari'|'Midori'|'GenericBrowser'
covers both systems and if we store $referer_device we'll be able to make more sense of it later.

We could and maybe should rename these variables as well. agent_platform could be agent_opsys and agent_name could be agent_browser?

That leaves us with one other thing that mobile detection provides that we have no equivalent of on the desktop assumption: the device maker.
Code: Select all
$phoneDevices = 'iPhone'|'BlackBerry'|'HTC'|'Nexus'|'Dell'|'Motorola'|'Samsung'|'Sony'|'Asus'|'Palm'|'Vertu'|'GenericPhone'
$tabletDevices = 'BlackBerryTablet'|'iPad'|'Kindle'|'SamsungTablet'|'HTCtablet'|'MotorolaTablet'|'AsusTablet'|'NookTablet'|'AcerTablet'|'YarvikTablet'|'GenericTablet'


I dunno. It gets complicated the more I think of it so I'm probably overthinking it. Still, it seems to me our terminology should make human-friendly sense so a template author can have an easier time doing stuff, and we should store it so our stats might one day be way better than they are.
EdB
Dracone
User avatar
 
Posts: 2072
Joined: Sun Nov 22, 2009 7:20 am
Location: Maricopa Arizona

Re: hit terminology question

Postby Kimberly » Fri Aug 17, 2012 5:53 pm

EdB wrote:
, and we should store it so our stats might one day be way better than they are.


This is a definite. If we see 70% of users coming from mobile and tablet devices, then we know that we need to be concern with our sites on those devices. On the other hand, if we see only 10% of our users coming from those devices, we might just decide to ignore any attempts at making the site more user friendly on those devices as it may not be worth the effort/cost.
Kimberly
Dracone
User avatar
 
Posts: 842
Joined: Mon Jul 19, 2010 4:44 pm


Return to Quickies

Who is online

Users browsing this forum: No registered users and 1 guest

cron