Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

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

HomeHomeUsing DNN Platf...Using DNN Platf...Skins, Themes, ...Skins, Themes, ...Weird Jqeury IssueWeird Jqeury Issue
Previous
 
Next
New Post
9/18/2011 11:24 PM
 
I have a weird case on DNN 6.0.2

I put Jqeury directly in my skin: for example

$(document).ready(function() {
    $('.hide').hide();
});

It works when I'm logged in as host but once I logged out, the script does not run, although it is shown in the page source.

Also, how do I remove Jqeury UI from my skin? I don't need that....

Thanks,
George

Where to eat? Visit GoEatOut for Food Promotion in Kuala Lumpur.
 
New Post
9/19/2011 11:57 AM
 
Do you mean 5.0.2 or 6.0.1 ? 6.0.2 is not yet available.

It's likely a problem that jQuery is not being registered on the page. When you're logged in as an admin DNN automatically registers jQuery for all the admin functions so it is available.

Modules are suppose to register jQuery using DotNetNuke.Framework.jQuery.RegisterScript(Me.Page) Which will make sure that it is available when you are logged out. View Source and see if the jQuery.min.js is loaded. If it is then you are probably having a javascript error somewhere. If it's not then you can do one of the following things
  • Upgrade DNN. I believe the latest versions add jQuery to all pages by default.
  • Register jQuery manually
You can add this to the top of your Skin file:
<script runat="server">
    Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs)
DotNetNuke.Framework.jQuery.RegisterScript(Me.Page)
    End Sub
</script>

Sr. Software Engineer
 
New Post
9/20/2011 1:43 AM
 
Another option could be that the $ is not recognized because there might be an other script that is also using the $

I always use jQuery() instead of $() this has helped me with issues like these in the past

Also it is a good this to install webdevelper toolbar for firefox and bugzilla and see if you have errors appearing so you can pinpoint your problem a bit more
 
Previous
 
Next
HomeHomeUsing DNN Platf...Using DNN Platf...Skins, Themes, ...Skins, Themes, ...Weird Jqeury IssueWeird Jqeury Issue


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.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out