[pmwiki-users] Skin for Mobile Browsers

marc gmane at auxbuss.com
Thu Oct 12 12:24:58 CDT 2006


Ben Stallings said...
> Ian Barton wrote,
> > Has anyone got a skin suitable for a mobile browser? I want to be able 
> > to read one of my sites on a mobile phone. Main requirements are:
> > 
> > Minimal top bar.
> > No side bar.
> > Decent text formatting when the browser window is very narrow (about 240 
> > pixels).
> 
> I've got an extremely minimal skin on my http://benstallings.name/ wiki. 
>   The colorful border is just a style on the <body> tag; below is the 
> template in its entirety.  The extra links in the pagegroup div are 
> necessary :
> 
> <!DOCTYPE html
>      PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
>      "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
> <html>
> <head>
>    <title>$WikiTitle | {$Group} / {$Title} $Action</title>
>    <meta http-equiv='Content-Style-Type' content='text/css' />
>    <link rel='stylesheet' href='$SkinDirUrl/benstallings.css' 
> type='text/css' />
>    <!--HeaderText-->
> </head>
> <body>
>   <div id='wikititle'>
>    <div class='pagegroup'>
> 	 <a href='{$ScriptUrl}/{$Group}'>{$Group}</a> /
> 	</div>
>    <h1 class='pagetitle'>{$Title}</h1>
>   </div>
>   <!--PageText-->
> </body>
> </html>

Nice one, Ben. It only needed a few tweaks to satisfy the accessibility 
rules. <html lang="en"> or similar is important these days.

I added the skin as "benstinything". Forever you will be remembered ;-)

> Of course I have to enter ?action=edit and so on from the address line, 
> but I'm guessing you probably don't want to edit pages from your mobile 
> phone anyway.

Could put a few links at the bottom with an access key to get there. 
Ditto nav links at top. if necessary. Testing with lynx is handy too.
 
> You might consider putting a line in config.php to assign different 
> skins based on browsers -- when it sees your phone's browser, it uses 
> the minimalist skin, otherwise it uses something more capable.

Or use CSS.

> Can I just say that I love how easy PmWiki is to skin?

+1

> Try doing a template like this in Joomla without pulling your hair out.

Been there, done that, and that's one reason why I here.

-- 
Best,
Marc





More information about the pmwiki-users mailing list