Results 1 to 2 of 2

Thread: Possible problem in firefox with 'Dynamic Ajax Content' using non-unique filenames

  1. #1
    Join Date
    Jul 2006
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Possible problem in firefox with 'Dynamic Ajax Content' using non-unique filenames

    1) Script Title: Dynamic Ajax Content

    2) Script URL (on DD): http://www.dynamicdrive.com/dynamici...jaxcontent.htm

    3) Describe problem:

    I am finding that when using this code in Firefox (v1.5.0.4) to create a select box with options whose values all point to the same file (with only the query string being different) that the content loads 'stacked'. i.e.: each new page load keeps the previous page loaded, pushing down the previous page content. The desired effect is, of course, to 'overwrite' the previous page load so that only the most recent selection is visible.

    I don't find that I have this problem in Safari (the only other browser I've tested it in). Here is some of my code that may help clarify what I mean:

    The select box and content div (ga_merchants_info):

    HTML Code:
    <form action="/dev/trunk/pub/gotapex/admin/ga_merchants.php" method="post" name="ga_merchants_form" id="ga_merchants_form">
    <div>
    <table border="0">
    
    	<tr>
    		<td align="right" valign="top"><b></b></td>
    		<td valign="top" align="left"><select size="20" id="ga_merchants_select" onchange="javascript:ajaxcombo('ga_merchants_select', 'ga_merchants_info')" name="ga_merchants_select">
    
    	<option value="ga_merchants.php?op=info&amp;id=1">00Inkjets.com</option>
    	<option value="ga_merchants.php?op=info&amp;id=2">1 & 1</option>
    	<option value="ga_merchants.php?op=info&amp;id=3">1-800-Contacts.com</option>
    	<option value="ga_merchants.php?op=info&amp;id=4">1-800-Florals.com</option>
    	<option value="ga_merchants.php?op=info&amp;id=5">1-800-Flowers.com</option>
    	<option value="ga_merchants.php?op=info&amp;id=6">1-800-Patches.com</option>
    
    	<option value="ga_merchants.php?op=info&amp;id=7">1-800-PetMeds.com</option>
    	<option value="ga_merchants.php?op=info&amp;id=8">1-800-Wheelchair.com</option>
    
    ....
    
    <div id="ga_merchants_info"></div>
    You'll notice I'm using onChange for the select box instead of a submit button but I doubt that this is responsible for the problem, although I have not tested it with a button.

    Any ideas?
    Last edited by led_belly; 07-21-2006 at 07:44 PM. Reason: Fixing subject

  2. #2
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    30,495
    Thanks
    82
    Thanked 3,449 Times in 3,410 Posts
    Blog Entries
    12

    Default

    This is very non-standard looking:

    Code:
    ga_merchants.php?op=info&amp;id=1
    I'd try fixing that and similar first, that may take care of it. For example, it should look like so:

    Code:
    ga_merchants.php?op=info&id=1
    Additionally, it is not clear to me if the part where it says:

    id=1

    refers to an element's id or not. If by chance it does, use a letter as the first character for all id attributes of elements. Numbers are not allowed as the first character of an element's id.

    If the above suggestions don't help, at least try it with the submit button, as a test.

    There could be other problems and the best way to diagnose what those might be would be to have a link to your live page.
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •