Results 1 to 4 of 4

Thread: Ajax Tabs Content Script (v 2.2)

  1. #1
    Join Date
    Mar 2009
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Ajax Tabs Content Script (v 2.2)

    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:

    Hi i am trying to use ajaxtabs and SexyLightBox2 on the same page.

    SexyLightBox initalises in the head like this:

    Code:
    <script type="text/javascript">
      window.addEvent('domready', function(){
        new SexyLightBox();
        new SexyLightBox({find:'sexywhite',color:'white', OverlayStyles:{'background-color':'#000'}});
      });
    </script>
    when i load a new content using AjaxTabs the SexyLightBox links in the new content wont work, while SLB links on the rest of the page works fine (i would expect that).

    So how can i re-initalise the above code when using AjaxTabs to load new content into a DIV?(i guess this would be a problem for any script that get initalised in the head)

    thank you very much for any assistance.


    NB. i realise that this is a multiple script question, but i think it is a basic javascript question as well, and i am new to this and just looking for some assistance.
    Last edited by atomic; 03-19-2009 at 01:33 PM. Reason: editing

  2. #2
    Join Date
    Mar 2009
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    I've been trying for quite a while now and i still dont have the answer, any good samaritans?

    I would have thought this would be a no-brainer for Javascript-gurus

  3. #3
    Join Date
    Mar 2009
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    i found a solution that might help you, however im not sure why it doesnt do it as it should.

    i basically used the explicit javascript command on the href.

    e.g.

    <a href="javascript: blah.loadajaxpage('some_file.php')">TEXT LINK</a>


    blah being the thing you specified in the below script

    <script type="text/javascript">

    var blah=new ddajaxtabs("nav", "holder")
    blah.setpersist(true)
    blah.setselectedClassTarget("link") //"link" or "linkparent"
    blah.init()

    </script>

    hope this helps,

    Andy.

  4. #4
    Join Date
    Aug 2009
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default loadajaxpage used with a form submission

    Can this work in a form? I'm not having any luck with it.



    <FORM name="form1" action="javascript: countries.loadajaxpage('/addlink.asp')" enctype="multipart/form-data" method="post">

    I'm trying to open this page in the same tab container it starts from, but it doesn't seem to be working at the moment.

    Anyone have any ideas?

    Thanks!

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
  •