<html><body><div style="color:#000; background-color:#fff; font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:12pt"><div class="" style=""><span class="" style="">Hi Michael, </span></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal; background-color: transparent;" class=""><span class="" style=""><br class="" style=""></span></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal; background-color: transparent;" class=""><span class="" style="">I think what you have done with the html page is crying for the CORS and an angularjs, single page app.</span></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida
 Grande', sans-serif; font-style: normal; background-color: transparent;" class=""><span class="" style="">Here is an open source project with such app that could "easily" be modified to do the work. </span></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal; background-color: transparent;" class="">Check out a working sample here:</div><div style="background-color: transparent;" class=""><span class="" style=""><a href="http://angular-client-side-auth.herokuapp.com/login/" class="" style="">http://angular-client-side-auth.herokuapp.com/login/</a><br class="" style=""></span></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal; background-color: transparent;" class=""><br></div><div style="color: rgb(0, 0, 0); font-size:
 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal; background-color: transparent;" class="">Nikolay</div><div>  </div> <div class="qtdSeparateBR"><br><br></div><div class="yahoo_quoted" style="display: block;"> <div style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 12pt;" class=""> <div style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 12pt;" class=""> <div dir="ltr" class="" style=""> <font size="2" face="Arial" class="" style=""> On Saturday, June 7, 2014 12:42 AM, Nikolay Shishkov <nshishkov@yahoo.com> wrote:<br class="" style=""> </font> </div>  <br class="" style=""><br class="" style=""> <div class="" style=""><div id="yiv1671584635" class="" style=""><div class="" style=""><div style="color:#000;background-color:#fff;font-family:HelveticaNeue, Helvetica
 Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:12pt;" class=""><div class="" style=""><span class="" style="">I believe the following two headers should do it:</span></div><div class="" style="background-color:transparent;">Access-Control-Allow-Origin: *</div><div class="" style="background-color:transparent;"><span class="" style=""></span></div><div class="" style="background-color:transparent;">Access-Control-Allow-Credentials: true</div><div class="" style="background-color:transparent;"><br clear="none" class="" style=""></div><div class="" style="color:rgb(0, 0, 0);font-size:16px;font-family:HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;font-style:normal;background-color:transparent;">But needs to be tested.</div> <div class="" style=""><br clear="none" class="" style=""><br clear="none" class="" style=""></div><div class="" style="display:block;"> <div class="" style="font-family:HelveticaNeue,
 Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:12pt;"> <div class="" style="font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:12pt;"> <div class="" id="yiv1671584635yqt20510" style=""><div class="" dir="ltr" style=""> <font class="" size="2" face="Arial" style=""> On Friday, June 6, 2014 2:31 PM, Mark Webb-Johnson <mark@webb-johnson.net> wrote:<br clear="none" class="" style=""> </font> </div>  <br clear="none" class="" style=""><br clear="none" class="" style=""> <div class="" style=""><div class="" id="yiv1671584635" style=""><div class="" style="">Bug squished. Live on tmc now (and pushed to github).<div class="" style=""><br clear="none" class="" style=""></div><div class="" style="">Neat web page. Shows promise.</div><div class="" style=""><br clear="none" class="" style=""></div><div class="" style="">Regarding the CORS, I’m very willing to make the changes - just not
 really sure what headers exactly need to be added. Anyone here
 know what I would need to add?</div><div class="" style=""><br clear="none" class="" style=""></div><div class="" style="">Regards, Mark.</div><div class="" style=""><br clear="none" class="" style=""></div><div class="" id="yiv1671584635yqt61277" style=""><div class="" style=""><div class="" style=""><div class="" style="">On 6 Jun, 2014, at 3:03 pm, Michael Balzer <<a rel="nofollow" shape="rect" class="" ymailto="mailto:dexter@expeedo.de" target="_blank" href="mailto:dexter@expeedo.de" style="">dexter@expeedo.de</a>> wrote:</div><br clear="none" class="" style=""><blockquote class="" type="cite" style="">
  
    </blockquote></div></div></div></div><div class="" id="yiv1671584635yqt37411" style=""><div class="" style=""><div class="" style="">
    <div class="" style="">Nikolay,<br clear="none" class="" style="">
      <br clear="none" class="" style="">
      you found an API server bug :-)<br clear="none" class="" style="">
      <br clear="none" class="" style="">
      Solution: delete all domain cookies for "<a rel="nofollow" shape="rect" class="" target="_blank" href="http://openvehicles.com/" style="">openvehicles.com</a>" from
      your browser before using the API.<br clear="none" class="" style="">
      <br clear="none" class="" style="">
      The API server gets confused by multiple cookies. If you visit
      <a rel="nofollow" shape="rect" class="" target="_blank" href="http://www.openvehicles.com/" style="">www.openvehicles.com</a> before using the API, you get a persistent
      PHP session cookie like this:<br clear="none" class="" style="">
      <br clear="none" class="" style="">
      Name    SESS619b2b3f204291df32506531f8b446dd<br clear="none" class="" style="">
      Host    .<a rel="nofollow" shape="rect" class="" target="_blank" href="http://openvehicles.com/" style="">openvehicles.com</a><br clear="none" class="" style="">
      Pfad    /<br clear="none" class="" style="">
      <br clear="none" class="" style="">
      As the host defines ".<a rel="nofollow" shape="rect" class="" target="_blank" href="http://openvehicles.com/" style="">openvehicles.com</a>" and path "/", this cookie
      also gets sent to the API host, which then confuses this one with
      the "ovmsapisession" cookie, i.e.<br clear="none" class="" style="">
      <br clear="none" class="" style="">
      Name    ovmsapisession<br clear="none" class="" style="">
      Host    <a rel="nofollow" shape="rect" class="" target="_blank" href="http://tmc.openvehicles.com/" style="">tmc.openvehicles.com</a><br clear="none" class="" style="">
      Pfad    /api/<br clear="none" class="" style="">
      <br clear="none" class="" style="">
      Regards,<br clear="none" class="" style="">
      Michael<br clear="none" class="" style="">
      <br clear="none" class="" style="">
      <br clear="none" class="" style="">
      Am 05.06.2014 23:46, schrieb Nikolay Shishkov:<br clear="none" class="" style="">
    </div>
    <blockquote class="" type="cite" style="">
      <div class="" style="background-color:rgb(255, 255, 255);font-family:HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;font-size:12pt;">
        <div class="" style=""><span class="" style="">Thanks Michael, </span></div>
        <div class="" style="font-size:16px;font-style:normal;background-color:transparent;"><span class="" style="">I am getting "login ok" when pressing on
            the login button, but then all the other buttons are giving
            "authentication error" message. </span></div>
        <div class="" style="font-size:16px;font-style:normal;background-color:transparent;"><span class="" style="">I could check that the cookie is sent with
            the request, but the server seems to respond with the 400
            code. </span></div>
        <div class="" style="font-size:16px;font-style:normal;background-color:transparent;">I tried in Chrome. Where, how do you use the
          page?</div>
        <div class="" style="font-size:16px;font-style:normal;background-color:transparent;">Nikolay</div>
        <div class="" style=""><br clear="none" class="" style="">
          <br clear="none" class="" style="">
        </div>
        <div class="" style="display:block;">
          <div class="" style="font-family:HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;font-size:12pt;">
            <div class="" style="font-family:HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;font-size:12pt;">
              <div class="" dir="ltr" style=""> <font class="" size="2" face="Arial" style=""> On Thursday,
                  June 5, 2014 10:59 PM, Michael Balzer
                  <a rel="nofollow" shape="rect" class="" ymailto="mailto:dexter@expeedo.de" target="_blank" href="mailto:dexter@expeedo.de" style=""><dexter@expeedo.de></a> wrote:<br clear="none" class="" style="">
                </font> </div>
              <br clear="none" class="" style="">
              <br clear="none" class="" style="">
              <div class="" style="">
                <div class="" id="yiv1671584635" style="">
                  <div class="" style=""> Nikolay,<br clear="none" class="" style="">
                    <br clear="none" class="" style="">
                    that's right, I intend to get this running without
                    an otherwise necessary proxy, i.e. for local HTML
                    pages on mobile devices or the like. I've been in
                    contact with Mark about CORS on the perl server.<br clear="none" class="" style="">
                    <br clear="none" class="" style="">
                    A server could of course be used, most simply the
                    HTTP API itself could deliver the client page, but
                    CORS should now enable to cope without and open
                    possible cross origin data/control integrations. Not
                    sure about static pages for this though, not yet
                    tested. I think it would be cool to just load some
                    HTML file in your browser and have a graphical OVMS
                    client.<br clear="none" class="" style="">
                    <br clear="none" class="" style="">
                    The "code" is currently just a first test bed HTML
                    page to interact with the HTTP API. No graphics,
                    just a simple table view. Works, but is clumsy as
                    hell.<br clear="none" class="" style="">
                    <br clear="none" class="" style="">
                    Try yourself, I've attached it.<br clear="none" class="" style="">
                    <br clear="none" class="" style="">
                    Regards,<br clear="none" class="" style="">
                    Michael<br clear="none" class="" style="">
                    <br clear="none" class="" style="">
                    <br clear="none" class="" style="">
                    <div class="" style="">Am
                      05.06.2014 11:26, schrieb Nikolay Shishkov:<br clear="none" class="" style="">
                    </div>
                    <blockquote class="" type="cite" style="">
                      <div class="" id="yiv1671584635yqt66378" style="">
                        <div class="" style="font-family:HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;font-size:12pt;background-color:rgb(255, 255, 255);">
                          <div class="" style=""><span class="" style="">Hi
                              Michael, </span></div>
                          <div class="" style="font-size:16px;font-family:HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;font-style:normal;background-color:transparent;"><span class="" style=""><br clear="none" class="" style="">
                            </span></div>
                          <div class="" style="font-size:16px;font-family:HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;font-style:normal;background-color:transparent;">I am very interested in the
                            "Browser client using HTTP API and
                            jQuery/Flot for visualization". From the
                            comment that CORS is needed I suspect you
                            want to have the html5 page locally and then
                            fetch data from the server while using other
                            sources for context data. </div>
                          <div class="" style="font-size:16px;font-family:HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;font-style:normal;background-color:transparent;">Have you considered running
                            this on a separate server that serves as a
                            gateway to the TMC server?</div>
                          <div class="" style="font-size:16px;font-family:HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;font-style:normal;background-color:transparent;"><br clear="none" class="" style="">
                          </div>
                          <div class="" style="font-size:16px;font-family:HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;font-style:normal;background-color:transparent;">Have you uploaded the code
                            somewhere?</div>
                          <div class="" style="font-size:16px;font-family:HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;font-style:normal;background-color:transparent;"><br clear="none" class="" style="">
                          </div>
                          <div class="" style="font-size:16px;font-family:HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;font-style:normal;background-color:transparent;">I have been playing around
                            with C# client and was thinking of using it
                            on an <a rel="nofollow" shape="rect" class="" target="_blank" href="http://asp.net/" style="">asp.net</a> server...</div>
                          <div class="" style="font-size:16px;font-family:HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;font-style:normal;background-color:transparent;"><br clear="none" class="" style="">
                          </div>
                          <div class="" style="font-size:16px;font-family:HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;font-style:normal;background-color:transparent;">Nikolay</div>
                          <div class="" style=""><br clear="none" class="" style="">
                            <br clear="none" class="" style="">
                          </div>
                          <div class="" style="display:block;">
                            <div class="" style="font-family:HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;font-size:12pt;">
                              <div class="" style="font-family:HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;font-size:12pt;">
                                <div class="" dir="ltr" style=""> <font class="" style="" size="2" face="Arial"> On
                                    Wednesday, June 4, 2014 11:22 PM,
                                    Michael Balzer <a rel="nofollow" shape="rect" class="" ymailto="mailto:dexter@expeedo.de" target="_blank" href="mailto:dexter@expeedo.de" style=""><dexter@expeedo.de></a>
                                    wrote:<br clear="none" class="" style="">
                                  </font> </div>
                                <br clear="none" class="" style="">
                                <br clear="none" class="" style="">
                                <div class="" style="">Am
                                  04.06.2014 07:38, schrieb Gianluca
                                  Magalotti:<br clear="none" class="" style="">
                                  > For nice2have features I'll wait
                                  for your list (I have my personal <br clear="none" class="" style="">
                                  > list too but maybe we'll have a
                                  later focus on that)<br clear="none" class="" style="">
                                  <br clear="none" class="" style="">
                                  So here it is.<br clear="none" class="" style="">
                                  <br clear="none" class="" style="">
                                  If other Twizy drivers would like to
                                  add their ideas, you're welcome.<br clear="none" class="" style="">
                                  <br clear="none" class="" style="">
                                  I'll do my best to check new ideas
                                  against my collected knowledge of <br clear="none" class="" style="">
                                  what's possible up to now and give you
                                  some feedback.
                                  <div class="" id="yiv1671584635yqtfd99580" style=""><br clear="none" class="" style="">
                                    <br clear="none" class="" style="">
                                    Regards,<br clear="none" class="" style="">
                                    Michael</div>
                                  <br clear="none" class="" style="">
                                  <br clear="none" class="" style="">
                                  -- <br clear="none" class="" style="">
                                  Michael Balzer * Paradestr. 8 *
                                  D-42107 Wuppertal<br clear="none" class="" style="">
                                  Fon 0202 / 272 2201 * Handy 0176 / 206
                                  989 26
                                  <div class="" id="yiv1671584635yqtfd18255" style=""><br clear="none" class="" style="">
                                    <br clear="none" class="" style="">
                                  </div>
                                  <br clear="none" class="" style="">
                                  <div class="" id="yiv1671584635yqtfd30669" style="">_______________________________________________<br clear="none" class="" style="">
                                    OvmsDev mailing list<br clear="none" class="" style="">
                                    <a rel="nofollow" shape="rect" class="" ymailto="mailto:OvmsDev@lists.teslaclub.hk" target="_blank" href="mailto:OvmsDev@lists.teslaclub.hk" style="">OvmsDev@lists.teslaclub.hk</a><br clear="none" class="" style="">
                                    <a rel="nofollow" shape="rect" class="" target="_blank" href="http://lists.teslaclub.hk/mailman/listinfo/ovmsdev" style="">http://lists.teslaclub.hk/mailman/listinfo/ovmsdev</a><br clear="none" class="" style="">
                                  </div>
                                  <br clear="none" class="" style="">
                                  <br clear="none" class="" style="">
                                </div>
                              </div>
                            </div>
                          </div>
                        </div>
                      </div>
                      <br clear="none" class="" style="">
                      <fieldset class="" style=""></fieldset>
                      <br clear="none" class="" style="">
                      <pre class="" style="">_______________________________________________
OvmsDev mailing list
<a rel="nofollow" shape="rect" class="" ymailto="mailto:OvmsDev@lists.teslaclub.hk" target="_blank" href="mailto:OvmsDev@lists.teslaclub.hk" style="">OvmsDev@lists.teslaclub.hk</a>
<a rel="nofollow" shape="rect" class="" target="_blank" href="http://lists.teslaclub.hk/mailman/listinfo/ovmsdev" style="">http://lists.teslaclub.hk/mailman/listinfo/ovmsdev</a>
</pre>
                    </blockquote>
                    <br clear="none" class="" style="">
                    <pre class="" style="">-- 
Michael Balzer * Paradestr. 8 * D-42107 Wuppertal
Fon 0202 / 272 2201 * Handy 0176 / 206 989 26
</pre>
                  </div>
                </div>
                <br clear="none" class="" style="">
                <div class="" id="yiv1671584635yqt96220" style="">_______________________________________________<br clear="none" class="" style="">
                  OvmsDev mailing list<br clear="none" class="" style="">
                  <a rel="nofollow" shape="rect" class="" ymailto="mailto:OvmsDev@lists.teslaclub.hk" target="_blank" href="mailto:OvmsDev@lists.teslaclub.hk" style="">OvmsDev@lists.teslaclub.hk</a><br clear="none" class="" style="">
                  <a rel="nofollow" shape="rect" class="" target="_blank" href="http://lists.teslaclub.hk/mailman/listinfo/ovmsdev" style="">http://lists.teslaclub.hk/mailman/listinfo/ovmsdev</a><br clear="none" class="" style="">
                </div>
                <br clear="none" class="" style="">
                <br clear="none" class="" style="">
              </div>
            </div>
          </div>
        </div>
      </div>
      <br clear="none" class="" style="">
      <fieldset class="" style=""></fieldset>
      <br clear="none" class="" style="">
      <pre class="" style="">_______________________________________________
