Can you use Css for Mobile Apps.

Patel Web Design (PWD)


<style type=”text/css”>
.ie .example {background-color: yellow}
.ie7 .example {background-color: orange}
.gecko .example {background-color: gray}
.win.gecko .example {background-color: red}
.linux.gecko .example {background-color: pink}
.opera .example {background-color: green}
.konqueror .example {background-color: blue}
.webkit .example {background-color: black}
.example {width: 100px;height: 100px;}
.no_js { display: block }
.has_js { display: none }
.js .no_js { display: none }
.js .has_js { display: block }

function css_browser_selector(u){var ua=u.toLowerCase(),is=function(t){return ua.indexOf(t)>-1},g=’gecko’,w=’webkit’,s=’safari’,o=’opera’,m=’mobile’,h=document.documentElement,b=[(!(/opera|webtv/i.test(ua))&&/msie\s(\d)/.test(ua))?(‘ie ie’+RegExp.$1):is(‘firefox/2′)?g+’ ff2′:is(‘firefox/3.5′)?g+’ ff3 ff3_5′:is(‘firefox/3.6′)?g+’ ff3 ff3_6′:is(‘firefox/3′)?g+’ ff3′:is(‘gecko/’)?g:is(‘opera’)?o+(/version\/(\d+)/.test(ua)?’ ‘+o+RegExp.$1:(/opera(\s|\/)(\d+)/.test(ua)?’ ‘+o+RegExp.$2:”)):is(‘konqueror’)?’konqueror’:is(‘blackberry’)?m+’ blackberry’:is(‘android’)?m+’ android’:is(‘chrome’)?w+’ chrome’:is(‘iron’)?w+’ iron’:is(‘applewebkit/’)?w+’ ‘+s+(/version\/(\d+)/.test(ua)?’ ‘+s+RegExp.$1:”):is(‘mozilla/’)?g:”,is(‘j2me’)?m+’ j2me’:is(‘iphone’)?m+’ iphone’:is(‘ipod’)?m+’ ipod’:is(‘ipad’)?m+’ ipad’:is(‘mac’)?’mac’:is(‘darwin’)?’mac’:is(‘webtv’)?’webtv’:is(‘win’)?’win’+(is(‘windows nt 6.0′)?’ vista’:”):is(‘freebsd’)?’freebsd’:(is(‘x11’)||is(‘linux’))?’linux’:”,’js’]; c = b.join(‘ ‘); h.className += ‘ ‘+c; return c;}; css_browser_selector(navigator.userAgent);





View original post


About oluakinola

Enthusiastic, fun to be with has great passion for cooking and the scientific approach to cookery, I also love Electronics and Gadgets generally. And I love my lord Jesus Christ and the gospel.
This entry was posted in Uncategorized. Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s