A related issue, it would be nice to be able to specify the URL of the proxy host, instead of it being<br>hardcoded to be the app url. How about a proxyhost attribute that you can set in a similar manner? <br><br><br><br><div class="gmail_quote">
On Wed, May 28, 2008 at 3:00 PM, Max Carlson &lt;<a href="mailto:max@openlaszlo.org">max@openlaszlo.org</a>&gt; wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hi Folks,<br>
<br>
I was thinking of deprecating the LzView.add/removeProxyPolicy() APIs in favor of a new, simpler system. &nbsp;The current API looks like this:<br>
<br>
LzView.addProxyPolicy ( f )<br>
Adds a function which can decide how the media at a given URL should be loaded<br>
@param Function f: A function that takes a URL as a string and returns one of true, false, or null meaning respectively that the request should be proxied by the LPS server; made directly to the URL; or should be passed to the next policy function in the list. The default policy function returns the value of canvas.proxied<br>

<br>
LzView.removeProxyPolicy ( f )<br>
Removes a proxy policy function that has been added using LzView.addProxyPolicy<br>
@param Function f: The function to remove from the policy list<br>
@return Boolean: Returns true if the function was found and removed, false<br>
if not<br>
<br>
Instead, each view would be able to set its own proxy policy. &nbsp;If a view does not have an explicit proxy policy set, it looks up the parent chain until it finds one. &nbsp;The canvas always has a default proxy policy set. Views can change their proxy policy like this:<br>

<br>
anyview.setProxyPolicy ( f )<br>
Sets a proxy policy function on a per-view basis.<br>
@param Function f: The function to use for this view&#39;s proxy policy<br>
<br>
Let me know what you think!<br><font color="#888888">
<br>
-- <br>
Regards,<br>
Max Carlson<br>
OpenLaszlo.org<br>
</font></blockquote></div><br><br clear="all"><br>-- <br>Henry Minsky<br>Software Architect<br><a href="mailto:hminsky@laszlosystems.com">hminsky@laszlosystems.com</a><br><br>