How To Not Apply The Mobile Skin To Blogs, Gallery, Etc. ?

Hi there,

I successfully installed your Aqua-Soft mobile skin. Now, an iPhone user can see my board with this skin, owing to the User Agent Mapping declaration.

However, i also run on my IPB installation the IP Blogs and IP Gallery apps.

The problem is that the mobile skin is also used with these apps, and because it is not built for them, it appears completely messy with an iPhone.

So, how to remove the mobile skin for blogs and gallery ?

I tried to add an URL Mapping for the mobile skin, in order to restrict the skin to the board only, but it doesn't work.

Do you have any idea ?

Thanks a lot!

#533350

You can try adding the following after the blog/gallery links

?unlockUserAgent=0

#533352

You can try adding the following after the blog/gallery links

?unlockUserAgent=0

This solution is not possible, because there are links everywhere in my board / website to the blogs and gallerys.

Would it be possible to modify the publicOutput.php file?

For example, checking the current app and setting the unlockUserAgent to zero when needed.

The problem is, I don't know how to do this <_<

Any idea ?

Thanks !

#533459

In the publicOutput.php file, I replaced your code with this one :

		if (IPS_AREA != "admin")
{
if (IPS_APP_COMPONENT == "gallery" || IPS_APP_COMPONENT == "blog" || IPS_APP_COMPONENT == "links")
{
$this->member->updateMySession( array( 'uagent_bypass' => 1 ) );

/* Set cookie */
IPSCookie::set("uagent_bypass", 1, -1);
}
else if (IPS_APP_COMPONENT == "forums")
{
$this->member->updateMySession( array( 'uagent_bypass' => 0 ) );

/* Set cookie */
IPSCookie::set("uagent_bypass", 0, -1);
}
else
{
if ( isset( $this->request['unlockUserAgent'] ) AND $this->request['unlockUserAgent'])
{
$this->member->updateMySession( array( 'uagent_bypass' => 1 ) );

// Set cookie
IPSCookie::set("uagent_bypass", 1, -1);
}
else if ( isset( $this->request['unlockUserAgent'] ) )
{
$this->member->updateMySession( array( 'uagent_bypass' => 0 ) );

/* Set cookie */
IPSCookie::set("uagent_bypass", 0, -1);
}
}
}

It works well (i.e. blogs and gallery don't appear with the mobile skin), but alas, it disables the possibility for mobile users to switch back to the classic version of the board.

If you have a better idea, don't hesitate to tell me :)

#533464