- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-03-2016
12:46 AM
10-03-2016
12:46 AM
How can I specify an custom template for an modal? I tried to specify the type and customTemplate, but no luck. The template file is called modal-gallery.html and is placed on the same path as the modal-popup.
var modalOptions = { type: 'gallery', customTpl: 'gallery' }; jQuery('<div />').modal(modalOptions).modal('openModal');
Solved! Go to Solution.
Labels:
1 ACCEPTED SOLUTION
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-03-2016
02:43 AM
10-03-2016
02:43 AM
I found the answer by myself. You need to define 'text!ui/template/modal/modal-gallery.html' as galleryTpl and use the modalOptions as below:
var modalOptions = { type: 'gallery', customTpl: 'gallery', galleryTpl: galleryTpl, };
1 REPLY 1
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-03-2016
02:43 AM