Passing named parameter without the URL

View: New views
20 Messages — Rating Filter:   Alert me  
< Prev | 1 - 2 - 3 - 4 | Next >

Passing named parameter without the URL

by Jean-Baptiste BRIAUD -- Novlog :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi,

I'm using io.remote.Request and I'm trying to pass named parameters  
with setParameter method.
http://demo.qooxdoo.org/current/apiviewer/#qx.io.remote.Request

Unfortunatly, I found my param name and value always encoded in the  
URL : &name=value

How can I pass the parameter inside the HTTP request without the URL ?

Thanks !

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Re: Passing named parameter without the URL

by Matthew Gregory :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi Again Jean-Baptiste,
I haven't tested this yet put when you create your instance of
qx.io.remote.Request you should be able to specify "POST" as the second
parameter.

Or alternativly you could call myRequest.setMethod("POST");

After that just call setFormField instead of setParameter

HTH!
Matt

Jean-Baptiste BRIAUD -- Novlog wrote:

> Hi,
>
> I'm using io.remote.Request and I'm trying to pass named parameters  
> with setParameter method.
> http://demo.qooxdoo.org/current/apiviewer/#qx.io.remote.Request
>
> Unfortunatly, I found my param name and value always encoded in the  
> URL : &name=value
>
> How can I pass the parameter inside the HTTP request without the URL ?
>
> Thanks !
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
> Build the coolest Linux based applications with Moblin SDK & win great prizes
> Grand prize is a trip for two to an Open Source event anywhere in the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Re: Passing named parameter without the URL

by Derrell Lipman :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On Mon, Nov 17, 2008 at 2:25 PM, Jean-Baptiste BRIAUD -- Novlog <j-b.briaud@...> wrote:
Hi,

I'm using io.remote.Request and I'm trying to pass named parameters
with setParameter method.
http://demo.qooxdoo.org/current/apiviewer/#qx.io.remote.Request

Unfortunatly, I found my param name and value always encoded in the
URL : &name=value

How can I pass the parameter inside the HTTP request without the URL ?

Using setParameter() specifically tells it to encode the parameters in the URL.  I believe you're looking for setFormField().

Cheers,

Derrell
 


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Simple tree navigation

by Kenny Tilton-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

My first qooxdoo trick is modifying the SplitButton example to have the
button reflect the selected value:

       menuItem.addListener("execute", function(e){
          button.setLabel(this.getLabel());
          });

Where the anonymous function closes over the local variable button to
know who to set. As an exercise in learning qooxdoo, tho, I wanted to
find the split button instance by navigating up the qui hierarchy
looking for such a beast:

function getAscendantTyped(self,type) {
   if (self) {
      var par = self.getLayoutParent(); // not .parentNode it seems
      console.log("getasc sees parents " + par);
      if (par instanceof type) {
        return par;
      } else {
         return getAscendantTyped(par, type);
      }
   }
}

This (or something close, I have been cleaning it up since pasting it
from my actual code) looks like it will work, but that "Layout" bit has
me nervous. Yet I cannot find anything more promising.

I got all excited about parentNode when I saw that used by getAncestors,
but then I could not find anywhere in the source that getAncestors was used.

So is getLayoutParent the way to navigate up a qooxdoo visual hierarchy?

kt

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Re: Passing named parameter without the URL

by Jean-Baptiste BRIAUD -- Novlog :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I never used GET and set that parameter with constructor : var req =  
new qx.io.remote.Request("http://...", "POST", contentType);
On 17 Nov 2008, at 21:19, Matthew Gregory wrote:

> Hi Again Jean-Baptiste,
> I haven't tested this yet put when you create your instance of
> qx.io.remote.Request you should be able to specify "POST" as the  
> second
> parameter.
>
> Or alternativly you could call myRequest.setMethod("POST");
>
> After that just call setFormField instead of setParameter
>
> HTH!
> Matt
>
> Jean-Baptiste BRIAUD -- Novlog wrote:
>> Hi,
>>
>> I'm using io.remote.Request and I'm trying to pass named parameters
>> with setParameter method.
>> http://demo.qooxdoo.org/current/apiviewer/#qx.io.remote.Request
>>
>> Unfortunatly, I found my param name and value always encoded in the
>> URL : &name=value
>>
>> How can I pass the parameter inside the HTTP request without the  
>> URL ?
>>
>> Thanks !
>>
>> -------------------------------------------------------------------------
>> This SF.Net email is sponsored by the Moblin Your Move Developer's  
>> challenge
>> Build the coolest Linux based applications with Moblin SDK & win  
>> great prizes
>> Grand prize is a trip for two to an Open Source event anywhere in  
>> the world
>> http://moblin-contest.org/redirect.php?banner_id=100&url=/
>
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's  
> challenge
> Build the coolest Linux based applications with Moblin SDK & win  
> great prizes
> Grand prize is a trip for two to an Open Source event anywhere in  
> the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> qooxdoo-devel mailing list
> qooxdoo-devel@...
> https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
>


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Re: Passing named parameter without the URL

by Jean-Baptiste BRIAUD -- Novlog :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On 17 Nov 2008, at 21:21, Derrell Lipman wrote:

On Mon, Nov 17, 2008 at 2:25 PM, Jean-Baptiste BRIAUD -- Novlog <j-b.briaud@...> wrote:
Hi,

I'm using io.remote.Request and I'm trying to pass named parameters
with setParameter method.
http://demo.qooxdoo.org/current/apiviewer/#qx.io.remote.Request

Unfortunatly, I found my param name and value always encoded in the
URL : &name=value

How can I pass the parameter inside the HTTP request without the URL ?

Using setParameter() specifically tells it to encode the parameters in the URL.  I believe you're looking for setFormField().

That may explain something :-)

Strangely, when I use setFormField, the request is not submited ...

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Re: Passing named parameter without the URL

by Jean-Baptiste BRIAUD -- Novlog :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


On 17 Nov 2008, at 21:45, Jean-Baptiste BRIAUD -- Novlog wrote:

On 17 Nov 2008, at 21:21, Derrell Lipman wrote:

On Mon, Nov 17, 2008 at 2:25 PM, Jean-Baptiste BRIAUD -- Novlog <j-b.briaud@...> wrote:
Hi,

I'm using io.remote.Request and I'm trying to pass named parameters
with setParameter method.
http://demo.qooxdoo.org/current/apiviewer/#qx.io.remote.Request

Unfortunatly, I found my param name and value always encoded in the
URL : &name=value

How can I pass the parameter inside the HTTP request without the URL ?

Using setParameter() specifically tells it to encode the parameters in the URL.  I believe you're looking for setFormField().

That may explain something :-)

Strangely, when I use setFormField, the request is not submited ...

OK, I managed to make it work with setFormField but from my backend point of view, it look like using form and setting a request parameter is not exactly the same.
Could one confirm that using form and using request parameter is different or is the same ?


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Re: Simple tree navigation

by Kenny Tilton-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Kenny Tilton wrote:

> My first qooxdoo trick is modifying the SplitButton example to have the
> button reflect the selected value:
>
>        menuItem.addListener("execute", function(e){
>   button.setLabel(this.getLabel());
>  });
>
> Where the anonymous function closes over the local variable button to
> know who to set. As an exercise in learning qooxdoo, tho, I wanted to
> find the split button instance by navigating up the qui hierarchy
> looking for such a beast:
>
> function getAscendantTyped(self,type) {
>    if (self) {
>       var par = self.getLayoutParent(); // not .parentNode it seems
>       console.log("getasc sees parents " + par);
>       if (par instanceof type) {
> return par;
>       } else {
>          return getAscendantTyped(par, type);
>       }
>    }
> }
>
> This (or something close, I have been cleaning it up since pasting it
> from my actual code) looks like it will work, but that "Layout" bit has
> me nervous.

For good reason. That hook took me to the Menu and then to the Application.

I think I have the wrong widget as well as the wrong navigation. :)

kt

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Re: Passing named parameter without the URL

by Derrell Lipman :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On Mon, Nov 17, 2008 at 3:45 PM, Jean-Baptiste BRIAUD -- Novlog <j-b.briaud@...> wrote:
On 17 Nov 2008, at 21:21, Derrell Lipman wrote:

On Mon, Nov 17, 2008 at 2:25 PM, Jean-Baptiste BRIAUD -- Novlog <j-b.briaud@...> wrote:
Hi,

I'm using io.remote.Request and I'm trying to pass named parameters
with setParameter method.
http://demo.qooxdoo.org/current/apiviewer/#qx.io.remote.Request

Unfortunatly, I found my param name and value always encoded in the
URL : &name=value

How can I pass the parameter inside the HTTP request without the URL ?

Using setParameter() specifically tells it to encode the parameters in the URL.  I believe you're looking for setFormField().