OvmsDev mailing list
<a rel="nofollow" shape="rect" class="" ymailto="mailto:OvmsDev@lists.teslaclub.hk" target="_blank" href="mailto:OvmsDev@lists.teslaclub.hk" style="">OvmsDev@lists.teslaclub.hk</a>
<a rel="nofollow" shape="rect" class="" target="_blank" href="http://lists.teslaclub.hk/mailman/listinfo/ovmsdev" style="">http://lists.teslaclub.hk/mailman/listinfo/ovmsdev</a>
</pre>
    </blockquote>
    <br clear="none" class="" style="">
    <br clear="none" class="" style="">
    <pre class="" style="">-- 
Michael Balzer * Paradestr. 8 * D-42107 Wuppertal
Fon 0202 / 272 2201 * Handy 0176 / 206 989 26
</pre>
  </div>

_______________________________________________<br clear="none" class="" style="">OvmsDev mailing list<br clear="none" class="" style=""><a rel="nofollow" shape="rect" class="" ymailto="mailto:OvmsDev@lists.teslaclub.hk" target="_blank" href="mailto:OvmsDev@lists.teslaclub.hk" style="">OvmsDev@lists.teslaclub.hk</a><br clear="none" class="" style="">http://lists.teslaclub.hk/mailman/listinfo/ovmsdev<br clear="none" class="" style=""><br clear="none" class="" style=""></div></div></div><br clear="none" class="" style=""><div class="" id="yiv1671584635yqt95950" style="">_______________________________________________<br clear="none" class="" style="">OvmsDev mailing list<br clear="none" class="" style=""><a rel="nofollow" shape="rect" class="" ymailto="mailto:OvmsDev@lists.teslaclub.hk" target="_blank" href="mailto:OvmsDev@lists.teslaclub.hk" style="">OvmsDev@lists.teslaclub.hk</a><br clear="none" class="" style=""><a rel="nofollow" shape="rect" class=""
 target="_blank" href="http://lists.teslaclub.hk/mailman/listinfo/ovmsdev" style="">http://lists.teslaclub.hk/mailman/listinfo/ovmsdev</a><br clear="none" class="" style=""></div><br clear="none" class="" style=""><br clear="none" class="" style=""></div></div>  </div> </div>  </div> </div></div></div><br class="" style=""><br class="" style=""></div>  </div> </div>  </div> </div></body></html>