Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
How to create custom sections with custom page contains tree media picker?
I have problem from few days and I can't find solution nowhere.
I have developed custom section and custom aspx web page to umbraco.
In dashboard I reder web page which is placed in /umbraco/plugins directory.
In this page I need to choose image from Media, so I placed piece of code in my page (the lines on the end of my post).
The media tree is rendering ok, but if I pick some node (image) in tree, I receive javascript error:
"parent.opener.dialogHandler is not a function"
This line of code is dynamicaly placed in treeInit.aspx.
In this post: http://forum.umbraco.org/yaf_postst8389_Bj248rnbakks-MultipleContentPicker-in-v4.aspx
someone also have problem with it, but no solution. The solution proposed by acl123 not working.
Can you help? This is my last fuctionality which I would like develop..
Best regards Tim.
function chooseContentId() {
var treePicker = window.showModalDialog('<%=umbraco.cms.presentation.Trees.TreeService.GetPickerUrl(true,"media","media")%>', 'treePicker', 'dialogWidth=350px;dialogHeight=300px;scrollbars=no;center=yes;border=thin;help=no;status=no');
if (treePicker != undefined) {
document.getElementById("ctl00_ContentPlaceHolder1_tbxParentNodeID").value = treePicker;
if (treePicker > 0) {
umbraco.presentation.webservices.CMSNode.GetNodeName('<%=umbraco.BasePages.BasePage.umbracoUserContextID%>', treePicker, updateContentTitle);
}
function updateContentTitle(result) {
document.getElementById("contentTitle").innerHTML = "<strong>" + result + "</strong>";
hi.. i used the same kind of script..
when i select the particular folder.,it is not getting selected..
how to solve that
is working on a reply...
Write your reply to:
Upload image
Image will be uploaded when post is submitted
Custom sections with custom aspx page
How to create custom sections with custom page contains tree media picker?
I have problem from few days and I can't find solution nowhere.
I have developed custom section and custom aspx web page to umbraco.
In dashboard I reder web page which is placed in /umbraco/plugins directory.
In this page I need to choose image from Media, so I placed piece of code in my page (the lines on the end of my post).
The media tree is rendering ok, but if I pick some node (image) in tree, I receive javascript error:
"parent.opener.dialogHandler is not a function"
This line of code is dynamicaly placed in treeInit.aspx.
In this post: http://forum.umbraco.org/yaf_postst8389_Bj248rnbakks-MultipleContentPicker-in-v4.aspx
someone also have problem with it, but no solution. The solution proposed by acl123 not working.
Can you help? This is my last fuctionality which I would like develop..
Best regards Tim.
function chooseContentId() {
var treePicker = window.showModalDialog('<%=umbraco.cms.presentation.Trees.TreeService.GetPickerUrl(true,"media","media")%>', 'treePicker', 'dialogWidth=350px;dialogHeight=300px;scrollbars=no;center=yes;border=thin;help=no;status=no');
if (treePicker != undefined) {
document.getElementById("ctl00_ContentPlaceHolder1_tbxParentNodeID").value = treePicker;
if (treePicker > 0) {
umbraco.presentation.webservices.CMSNode.GetNodeName('<%=umbraco.BasePages.BasePage.umbracoUserContextID%>', treePicker, updateContentTitle);
}
}
}
function updateContentTitle(result) {
document.getElementById("contentTitle").innerHTML = "<strong>" + result + "</strong>";
}
hi.. i used the same kind of script..
when i select the particular folder.,it is not getting selected..
how to solve that
is working on a reply...