That may explain something :-)

Strangely, when I use setFormField, the request is not submited ...

What does your debug console tell you?  There's almost certainly a message from qx.io.remote.<something> providing a reason.  Be sure that you're using the "source" version, not a "build", and that you've enabled a log appender, e.g. by adding these lines to your main():

      // Enable logging in debug variant
      if (qx.core.Variant.isSet("qx.debug", "on"))
      {
        // support native logging capabilities, e.g. Firebug for Firefox
        qx.log.appender.Native;

        // support additional cross-browser console. Press F7 to
        // toggle visibility
        qx.log.appender.Console;
      }

Derrell


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Re: Passing named parameter without the URL

by Derrell Lipman :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On Mon, Nov 17, 2008 at 3:50 PM, Jean-Baptiste BRIAUD -- Novlog <j-b.briaud@...> wrote:

On 17 Nov 2008, at 21:45, Jean-Baptiste BRIAUD -- Novlog wrote:

On 17 Nov 2008, at 21:21, Derrell Lipman wrote:

On Mon, Nov 17, 2008 at 2:25 PM, Jean-Baptiste BRIAUD -- Novlog <j-b.briaud@...> wrote:
Hi,

I'm using io.remote.Request and I'm trying to pass named parameters
with setParameter method.
http://demo.qooxdoo.org/current/apiviewer/#qx.io.remote.Request

Unfortunatly, I found my param name and value always encoded in the
URL : &name=value

How can I pass the parameter inside the HTTP request without the URL ?

Using setParameter() specifically tells it to encode the parameters in the URL.  I believe you're looking for setFormField().

That may explain something :-)

Strangely, when I use setFormField, the request is not submited ...

OK, I managed to make it work with setFormField but from my backend point of view, it look like using form and setting a request parameter is not exactly the same.
Could one confirm that using form and using request parameter is different or is the same ?

If you have form fields, then a different transport will be used.  Without them, you were getting the XmlHttp transport.  That transport, however, doesn't support form fields, so you're now getting the IFrame transport.  Yes, what you see on the server will be slightly different.  You'll see form fields since you're saying setFormField(). :-)  You can expect, however, that as long as you don't change the parameters of your request (the parameters being synchronous vs async, selection or deselection of crossDomain, use or non-use of form fields, and your specified response type) that you'll continue to get the same automatically selected transport for every request.

Derrell



-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Re: Passing named parameter without the URL

by Jean-Baptiste BRIAUD -- Novlog :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


On 17 Nov 2008, at 21:53, Derrell Lipman wrote:

On Mon, Nov 17, 2008 at 3:45 PM, Jean-Baptiste BRIAUD -- Novlog <j-b.briaud@...> wrote:
On 17 Nov 2008, at 21:21, Derrell Lipman wrote:

On Mon, Nov 17, 2008 at 2:25 PM, Jean-Baptiste BRIAUD -- Novlog <j-b.briaud@...> wrote:
Hi,

I'm using io.remote.Request and I'm trying to pass named parameters
with setParameter method.
http://demo.qooxdoo.org/current/apiviewer/#qx.io.remote.Request

Unfortunatly, I found my param name and value always encoded in the
URL : &name=value

How can I pass the parameter inside the HTTP request without the URL ?

Using setParameter() specifically tells it to encode the parameters in the URL.  I believe you're looking for setFormField().

That may explain something :-)

Strangely, when I use setFormField, the request is not submited ...

What does your debug console tell you?  There's almost certainly a message from qx.io.remote.<something> providing a reason.  Be sure that you're using the "source" version, not a "build", and that you've enabled a log appender, e.g. by adding these lines to your main():

      // Enable logging in debug variant
      if (qx.core.Variant.isSet("qx.debug", "on"))
      {
        // support native logging capabilities, e.g. Firebug for Firefox
        qx.log.appender.Native;

        // support additional cross-browser console. Press F7 to
        // toggle visibility
        qx.log.appender.Console;
      }

I manage to make it work with application/json instead of text/html content type.

I normaly use application/json but for testing purpose on the backend, I had to switch to text/html because the backend retrun in that case some more debug info and application/json make qooxdoo trying to execute that debug info.

I'm using a build version, the one that Petr kindly made for me.
Despite the enabled console, absolutly nothing was logged.

I'm a little bit scared to use a source version for a production application but I'm still quite new to qooxdoo, so ... I'll follow your advice : would you advice me to use the trunk version in SVN ?
In such a case, when will I know I could upgrade from repository without taking the risk of breaking my app with a broken trunk ?



