This is a migrated thread and some comments may be shown as answers.
Using relative URLs for content
1 Answer 60 Views
This is a migrated thread and some comments may be shown as answers.
PaulMrozowski
Top achievements
Rank 1
PaulMrozowski asked on 19 Aug 2012, 07:30 PM
I have the following:
$("#newBatchWindow").kendoWindow({               
    width: "425px",
    height: "375px",
    title: "New Batch",
    visible: false,
    resizable: false,
    modal: true,
    content: "/Batch/Create"
});

However, when this window is activated using this code, it fails on the call to center(), because batchWindow doesn't contain a reference.
var batchWindow = $('#newBatchWindow').data('kendoWindow');
batchWindow.center();
batchWindow.open();

If I modify the content field to be a full URL, things work as expected. How can I use a relative URL here?

1 Answer, 1 is accepted

Sort by
0
Daniel
Telerik team
answered on 23 Aug 2012, 06:05 AM
Hello,

The object will not be available if you are loading jQuery from the server with the window content. The problem will not occur when using a full URL because the Window will create an iframe. To use a relative URL you should either use the iframe option of the window or remove jQuery from the content you are loading.

Regards,
Daniel
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Asked by
PaulMrozowski
Top achievements
Rank 1
Answers by
Daniel
Telerik team
Share this question
or