Reputation: 1343
I am trying to unhide a panel client side by setting it's style. I initial setting for the style property is: display: none;
I am tying to unhide it with the following code:
var fileUploadPanel = dojo.byId("fileUploadPanel");
var fileUpload1 = dojo.byId("fileUpload1");
dojo.style(fileUploadPanel, "display", "block");
fileUpload1.focus();
But I get a javscript error style is null or not an object. Any idea why? the panel should have a style property correct?
Also as a follow up, I need to be able to hide that panel again with another button but it has to be SSJS. Anyway to do this?
Upvotes: 0
Views: 231
Reputation: 10485
Have you tried to use the client id instead?
dojo.byId("#{id:fileUploadPanel}");
var fileUpload1 = dojo.byId("#{id:fileUpload1}");
Upvotes: 4