-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Re: Simple tree navigation

by Petr Kobalíček :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi Kenny,

I don't know what you are really doing, but maybe this will help you:)

In tree, you can simply add changeSelection event

// 'this' is your main object / widget / what you need
_createUI: function()
{
  this._tree = new qx.ui.tree.Tree().set(
  {
    backgroundColor : "white",
    rootOpenClose   : true
  });
  this._root = new qx.ui.tree.TreeFolder("Root");
  this._tree.setRoot(this._fileTreeRoot);
  this._tree.addListener("changeSelection", this._onTreeChange, this);

  // add this._tree to your container...
},

// and onTreeChange() event
_onTreeChange: function(e)
{
  var item = e.getData()[0];

  if (item)
  {
    // ... item is your item, do whatever you need with it ;)
  }
},

Hope that helps:)
- Petr

2008/11/17 Kenny Tilton <kennytilton@...>:

> Kenny Tilton wrote:
>> My first qooxdoo trick is modifying the SplitButton example to have the
>> button reflect the selected value:
>>
>>        menuItem.addListener("execute", function(e){
>>               button.setLabel(this.getLabel());
>>         });
>>
>> Where the anonymous function closes over the local variable button to
>> know who to set. As an exercise in learning qooxdoo, tho, I wanted to
>> find the split button instance by navigating up the qui hierarchy
>> looking for such a beast:
>>
>> function getAscendantTyped(self,type) {
>>    if (self) {
>>       var par = self.getLayoutParent(); // not .parentNode it seems
>>       console.log("getasc sees parents " + par);
>>       if (par instanceof type) {
>>       return par;
>>       } else {
>>          return getAscendantTyped(par, type);
>>       }
>>    }
>> }
>>
>> This (or something close, I have been cleaning it up since pasting it
>> from my actual code) looks like it will work, but that "Layout" bit has
>> me nervous.
>
> For good reason. That hook took me to the Menu and then to the Application.
>
> I think I have the wrong widget as well as the wrong navigation. :)
>
> kt
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
> Build the coolest Linux based applications with Moblin SDK & win great prizes
> Grand prize is a trip for two to an Open Source event anywhere in the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> qooxdoo-devel mailing list
> qooxdoo-devel@...
> https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
>

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Re: Passing named parameter without the URL

by Petr Kobalíček :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi devs,

I have only one thing about this discussion.

I really don't understand, why setFormField() must use different
transport method. I wrote some time ago own transport class for our
app, because way that setFormField() works not worked for me well.

Maybe in older mails is some more info, but the question is, is really
needed to switch transport by using setFormField() ? My way is that I
will serialize parameters and use setData(). This works fine and I
haven't encountered problem yet.

Only disadventage is that uploading not works by this way, but for
uploading we have another solution, aren't we ?

The requests and responses I'm using looks like this:

          var req = new
bfly.io.remote.Request(this.provider.opt.address.remove, "POST");

          req.addPostParameter("id", this.getId());
          req.addListener("success", function(e)
          {
            this.provider.query("$", /*force*/ true);
          }, this);
          req.addListener("error", app._onRequestFailure, app);
          req.send();

Cheers
- Petr

2008/11/17 Jean-Baptiste BRIAUD -- Novlog <j-b.briaud@...>:

