I am using JQuery colorbox like that: There is a link(with a button) that has a class cboxElement. The html of colorbox is at that link, I mean at another JSP file. When user click that link colorbox appears and everything is OK.
However how can I use colorbox for something within my page between div tags I mean without writing another JSP file that will be non-visible for users and it will appear after a user clicks a button)?
EDIT: I found that: If inline ‘true’ a jQuery selector can be used to display content from the current page. Example:
$("#inline").colorbox({inline:true, href:"#myForm"});
I think this is what I am looking for but I couldn’t find any example of it?
Take a look at the example for inner HTML on this page. I believe that is what you’re looking for.
If you look at the source of the page, you’ll find this HTML:
This is the link that launches ColorBox on click:
This is the binding for ColorBox: