How to modify metadata on Control Pages

Posted on
Sat Mar 13, 2010 5:30 pm
dsloar offline
Posts: 13
Joined: Dec 07, 2009

How to modify metadata on Control Pages

Trying to get the Control Pages to display properly on my Palm Pre. How do I modify the metadata on the control pages? I can't find them in the WebServer folder. Thanks. :(

Posted on
Sat Mar 13, 2010 5:51 pm
jay (support) offline
Site Admin
User avatar
Posts: 18199
Joined: Mar 19, 2008
Location: Austin, Texas

Re: How to modify metadata on Control Pages

Metadata? What data are you talking about?

Jay (Indigo Support)
Twitter | Facebook | LinkedIn

Posted on
Sat Mar 13, 2010 6:04 pm
dsloar offline
Posts: 13
Joined: Dec 07, 2009

Re: How to modify metadata on Control Pages

The metadata in the HTML code that looks at whether an iphone is connecting. I was able to spoof an iphone user agent on an earlier version of webOS. That changed with the webOS 1.4 update. The buttons I created on the Control Pages are to small to use on my Pre. It works fine when viewing from an iphone. I would like to change the "Viewport" settings to hopefully make the Control Pages on usable my Pre.

Doug

Posted on
Sat Mar 13, 2010 6:56 pm
jay (support) offline
Site Admin
User avatar
Posts: 18199
Joined: Mar 19, 2008
Location: Austin, Texas

Re: How to modify metadata on Control Pages

Ah, User-Agent sniffing. In the basereqhandler.py file, located here:

Code: Select all
/Library/Application Support/Perceptive Automation/Indigo 4/IndigoWebServer/indigopy/


There is a method called _IsiPhone (line 292) - it snarfs out whether the User-Agent header contains "iPhone" or "iPod", and returns True if it does, False otherwise. We then set a global boolean template variable, $iphone, to that value and use it in various templates to show/hide/reformat things. You can probably just hack the IsiPhone method to also search for the appropriate User-Agent information for the Pre - apparently it does contain "Pre" so it should be rather simple. Let us know if it works and we'll add it in.

General note to everyone: if you write IWS plugins, you also have access to that variable (or if you're hacking the built-in templates) so feel free to use it.

Jay (Indigo Support)
Twitter | Facebook | LinkedIn

Posted on
Sat Mar 13, 2010 7:57 pm
dsloar offline
Posts: 13
Joined: Dec 07, 2009

Re: How to modify metadata on Control Pages

Thanks for the fast reply. I will post the results when I figure this out.

Doug

Page 1 of 1

Who is online

Users browsing this forum: No registered users and 3 guests