Results 1 to 5 of 5

Thread: Ajax Tabs Content Script don't work on firefox 3

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

    Unhappy Ajax Tabs Content Script don't work on firefox 3

    1) Script Title: Ajax Tabs Content Script (v 2.2)

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

    3) Describe problem: Hello,

    i modified the codes in external2.htm as below
    Code:
    This is the contents of "external2.htm"<br />
    This is the contents of "external2.htm"<br /><br />
    This will open <a href="javascript: countries.expandit(2)">tab no 3</a><br />
    so that user can click on the "tab no 3" link to open the tab no 3. This modication work very well in IE 7. But i have problem with Firefox ver 3. The FF refuse to do anything at all. Why FF no response at all?

  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

    I still use FF 2. Check the error console in FF 3 though. Also, are you sure you have javascript enabled? Do you have a problem with the demo page on DD in FF 3?
    - John
    ________________________

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

  3. #3
    Join Date
    Jul 2008
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    i don't have any problem with the demo page on DD in FF 3. javascript enabled.

    no error message in error console in FF 3. seem like nothing happen when click on the link inside external2.htm.

  4. #4
    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

    How is external2.htm being imported? If via iframe, it shouldn't work in any browser. However, the construction:

    Code:
    <a href="javascript: countries.expandit(2)">
    has never been the best idea, as it tells the browser to start unloading the page. Generally this has only been a problem in a few specific instances in IE, at least that I am aware of, and may have nothing to do with your problem. Still, I would try:

    Code:
    <a href="javascript: countries.expandit(2)" onclick="countries.expandit(2);return false;">
    This overrides the href and executes the onclick event without telling the browser to start the unload process.

    Other than those two things (the import method and the execution syntax), the only other thing I can think of is that somehow FF 3 is stripping all script code from imported content, or perhaps even just refusing to parse it as script code (this could perhaps even be a setting in the browser doing one of these things). My second idea may help with that, as it is at least valid HTML.
    - John
    ________________________

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

  5. #5
    Join Date
    Jul 2008
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Thumbs up

    You're right!

    Your overrides the href and executes the onclick event without telling the browser to start the unload process, do the trick.

    Code:
    <a href="javascript: countries.expandit(2)" onclick="countries.expandit(2);return false;">
    FF3 working like charm now! Why i never think of that, silly i!

    Thank you!

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
  •