|
Posted by Kris Zyp on 02/24/07 06:53
I frequently use Ajax requests with responses of 100K+ with no
problems for both IE and FF.
Kris
On Feb 23, 7:14 pm, Jeff North <jnort...@yahoo.com.au> wrote:
> On 23 Feb 2007 16:48:19 -0800, in comp.lang.javascript
> trp...@gmail.com
>
> <1172278099.323577.325...@p10g2000cwp.googlegroups.com> wrote:
> >| I am using ajax / php where I am looking up some info from the
> >| database and populating a select list dynamically, however I am
> >| running into some sort of size limitation with the ajax.response
> >| object. If the string I am passing to javascript from php is too large
> >| javascript does not get it all the data. The magic number appears to
> >| be 6123 characters, anything below that it works fine, anything above
> >| and if I alert the ajax.response, I see the string is cutoff. Any
> >| ideas where this limitation is defined?
>
> Your page:
> <select name="lbItems" onChange="AJAXCall(this.value);">
> <option value="1">1</option>
> etc etc etc
> </select>
>
> Javascript function on your page
> function AJAXCall(val)
> {
> //--- make your ajaxcall here
> url = "mypage.php?id=" + val;
>
> }
>
> php page:
> <?php
> $id = 0;
> if( isset($_GET['id]) ) $id = $_GET['id'];
> if( !is_numeric($id) ) $id =0;
>
> //--- read database
> $sql = "SELECT * FROM yourtable WHERE pk=".$id;
>
> //--- loop through recordset and populate listbox
> echo "<option value='".$recPK."'>".$recText."</option>\n";
> ?>
> ---------------------------------------------------------------
> jnort...@yourpantsyahoo.com.au : Remove your pants to reply
> ---------------------------------------------------------------
Navigation:
[Reply to this message]
|