Products

Solutions

Learn More

Partners

Community

Blog

About

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeDevelopment and...Development and...Building ExtensionsBuilding ExtensionsModulesModulesDisplay module on all pages AND set Display Container Unchecked for all?Display module on all pages AND set Display Container Unchecked for all?
Previous
 
Next
New Post
12/22/2017 12:38 PM
 

...

Dear DotNetNuke Pro Developers --

Please help, with a question about including an HTML Module on all pages and replicating the Settings in all instances of that module.

Display module on all pages AND set Display Container Unchecked for all?

Here is the scenario that I am dealing with now, and I know there are other (perhaps better?) ways to do this, but this is how it is currently done, so I would like to make this work better if possible.

We are using DotNetNuke 8.0.3 here, and cannot upgrade yet.

We are using the Xcillion Theme everywhere, by default.

We have a bit of JavaScript that we want included on all pages.

We added an HTML Module added to the bottom of the Home page.

We set Display Module On All Pages to be Checked.

We switched to Source view, removed all visual elements, added a script block with our common JavaScript and saved it.

It works as we want, and the JavaScript is available on all pages.

But, the Module should be 100% invisible and instead the little Module title bar separator visual element (which is part of the Xcillion Theme) shows up for the Module, on all pages. Ug. We need to remove that.

So, we went in to the Module Settings and set "Display Container" to "Not Checked" (where it was checked by default) and that made the title bar separator disappear for this Module. Great. That is what you want.

But...

This "Display Container = Not Checked" setting does NOT automatically propagate to all instances of this Module, so we have had to go into each page and set the Module properties.

Yes, I restarted the DotNetNuke app via Tools, I cleared the app Cache via Tools, I cleared the browser cache, I ran iisreset, etc, but those changes do not propagate.

This is kind of Ok, since we have just a small number of pages, but is there a way to set "Display Container = Not Checked" on 1 page and (since it has "Display On All Pages = Checked") have that setting propagate to all instances of the "shared" Module?

What do you think? Is there a way to do this? Is there a better (and equally simple) way to share JavaScript across all pages?

Please advise.

Thanks.

-- Mark Kamoski

...
 
New Post
12/26/2017 3:50 PM
 
Mark,

Putting Javascript like that on every page, it would be easier to simply add the javascript into the SKIN files, but you can definitely do it with a module as well.

Here's what I recommend.

1) Add the module to the page
2) Configure the Javascript
3) Configure the module settings (save the settings)
4) Check the box for Display on all pages after you've done Step 3

If you do step #4, before Step #3 you'll have to go through and remove the module from all the pages.
a) Navigate to a page with the module on it
b) Edit the module settings
c) Uncheck the display on all pages check box
d) Go to the recyle bin and empty all the deleted modules
e) Configure the display of the module, container, javascript, etc.
f) Recheck the display on all pages check box

Chris Hammond
Former DNN Corp Employee, MVP, Core Team Member, Trustee
Christoc.com Software Solutions DotNetNuke Module Development, Upgrades and consulting.
dnnCHAT.com a chat room for DotNetNuke discussions
 
New Post
1/1/2018 10:38 PM
 
DisplayContainer is a TabModuleSetting, i.e. a setting per module reference.
If you want to apply it to all references of a module instance, you may use the following SQL statement in Host > SQL:
UPDATE {databaseOwner}[{objectQualifier}TabModuleSettings]
SET SettingValue = "false"
WHERE ModuleID = [myModuleID] -- replace [myModuleID] with the ID of the module from module settings.

Cheers from Germany,
Sebastian Leupold

dnnWerk - The DotNetNuke Experts   German Spoken DotNetNuke User Group

Speed up your DNN Websites with TurboDNN
 
New Post
1/24/2018 6:37 PM
 
@sebastian, I appreciate the help, I can only "accept as answer" to 1 post, so I just wanted to say "thank you" to you directly here. Thanks!
 
New Post
1/25/2018 10:39 AM
 
Mark,

for this use case I use the Injection Module by Will Strohl - you can inject scripts and other stuff with this, and it is not visible for anyone except administrators and users who have the permission to edit the module.

https://github.com/hismightiness/dnne...

Happy DNNing!
Michael

Michael Tobisch
DNN★MVP
dnn-Connect.org - The most vibrant community around the DNN-platform
 
Previous
 
Next
HomeHomeDevelopment and...Development and...Building ExtensionsBuilding ExtensionsModulesModulesDisplay module on all pages AND set Display Container Unchecked for all?Display module on all pages AND set Display Container Unchecked for all?


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.

Content Layout

Subscribe to DNN Digest

Subscribe to DNN Digest

DNN Digest is our monthly email newsletter. It highlights news and content from around the DNN ecosystem, such as new modules and themes, messages from leadership, blog posts and notable tweets. Keep your finger on the pulse of the ecosystem by subscribing.  

What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out