0

how can I load HTML code in separated HTML file into dialog in another file. when I click into anchor in one.html page, dialog appears containing HTML code exist in another HTML page.

I didn't make the code that appear in the dialog in the same page, because I will use this code into another places.

1
  • So, do you need to use ajax to load the external HTML? Commented Jul 19, 2011 at 0:00

1 Answer 1

1

you can read your code using ajax

jQuery.get('second.html', function(html){
    $('#dialog').html(html).dialog();
})

This should work using jQuery and jQuery UI for dialog

Hope this helps

Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.