Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AsyncRequest add get(uri, timeout) and post(uri, data, timeout) methods #2

Closed
GarrettS opened this issue Jan 23, 2010 · 1 comment
Closed

Comments

@GarrettS
Copy link
Owner

AsyncRequest has a send() method and accepts a uri in the config to the constructor.

This is inflexible when you want to change the query string around.

Propose to change AsyncRequest add two methods:

  • get(uri, timeout)
  • post(uri, data, timeout)

A parallel API for a ScriptLoader can use same interface, so can be an alternative for get().

@GarrettS
Copy link
Owner Author

GarrettS commented Feb 1, 2010

methods added:
get(queryParams, timeoutMillis) and post(data, timeoutMillis).

Also created a base file "ajax-base.js"containing:

APE.ajax.appendToURI
appends parameters to a URI with no hash, adding either & or ? delimiter.
APE.ajax.jsonp
noop callback used for default jsonp callback for scriptloader. JSONP 1-arg functions can be used with EventPublisher as APE.EventPublisher.add(APE.ajax, "jsonp", handler).

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant