Wednesday, October 30, 2013

Allow Indexing Page Settings and ROBOTS Meta in DotNetNuke

This is a single page settings that every DotNetNuke Admin should never forget.

This setting controls whether a page should be indexed by search crawlers. It uses the INDEX/NOINDEX values for ROBOTS meta tag.

It is located in:
Page Settings > Advance Settings > Other Settings

Monday, July 15, 2013

Example on how to use dnnConfirm jQuery Plugin

The JS code below will show a dnn confirm dialog upon click on any button with my-Button class.  Pay attention to isButton option on initialization and the isTrigger parameter on button click.

    text: "Confirm Message",
    title: "Confirm",
    isButton: true
//button click handler
$(".my-Button").click(function (e, isTrigger) {

    if (isTrigger) {
        // Your code here

    return false;


Friday, July 5, 2013

DotNetNuke+Apache Solr=High Speed Enterprise Search

We have successfully implemented Apache Solr as a Search Solution for DotNetNuke.

Here's the summary on how we did it.

First we installed BitNami Apache Solr Stack to our test machine(Windows 7).

We change the Solr Schema to fit our needs.  

We build a DNN Scheduler to add/edit/delete documents to Solr using Solrnet.

After we are done indexing,  we created a search class to query Solr Webservice using Solrnet.

Now we have an Intelligent and Fast Search. :)

FYI: Solr has a cool Dashboard that will let you check if your documents are being index properly or do some test query.

I will find time to share actual source code in the near future.


Sorting DotNetNuke List Using Linq

The code below will return a list of ListEntryInfo objects sorted by value in ascending order. :)

Dim lc As New DotNetNuke.Common.Lists.ListController()
Dim entries = From e In lc.GetListEntryInfoItems("ListName") Order By e.Value Ascending Select e

Wednesday, June 12, 2013

Check if Table Exist :TSQL

IF EXISTS (SELECT * FROM dbo.sysobjects WHERE id = object_id(N'TABLENAME]') AND OBJECTPROPERTY(id, N'IsTable') = 1)
-- Your code here

Friday, May 24, 2013

Another way implementing dnnConfirm

// Delete review button
    text: "Confirm Message",
    title: "Confirm Title",
    isButton: true
$(document).delegate(".Delete-Button", "click", function (e) {
    if (e.isTrigger) {
        //Your code here
    return false;

Monday, March 25, 2013

Disable tokeninput inside of Compose Message Dialog

I implemented DotNetNuke's dnnComposeMessage method/plugin in one of my module and I notice that other than the contact being pre-populated, users are also allowed to add/edit contact, this is great if you want it that way, however if you don't want users to change contacts other than what you already pre-populated, then we should disable it. I can't find a method inside of tokeninput plugin so I use CSS to hide the close icon and input control which in turn disable add or delete of contact during compose message dialog. Below is my CSS, using facebook theme.

.composeMessageDialog fieldset .dnnFormItem .token-input-input-token-facebook input { display: none; } .composeMessageDialog fieldset .dnnFormItem .token-input-delete-token-facebook { display: none; }