>
> On 17 Nov 2008, at 21:53, Derrell Lipman wrote:
>
> On Mon, Nov 17, 2008 at 3:45 PM, Jean-Baptiste BRIAUD -- Novlog
> <j-b.briaud@...> wrote:
>>
>> On 17 Nov 2008, at 21:21, Derrell Lipman wrote:
>>
>> On Mon, Nov 17, 2008 at 2:25 PM, Jean-Baptiste BRIAUD -- Novlog
>> <j-b.briaud@...> wrote:
>>>
>>> Hi,
>>>
>>> I'm using io.remote.Request and I'm trying to pass named parameters
>>> with setParameter method.
>>> http://demo.qooxdoo.org/current/apiviewer/#qx.io.remote.Request
>>>
>>> Unfortunatly, I found my param name and value always encoded in the
>>> URL : &name=value
>>>
>>> How can I pass the parameter inside the HTTP request without the URL ?
>>
>> Using setParameter() specifically tells it to encode the parameters in the
>> URL.  I believe you're looking for setFormField().
>>
>> That may explain something :-)
>> Strangely, when I use setFormField, the request is not submited ...
>
> What does your debug console tell you?  There's almost certainly a message
> from qx.io.remote.<something> providing a reason.  Be sure that you're using
> the "source" version, not a "build", and that you've enabled a log appender,
> e.g. by adding these lines to your main():
>
>       // Enable logging in debug variant
>       if (qx.core.Variant.isSet("qx.debug", "on"))
>       {
>         // support native logging capabilities, e.g. Firebug for Firefox
>         qx.log.appender.Native;
>
>         // support additional cross-browser console. Press F7 to
>         // toggle visibility
>         qx.log.appender.Console;
>       }
>
> I manage to make it work with application/json instead of text/html content
> type.
> I normaly use application/json but for testing purpose on the backend, I had
> to switch to text/html because the backend retrun in that case some more
> debug info and application/json make qooxdoo trying to execute that debug
> info.
> I'm using a build version, the one that Petr kindly made for me.
> Despite the enabled console, absolutly nothing was logged.
> I'm a little bit scared to use a source version for a production application
> but I'm still quite new to qooxdoo, so ... I'll follow your advice : would
> you advice me to use the trunk version in SVN ?
> In such a case, when will I know I could upgrade from repository without
> taking the risk of breaking my app with a broken trunk ?
>
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
> Build the coolest Linux based applications with Moblin SDK & win great
> prizes
> Grand prize is a trip for two to an Open Source event anywhere in the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> qooxdoo-devel mailing list
> qooxdoo-devel@...
> https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
>
>

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Re: Simple tree navigation

by Kenny Tilton-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Petr Kobalíček wrote:
> Hi Kenny,
>
> I don't know what you are really doing,...

Me neither, at the time. :) The widget I wanted was SelectBox, and it is
working like a charm. I need to slow down a little.

Thanks for all the trouble you took. My next train wreck will be loading
data from the server to populate the select box options. I kicked off
the XHR just now knowing the URL was invalid just to see it fail --
great error messages!

I think qooxdoo has a new user, assuming all goes well thru the
Table-with-remote data exercise coming up later tonight. I believe the
qooxdoo approach of hiding HTML & CSS is Exactly Right for JS frameworks.

cheers, kenny


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Re: Passing named parameter without the URL

by Derrell Lipman :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On Mon, Nov 17, 2008 at 5:17 PM, Petr Kobalíček <kobalicek.petr@...> wrote:
Hi devs,

I have only one thing about this discussion.

I really don't understand, why setFormField() must use different
transport method. I wrote some time ago own transport class for our
app, because way that setFormField() works not worked for me well.

Maybe in older mails is some more info, but the question is, is really
needed to switch transport by using setFormField() ? My way is that I
will serialize parameters and use setData(). This works fine and I
haven't encountered problem yet.

Only disadventage is that uploading not works by this way, but for
uploading we have another solution, aren't we ?

The requests and responses I'm using looks like this:

         var req = new
bfly.io.remote.Request(this.provider.opt.address.remove, "POST");

         req.addPostParameter("id", this.getId());
         req.addListener("success", function(e)
         {
           this.provider.query("$", /*force*/ true);
         }, this);
         req.addListener("error", app._onRequestFailure, app);
         req.send();

Hi Petr.  The whole set of qx.io.remote.* is not ideal.  We know, and a number of us have discussed this in the past.  It does, however, work for most applications, and no one has gotten around to actually rewriting it.  If you've written a replacement set of transport classes, I'd be interested in seeing them.  If you'd like to contribute your work, please either create a qooxdoo-contrib project with them or create a new bug and attach them to the bug so we can see what you've done.

Thanks!

Derrell


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

build vs source

by Kenny Tilton-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I was having trouble loading my page using my Lisp server. I saw dozens
of separate requests pulling in bits of JS, and then nothing, just a
blank screen. I had seen problems before loading big Dojo setups which
seemed clearly a timing problem, so with qooxdoo I did a "build" run of
generate.py and my page came up OK.

Only problem is that I am not getting any logging output, which I recall
is a feature, not a bug. But that leaves me in a bind, unable to debug.

So...is it possible to mix my own "un-built" application.js with a
pre-built JS file of all the stuff? That would probably load fine amd
then (I guess) my logging code will work. Yes? No?

cheers,kt

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

log request. [was:] Passing named parameter without the URL

by Jean-Baptiste BRIAUD -- Novlog :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi,

As we talked about several issues, I split them into several messages.

That one is about the fact some call to io.remote.Request are not log in the debig console the same way other call are.

I normaly use application/json but for testing purpose on the backend, I had to switch to text/html because the backend retrun in that case some more debug info and application/json make qooxdoo trying to execute that debug info.

I'm using a build version, the one that Petr kindly made for me.
Despite the enabled console, absolutly nothing was logged.

Amazingly, 2 different requests to the same backend, with the same transport layer but with only one difference are not debuged the same : one of them use setFormField.
That last one is not debugged while the other is nicely debuged with a tree like triangle that one could open and launch the request again to see the result.
This is by the way a very very nice way to debug a HTTP request ... when it worked :-)


On 17 Nov 2008, at 22:06, Jean-Baptiste BRIAUD -- Novlog wrote:


On 17 Nov 2008, at 21:53, Derrell Lipman wrote:

On Mon, Nov 17, 2008 at 3:45 PM, Jean-Baptiste BRIAUD -- Novlog <j-b.briaud@...> wrote:
On 17 Nov 2008, at 21:21, Derrell Lipman wrote:

On Mon, Nov 17, 2008 at 2:25 PM, Jean-Baptiste BRIAUD -- Novlog <j-b.briaud@...> wrote:
Hi,

I'm using io.remote.Request and I'm trying to pass named parameters
with setParameter method.
http://demo.qooxdoo.org/current/apiviewer/#qx.io.remote.Request

Unfortunatly, I found my param name and value always encoded in the
URL : &name=value

How can I pass the parameter inside the HTTP request without the URL ?

Using setParameter() specifically tells it to encode the parameters in the URL.  I believe you're looking for setFormField().

That may explain something :-)

Strangely, when I use setFormField, the request is not submited ...

What does your debug console tell you?  There's almost certainly a message from qx.io.remote.<something> providing a reason.  Be sure that you're using the "source" version, not a "build", and that you've enabled a log appender, e.g. by adding these lines to your main():

      // Enable logging in debug variant
      if (qx.core.Variant.isSet("qx.debug", "on"))
      {
        // support native logging capabilities, e.g. Firebug for Firefox
        qx.log.appender.Native;

        // support additional cross-browser console. Press F7 to
        // toggle visibility
        qx.log.appender.Console;
      }

I manage to make it work with application/json instead of text/html content type.

I normaly use application/json but for testing purpose on the backend, I had to switch to text/html because the backend retrun in that case some more debug info and application/json make qooxdoo trying to execute that debug info.

I'm using a build version, the one that Petr kindly made for me.
Despite the enabled console, absolutly nothing was logged.

I'm a little bit scared to use a source version for a production application but I'm still quite new to qooxdoo, so ... I'll follow your advice : would you advice me to use the trunk version in SVN ?
In such a case, when will I know I could upgrade from repository without taking the risk of breaking my app with a broken trunk ?


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Using SVN trunk rather than build [was:] Passing named parameter without the URL

by Jean-Baptiste BRIAUD -- Novlog :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi,

As we talked about several issues, I split them into several messages.
That one is about using SVN trunk of qooxdoo for developping a production application.

I'm a little bit scared to use a source version for a production application but I'm still quite new to qooxdoo, so ... I'll follow your advice : would you advice me to use the trunk version in SVN ?
In such a case, when will I know I could upgrade from repository without taking the risk of breaking my app with a broken trunk ?


On 17 Nov 2008, at 22:06, Jean-Baptiste BRIAUD -- Novlog wrote:


On 17 Nov 2008, at 21:53, Derrell Lipman wrote:

On Mon, Nov 17, 2008 at 3:45 PM, Jean-Baptiste BRIAUD -- Novlog <j-b.briaud@...> wrote:
On 17 Nov 2008, at 21:21, Derrell Lipman wrote:

On Mon, Nov 17, 2008 at 2:25 PM, Jean-Baptiste BRIAUD -- Novlog <j-b.briaud@...> wrote:
Hi,

I'm using io.remote.Request and I'm trying to pass named parameters
with setParameter method.
http://demo.qooxdoo.org/current/apiviewer/#qx.io.remote.Request

Unfortunatly, I found my param name and value always encoded in the
URL : &name=value

How can I pass the parameter inside the HTTP request without the URL ?

Using setParameter() specifically tells it to encode the parameters in the URL.  I believe you're looking for setFormField().

That may explain something :-)

Strangely, when I use setFormField, the request is not submited ...

What does your debug console tell you?  There's almost certainly a message from qx.io.remote.<something> providing a reason.  Be sure that you're using the "source" version, not a "build", and that you've enabled a log appender, e.g. by adding these lines to your main():

      // Enable logging in debug variant
      if (qx.core.Variant.isSet("qx.debug", "on"))
      {
        // support native logging capabilities, e.g. Firebug for Firefox
        qx.log.appender.Native;

        // support additional cross-browser console. Press F7 to
        // toggle visibility
        qx.log.appender.Console;
      }

I manage to make it work with application/json instead of text/html content type.

I normaly use application/json but for testing purpose on the backend, I had to switch to text/html because the backend retrun in that case some more debug info and application/json make qooxdoo trying to execute that debug info.

I'm using a build version, the one that Petr kindly made for me.
Despite the enabled console, absolutly nothing was logged.

I'm a little bit scared to use a source version for a production application but I'm still quite new to qooxdoo, so ... I'll follow your advice : would you advice me to use the trunk version in SVN ?
In such a case, when will I know I could upgrade from repository without taking the risk of breaking my app with a broken trunk ?


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Re: Passing named parameter without the URL

by Jean-Baptiste BRIAUD -- Novlog :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I feel that using form for passing parameter should not be mandatory  
and can lead to issue or hacks.
In particular, what will you do if you have to pass parameters on  
screen that have a form to transmit ?
This could ends with hidden fields in pure HTML and this is just a  
hack but with qooxdoo, there is no way I know to distinguish hidden  
parameters from real form field.
At the end, the server can sort all that out (this is the design cost  
of that hack), but this underline that we should be able to just have  
parameter not form field : this is different semantic.
In fact, we do have that in qooxdoo but it works only by using the URL  
to store parameters values.

So my question : how to have HTTP request parameter, not form field,  
using the body of the request, not URL ?

I remember from JEE API that you have a method like  
request.addParameter(String name, String value) that can pass  
parameter in the body of the HTTP request, not using the URL.
I forgot the details ...

So, I like the idea of having a req.addPostParameter("id", this.getId())
but then, I don't understand the code around, see the comments in the  
code : (question or comments before the line)

Is it a specific implementation of some underlying transport layer ?
If yes, how can you register new transport layer, how to you choose to  
use it ?

On 17 Nov 2008, at 23:17, Petr Kobalíček wrote:

> Hi devs,
>
> I have only one thing about this discussion.
>
> I really don't understand, why setFormField() must use different
> transport method. I wrote some time ago own transport class for our
> app, because way that setFormField() works not worked for me well.
>
> Maybe in older mails is some more info, but the question is, is really
> needed to switch transport by using setFormField() ? My way is that I
> will serialize parameters and use setData(). This works fine and I
> haven't encountered problem yet.
>
> Only disadventage is that uploading not works by this way, but for
> uploading we have another solution, aren't we ?
>
> The requests and responses I'm using looks like this:
>
no content type ?
>          var req = new  
> bfly.io.remote.Request(this.provider.opt.address.remove, "POST");
>

>          req.addPostParameter("id", this.getId());
>          req.addListener("success", function(e)
>          {
What does the $ mean ?

>            this.provider.query("$", /*force*/ true);
>          }, this);
>          req.addListener("error", app._onRequestFailure, app);
>          req.send();
>
> Cheers
> - Petr
>
> 2008/11/17 Jean-Baptiste BRIAUD -- Novlog <j-b.briaud@...>:
>>
>> On 17 Nov 2008, at 21:53, Derrell Lipman wrote:
>>
>> On Mon, Nov 17, 2008 at 3:45 PM, Jean-Baptiste BRIAUD -- Novlog
>> <j-b.briaud@...> wrote:
>>>
>>> On 17 Nov 2008, at 21:21, Derrell Lipman wrote:
>>>
>>> On Mon, Nov 17, 2008 at 2:25 PM, Jean-Baptiste BRIAUD -- Novlog
>>> <j-b.briaud@...> wrote:
>>>>
>>>> Hi,
>>>>
>>>> I'm using io.remote.Request and I'm trying to pass named parameters
>>>> with setParameter method.
>>>> http://demo.qooxdoo.org/current/apiviewer/#qx.io.remote.Request
>>>>
>>>> Unfortunatly, I found my param name and value always encoded in the
>>>> URL : &name=value
>>>>
>>>> How can I pass the parameter inside the HTTP request without the  
>>>> URL ?
>>>
>>> Using setParameter() specifically tells it to encode the  
>>> parameters in the
>>> URL.  I believe you're looking for setFormField().
>>>
>>> That may explain something :-)
>>> Strangely, when I use setFormField, the request is not submited ...
>>
>> What does your debug console tell you?  There's almost certainly a  
>> message
>> from qx.io.remote.<something> providing a reason.  Be sure that  
>> you're using
>> the "source" version, not a "build", and that you've enabled a log  
>> appender,
>> e.g. by adding these lines to your main():
>>
>>      // Enable logging in debug variant
>>      if (qx.core.Variant.isSet("qx.debug", "on"))
>>      {
>>        // support native logging capabilities, e.g. Firebug for  
>> Firefox
>>        qx.log.appender.Native;
>>
>>        // support additional cross-browser console. Press F7 to
>>        // toggle visibility
>>        qx.log.appender.Console;
>>      }
>>
>> I manage to make it work with application/json instead of text/html  
>> content
>> type.
>> I normaly use application/json but for testing purpose on the  
>> backend, I had
>> to switch to text/html because the backend retrun in that case some  
>> more
>> debug info and application/json make qooxdoo trying to execute that  
>> debug
>> info.
>> I'm using a build version, the one that Petr kindly made for me.
>> Despite the enabled console, absolutly nothing was logged.
>> I'm a little bit scared to use a source version for a production  
>> application
>> but I'm still quite new to qooxdoo, so ... I'll follow your  
>> advice : would
>> you advice me to use the trunk version in SVN ?
>> In such a case, when will I know I could upgrade from repository  
>> without
>> taking the risk of breaking my app with a broken trunk ?
>>
>>
>> -------------------------------------------------------------------------
>> This SF.Net email is sponsored by the Moblin Your Move Developer's  
>> challenge
>> Build the coolest Linux based applications with Moblin SDK & win  
>> great
>> prizes
>> Grand prize is a trip for two to an Open Source event anywhere in  
>> the world
>> http://moblin-contest.org/redirect.php?banner_id=100&url=/
>> _______________________________________________
>> qooxdoo-devel mailing list
>> qooxdoo-devel@...
>> https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
>>
>>
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's  
> challenge
> Build the coolest Linux based applications with Moblin SDK & win  
> great prizes
> Grand prize is a trip for two to an Open Source event anywhere in  
> the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> qooxdoo-devel mailing list
> qooxdoo-devel@...
> https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
>


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Re: build vs source

by Alexander Back :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi Kenny,

On Tuesday 18 November 2008 Kenny Tilton wrote:
> I was having trouble loading my page using my Lisp server. I saw dozens
> of separate requests pulling in bits of JS, and then nothing, just a
> blank screen.
The "source" version of qooxdoo uses a kind of "inlcude" script which includes
every necessary javascript file individually. These are the dozens separate
requests. The "build" version however uses a single loader JS file to load
another JS file which includes the whole application.
I wonder about your "blank screen". Are there no log messages? What kind of
logger do you use?
The log system of qooxdoo is capable of using FireBug (available as extension
with Firefox) for logging. Otherwise you can use the standard console which
should open whenever you hit the "F7" key.

> I had seen problems before loading big Dojo setups which
> seemed clearly a timing problem, so with qooxdoo I did a "build" run of
> generate.py and my page came up OK.
The "source" version incorporates some additional checks to help the developer
while developing. In the "build" version however these checks are "cut out"
to increase performance. That's why you don't get any errors in the "build"
version, which still is a little bit odd, since your page is working.

> Only problem is that I am not getting any logging output, which I recall
> is a feature, not a bug. But that leaves me in a bind, unable to debug.
Another feature of the "build" version to increase the performance: logging is
disabled.

> So...is it possible to mix my own "un-built" application.js with a
> pre-built JS file of all the stuff? That would probably load fine amd
> then (I guess) my logging code will work. Yes? No?
It's better to use the generator to let you generate a customized "source"
version of your application. This will enable logging for you and once you
are ready for production you can generate a "build" version of your
application.
Did you start with creating your own application using
the "create-application.py" script? If so, you can simply execute

"./generate.py source"

inside your application folder to generate your own "source" version.

If this doesn't fit for you let me know, but I recommend this way since it's
the standard way in qooxdoo :)

cheers,
  Alex

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@...
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
< Prev | 1 - 2 - 3 - 4 | Next >