DotNetNuke Hosting with ASPHostPortal.com

BLOG about DotNetNuke CMS, latest technology and Special DotNetNuke Hosting Package with ASPHostPortal.com

DotNetNuke 7.4.1 Hosting - ASPHostPortal.com :: How to Use the Text DotNetNuke Skin Object

clock Augustus 28, 2015 11:54 by author Kenny

How to Use the Text DotNetNuke Skin Object

DotNetNuke is a web content management system based on Microsoft .NET. The DNN Platform Edition is open source. DNN is designed for multi-tenancy and supports an unlimited number of websites, either as root websites or for portals in a parent-child configuration. The platform's skinning feature separates content from design-related files for easier customization. Skins make it simple to maintain a common look and structure across related sites without advanced programming knowledge. DNN's core functionality can be expanded with modules for common elements, such as those for e-commerce. The software enables parent-child website resource sharing and management using specially-formed symbolic links.

How to Use the Text DotNetNuke Skin Object

What is a Skin Object?

First of all, a skin object is an ASP.Net user control that is used in DNN skins to provide a limited feature.  For example, the search box, menu, login link, copyright statement, and more, are all skin objects.  They allow a skin designer to include dynamic content without having to know how to build the content itself, or knowing any programming.

Other than the previous description, this post will assume that you know how to create and package your own skin.

Text Skin Object

The Text skin object itself is a very useful feature in skinning, as it allows you to include localized text, while not having to create a copy of the skin for each language, or using any other number of workarounds.

For example, if you have static text next to your login skin object that says, “Welcome, “ then you might want to have alternatives for another language, if you plan to support it.

I am going to use that example for the rest of this post.

The Code

There is minimal code needed to implement the Text skin object.  If you’re using an HTML skin, then you would simply need to do the following:

<object id="dnnTEXT-Welcome" codetype="dotnetnuke/server" codebase="TEXT">
    <param name="Text" value="Welcome, " />
    <param name="CssClass" value="NormalBold" />
    <param name="ResourceKey" value="Welcome.Text" />
    <param name="ReplaceTokens" value="False" />
</object>

If you are using a ASCX skin, then you would need two updates.  First, put this line of code into the top section of the source:

<%@ Register TagPrefix="dnn" TagName="TEXT" Src="~/Admin/Skins/Text.ascx" %>

Next, put this code into the appropriate spot of the source in the skin:

<dnn:TEXT runat="server" id="dnnTEXT-Welcome" Text="Welcome, "
CssClass="NormalBold" ResourceKey="Welcome.Text" ReplaceTokens="False" />

Resource Files

Next, you need to make sure your skin has resource files.  In your skin package, you should have a folder namedApp_LocalResources.  This folder will contain the necessary files to tell your skin the appropriate text to use for the skin object when the specific language is asked for during page request life cycle.

If your skin file is named index.ascx or index.html, then your default resource file for English would be namedindex.ascx.resx.  If your additional supported language is French, your filename might be index.fr-FR.ascx.resx.

The English file code would be something like this:

<?xml version="1.0" encoding="utf-8"?>
<root>
  <data name="Welcome.Text">
    <value>Welcome, </value>
  </data>
</root>

The respective code for the French language file might look like this:

<?xml version="1.0" encoding="utf-8"?>
<root>
  <data name="Welcome.Text">
    <value>Accueil, </value>
  </data>
</root>

Text Skin Object Properties Explained

There are a few properties that you’ve seen in the previous examples that you might be wondering about.  Here is an explanation of those properties:

  • Runat – (required, ASCX only) The value must be ‘server’ 
  • Id – (required) This is a unique name for the tag, much like in standard HTML 
  • Text – (optional) This value will be used as the default, should an appropriate resources file for the current language not be found 
  • CssClass – (optional) This value is the name of a CSS class that will be available to the rendered HTML page to stylize the text in the web browser 
  • ResourceKey – (required) This value references the id (name) of the text to retrieve from the resources file 
  • ReplaceTokens – (optional) This true/false value will tell DNN to look for system tokens and replace them with the appropriate text


DotNetNuke Hosting With ASPHostPortal :: How to modify DotNetNuke Login Page? The Easy Way

clock Maart 16, 2015 05:42 by author Mark

The DNN login page is the most forgotten part in all DNN users and even some professional DNN portals like PokerDiy.com and neoteo.com. There are few modules that allow you to have a simplified login or pop up login like digg.com but you need to pay or it and it is not cheap and easy to change the design.
dnn-login-sample

In order to make changes to your DNN Login page, you have to understand the components in the login module. The DNN Login module consists of 4 parts which is the DNN Membership Authentication System, The Authentication Provider, The Login Module itself and the Language Resources Files (.resx).

The linkage of these components are as below:
Login Module loads Authentication Provider(s) into it and the provider as a gateway to the DNN Membership Authentication System. For example, if a user using LiveID to login your DNN Portal, the LiveID Authentication Provider redirect the user to MSN LiveID Gateway and then pass the credential back to your DNN Portal and match it with the DNN Membership Authentication System.

Login Structure

However, DNN Membership Authentication System also consist of Member Registration, Password Reminder and Forgot Password Question which makes the designing work on Login Works kinda tricky, not even need to mention the words that are loaded from the language resource files.
Ok, lets start changing those ugly interface! First we need to locate all the files that need to be changed. You will need to have FTP access to your DNN installation root.

Step 1: Changing the Login Module Container

The Login Module is basically the Admin’s Container by default where there is actually no login page but a “DNN Control” (Home/ctl/Login.aspx) unless you create a page and specified it in Admin > Site Setting > Advance Setting > Login Page.

Step 2: Locating Files that need to be changed

Now we need to locate the Login Authentication Providers at /DesktopModules/AuthenticationServices/ There will be 3 default providers which is DNN, LiveID and OpenID. You will find Login.aspx and Login.ascx.resx (under App_LocalResources) inside it and that are the files you are going to change it. For the DNN authentication files, you can get them at: /admin/Users/user.aspx and /admin/Authentication/login.aspx
Make sure you didn’t mixed up with login.aspx in providers.

Step 3: Changing the Text and Words

You can either change it using DNN Language editor which is located in Admin > Language in control panel are directly look for the files in FTP. I actually prefer the later method as it is more easier to read and modify using Visual Web Developer.
“Register” “Forgot and Password” at
/httpdocs/admin/Authentication/App_LocalResources/Login.ascx.resx
*If you have more than one portal, the file name will be “Login.ascx.Portal-0”

<data name="Remember.Text" xml:space="preserve">
     <value>Remember Login</value>
 </data>
 <data name="cmdForgotPassword.Text" xml:space="preserve">
    <value>Forgot Password ?</value>
 </data>
 <data name="cmdRegister.Text" xml:space="preserve">
     <value>Register</value>
 </data>

All you need to to change the text inside between the “value” attribute. I’d not recommend you to put html/css into it as it will increase the load time and may messing up xhtml coding standard…

Step 4: Changing the files.

First, we need to deal with the Login Tabs which is using the DNNTabStrip webcontrol. You can find this file at:
/httpdocs/admin/Authentication/Login.ascx
Inside the file, look for:

<DNN:DNNTabStrip
 ID="tsLogin"
 runat="server"
 TabRenderMode="All"
 CssTabContainer="LoginTabGroup"
 CssContentContainer="LoginContainerGroup"
 DefaultContainerCssClass="LoginContainer"
 DefaultLabel-CssClass="LoginTab"
 DefaultLabel-CssClassHover="LoginTabHover"
 DefaultLabel-CssClassSelected="LoginTabSelected"
 visible="false" />

The Css Classes are located at /Portals/_default/default.css by default. You can either change the css file, override it in skin.css / portal.css or redefine the classes in login.ascx
If you look at the pokerDIY login tabs, you will see that the tabs have been pushed into 2 lines which makes the layout very messy. You can simply widen it by changing the “width=160” to a larger number in the following lines and you will have the problem solved.

<asp:panel id="pnlLogin" runat="server" Visible="false">
     <table cellspacing="0" cellpadding="3" border="0" summary="SignIn Design Table" width="160">

Ok, now you have change the “Register” and “Forgot Password?” text but what about the design? For these, you need to look for “cssclass=”CommandButton” in the following lines located inside the same login.ascx.

<asp:Linkbutton id="cmdRegister" resourcekey="cmdRegister" cssclass="CommandButton" text="Register" runat="server"/>
 <asp:Linkbutton id="cmdPassword" resourcekey="cmdForgotPassword" cssclass="CommandButton" text="Forgot Password?" runat="server" />

We’ll leave the other parts of codes inside the file and CSS coding for a moment. Now we proceed to change another login.ascx which is located in:
/DesktopModules/AuthenticationServices/DNN.ascx
There are few basic things you need to change to make your login looks beautiful which are: The width, Label text/icon, login button, input box and the text inside it. You can find them in these lines:

<dnn:label id="plUsername" controlname="txtUsername" runat="server" resourcekey="Username" />
 <dnn:label id="plPassword" controlname="txtPassword" runat="server" resourcekey="Password" />
 <asp:textbox id="txtUsername" columns="9" width="150" cssclass="NormalTextBox" runat="server" />
 <asp:textbox id="txtPassword" columns="9" width="150" textmode="password" cssclass="NormalTextBox" runat="server" />
 <asp:button id="cmdLogin" resourcekey="cmdLogin" cssclass="DNNLogin" text="Login" runat="server" />

Like many others, you probably thought of removing the stupid help icon in the login page. It is simple if you’re only having a single language website version. All you need is to replace the <dnn:label to standard html code.
If you need to persevered the language resources function, you may substitute the dnn label control into standard asp label control as follow:

<asp:label id="plUsername" controlname="txtUsername" runat="server" resourcekey="Username" />

To change the textbox design as well as the font inside, simply look for <asp:textbox and change the cssclass value and thing applies to <asp:button for the login button.
After you’ve changed all the cssclass value in dnn.ascx, you may proceed to LiveID.ascx and OpenID.ascx using the same method.

Step 5: CSS Styling codes

Now we’ve reached into the hardest part where we need to use css to make a stylish login page. First, I would suggest you to put a new name for each of the value inside the CssClass attribute. This is because the default value are general classes which are shared with other modules and controls in the whole portal.

Best DotNetNuke Hosting Recommendation

ASPHostPortal.com provides its customers with Plesk Panel, one of the most popular and stable control panels for Windows hosting, as free. You could also see the latest .NET framework, a crazy amount of functionality as well as Large disk space, bandwidth, MSSQL databases and more. All those give people the convenience to build up a powerful site in Windows server. ASPHostPortal.com offers DotNetNuke hosting starts from $5/month only. We also guarantees 30 days money back and guarantee 99.9% uptime. If you need a reliable affordable DotNetNuke Hosting, we should be your best choice.



DotNetNuke Hosting With ASPHostPortal :: How To Setting up the DotNetNuke Blog Module

clock Maart 12, 2015 06:06 by author Mark

This article will walk you through this module and how to successfully configure it on a page within your DNN portal.This article assumes that you have downloaded and installed this version of the module in your website.  This article also discusses creating a blog that is to be used only by the individual configuring the blog, so you will want to login as the blog owner before continuing with this tutorial.  For this example we will be creating a blog for use by the “Admin” of the site.

Creating the Blog!

To get started we will add a new page and call it “Blog”, you complete this step by clicking the   icon in the control panel.  Input the following information for the blog page, or feel free to input your own specific information.
This creates a page that is visible to all users that will contain our blog.  Now, we will want to add an instance of the blog to this newly created page.  Select “Blog” from the list of available modules in the control panel and then select “Add”

Now right away you will notice that the blog module has now added a total of 5 new module displays to your page; most recent blog entries, blog list, new blog, search blog and blog archive.  We will work with each of the controls individually to properly configure the blog for display.

Lets start with the “New Blog” module, this is an administrative module that is used to manage the blogs that are part of the module so we will first want to change the display properties of this module to disable viewing by all users.  Hover over the action menu and select “Settings” to enter the module settings.  In the permissions section, uncheck the “Inherit View Permissions from Page” and ensure that no values are selected, then click “Update”.  The module should now show that it is only available for administrators.

This view control is the one that you will use to create and manage the properties for your blog and sub-blogs.  Once you have the view listed above click on “Create My Blog” to start the configuration of the blog module.  You will be presented with a “Create new Blog” page that will prompt you for various bits of information; each of these will be discussed below.

  • Title – This is the display title for your blog, it is displayed at the top of the entry listing and in the blog directory.  For this example we will call our blog “Test Blog”
  • Description – This is a short description to the purposes of the blog.  This content is displayed on RSS feeds and as general blog information..  For this example we will use the text “Demonstration blog description text”.
  • Blog Options – This section is a collection of checkboxes and looks like this, each setting will be discussed below.
  • Make this blog public – This option is used to make the blog visible to the public
  • Allow users to post comments – This allows registered users to post comments to your blog
  • Approval for user comments required – This option is only enabled for selection if user comments are allowed.  If enabled this option will prevent any comments from displaying publicly until they are approved
  • Allow anonymous users to post comments – this allows anonymous users to post comments to your blog
  • Approval for anonymous comments required – Just like the rule for user comments this adds an approval processes to the anonymous comments.
  • Allow Trackback Comments – This option allows users of other blogs to link back to your blog inputting a comment automatically
  • Approval for trackback comments – Just like the other items this will enable an approval process flow
  • Trackback auto discovery – This is a mode that will allow trackbacks to be discovered automatically
  • Send mail notifications - This option will send an e-mail notification to the blog owner after each blog comment and/or trackback
  • Use CAPTCHA for comments – This option will require the completion of a visual CAPTCHA before a comment can be submitted.

The final option in this section is the “When displaying your identity use” option.  This allows you to use either your username or full name as the identifying name for blog postings.
Typically when configuring modules we would enable comments for registered users without approval and for anonymous users with approval.  These will be the options that are selected for this tutorial.

  • Syndication Options – This collection of settings relates to RSS feeds and if/how they will be created.  Each option will be described below.
  • Syndicate this blog – If this is enabled the content for this blog will be introduced into an RSS feed
  • Syndicate independently – If this is enabled the blog will be syndicated as its own separate RSS feed.  You can use this with child blogs to prevent them from all being listed in 1 feed.
  • Managing Editor - This textbox is where you can put an e-mail address that should be listed as the managing editor for the RSS feed.  This is something that should be populated with a valid e-mail address as it provides a method for feedback and questions from consumers of the RSS feed.
  • Date and Time Options – These options are used to control how the dates and times are displayed in the blog.  This is where you select the time zone for your postings as well as your desired date format.  Below is an example of the default setting for US Central time.

Once you have gone through these settings you can skip past the “Child Blogs” section as this section is outside the scope of this article.  After clicking on “Update” your blog will be created.

Configuring your page layout

Now that we have created a blog it is a bit easier to see what each of these individual modules on our page are used for.  Lets take a bit of time to organize and discuss each of these modules.  The following steps will take you through a process to provide you meaningful information for each control as well as will give you instructions on how to rename the components to be more descriptive.

New_Blog

This control is the first control that we worked with an serves as an administration module, initially used to create the blog and eventually used to modify blog settings and to add new blog entries.  Typically renaming this module to “Administration” is helpful as it makes it easy to remember what its purpose is.  You can click in the module title to use the inline editor to change the name of the module.
It is also very common to move this module to the left pane to condense it’s display.  The module display provides you with three options.

Blog Settings

Clicking on this link will return you to the blog settings page that we used above to create your blog; you can use this to administer the various configuration elements of your blog.

View My Blog

Clicking on this link is the same as clicking your specific blog form the “Blog_List” module; it simply updates the “Most recent blog entries” window to show your blog listing.

Add Blog Entry

This is where you can make a new post to your blog.  You will be presented with an input screen that will provide you with fields for entry date, blog, title, summary, and blog.  Each of these fields are fairly self explanatory you can use these fields to control the CONTENT of your blog post.  You additionally have an “Entry Options” section where you can set options for your blog.  These items exist to allow you to “publish” a blog, to allow comments, and/or to display a copyright notice at the bottom of your blog posting.  Below is an example of these settings under their defaults
After you populate all values for the fields you may press “update” to actually make your new blog post!  It is that easy!

Blog_Archive

This module is a simple calendar that shows days that have blog posts and allow users to navigate the blog based on a date range.  Typically this module is renamed to “Archive” or something of that nature.  This is another control that for both space and usability is typically moved to the “RightPane” to allow it to display alongside the blog postings.  An example of the interface after modifying this control and the previous control is below.
As you can see we are starting to create something that looks more like a blog that you might expect to see.

Blog_List

This module is a control that allows users to select the various views from your blog.  They are presented options for “View All Recent Entries” which will display recent entries from any and all blogs and child blogs.  They are also given the ability to click on each individual blog and they will be displayed that information.  This is another control that condenses display very nicely and is deserving of a new name and location.  Typically this is found on the “LeftPane” of a site and is called “Navigation” or “Blogs” something a bit more descriptive to your users.
The action menu for this module provides you access to the “Blog Settings” page and “Add New Blog” pages.  This makes the “Administration” module unneeded for administration purposes now that you have created your blog.  Some individuals remove the module entirely but most just leave it for administration display.

Search Blog

This module is the search feature for the blog module itself allowing users to search for desired content, again this is a module that can condense to display in smaller areas and is typically located near the “Archive “ control as they are similar in function.  For this example we will rename it to “Search” and place it directly below the “Archive” module.
This module has no configuration options and provides users basic searching of blog content.

Most Recent Blog Entries

This module is the actual display control for the module that will show your blog posts to your users and allow them to view/leave comments.  The view of this specific module changes depending on how the other modules are configured.  You can view summary information for you blog postings and then drill down into the full detail display.
This module does have a configuration element that is accessible via the action menu by selecting “Module Options”.  These options apply to the blog module as a whole and will be discussed in two separate sections.

Basic Settings

These settings are basic settings that control the display of the blog and the input of content for the module.  Below are the default settings for this module.  They are all fairly self explanatory and are used to mostly limit the content to ensure that you have a proper display on your site for content length, search results length, and RSS feed length.

Advanced Settings

These settings are more advanced topics and relate to integration and other elements of the blog module.  Each of these values will be discussed below.

  • Allow Upload Options – Can blog posters upload items to their posting?
  • Show Blog Summary – Is the summary displayed when viewing the single blog detail?  Typically this is disabled as your summary is the first portion of your full blog post and it wouldn’t make sense to display it before the blog content.
  • Show unique title – If enabled this module will use a blog specific title to describe the content of the page.  For SEO this is a very good practice!
  • Personal Blog Page – If you want to display 1 and ONLY 1 blog on the page you can select the blog that is associated with the module here.  This essentially disables the function of the “Navigation”/”Blog_List” module discussed earlier and selects the given blog directly.
  • Enable DNN Search – This option is disabled by default.  If selected the module will use the ISearchable interface to provide the core DNN search engine with information about your blog postings.

Summary

After walking through this example you should now have a blog page that looks something like the following.

Best DotNetNuke 7.4 Hosting Recommendation

ASPHostPortal.com

ASPHostPortal.com is the leading provider of Windows hosting and affordable DotNetNuke Hosting. DotNetNuke Hosting from ASPHostPortal.com provides a safe, reliable and performance-driven foundation for your DotNetNuke website. DotNetNuke is the perfect Content Management System for managing and developing your website with one of ASPHostPortal’s Hosting plans. ASPHostPortal has ability to support the latest Microsoft and ASP.NET technology, such as: WebMatrix, WebDeploy, Visual Studio 2015, .NET 5/ASP.NET 4.5.2, ASP.NET MVC 6.0/5.2, Silverlight 6 and Visual Studio Lightswitch, ASPHostPortal guarantees the highest quality product, top security, and unshakeable reliability, carefully chose high-quality servers, networking, and infrastructure equipment to ensure the utmost reliability



DotNetNuke Hosting With ASPHostPortal :: Step by Step Process to Install The DotNetNuke (DNN)

clock Januarie 26, 2015 06:05 by author Mark

DNN Installation Process

  • Unzip the DNN file.
  • Rename
  • Make Two Folders in side UnZip folder
    • SQLExpress_DBFile
    • Website
  • Move all files inside the Website Folder except SqlExpressFolder.
    • Modify WebConfig.
  • Host it to IIS
    • Open IIS
    • Add new website (exp: DNNDEV.ME)
      • Site name :DNNDEV.ME
      • Provide physical path of dnn(Mark it to website folder under dnn folder)
      • Host name:DNNDEV.ME(same as site name)
  • After adding site you have to provide it permission:
    • Right click website folder > Edit permission > Security
    • Under Security click Edit > ADD > iis apppool\DC700X_DEV5 (your site name)
    • Allow it to All permission
  • Now add it to Host sites
    • Open notepad as Administration > File > Open > Brows (C > Windows32 > Systems > Drivers > host(Select all files) remove Read only permission
    • Now open Host and add 127.0.0.1 DNNDEV.ME (as per your ip and site name)
    • Now save and give it Read only Permission.

Make Data Base for dnn

  • Open SqlServer > Database(right click) >Add new DB > Paste here DNNDEV.ME(original site or host name as in IIS)
  • Open Database > Security > Logins (Create new user)
    • Login Name :DNNDEV.ME
    • Check Sql Server Authentication (nt Windows Auth)
    • Pas :Database,Confirm pass:Database
    • Make Enforce Password Policy Uncheck Then cilck > OK
  • Open DNNDEV.ME > Security > USers (right click) > New USer
    • User Name :DNNDEV.ME
    • Default Scheme : dbo
    • Select both chk to db_owner then click ok

Run DNN from IIS

  • Fill all field as per your back entrys.
  • Change Custom.

Now its running
Template Modify Process

Best Recommended DotNetNuke Hosting

ASPHostPortal.com

ASPHostPortal.com is the leading provider of Windows hosting and affordable DotNetNuke Hosting. DotNetNuke Hosting from ASPHostPortal.com provides a safe, reliable and performance-driven foundation for your DotNetNuke website. DotNetNuke is the perfect Content Management System for managing and developing your website with one of ASPHostPortal’s Hosting plans. ASPHostPortal has ability to support the latest Microsoft and ASP.NET technology, such as: WebMatrix, WebDeploy, Visual Studio 2015, .NET 5/ASP.NET 4.5.2, ASP.NET MVC 6.0/5.2, Silverlight 6 and Visual Studio Lightswitch, ASPHostPortal guarantees the highest quality product, top security, and unshakeable reliability, carefully chose high-quality servers, networking, and infrastructure equipment to ensure the utmost reliability.



DotNetNuke Hosting with ASPHostPortal :: How to Fix Problem DotNetNuke 7 Edit Button Not Work

clock Januarie 7, 2015 06:54 by author Mark

DotNetNuke 7 DNN Edit Button Will Not Work

After a clean install of DotNetNuke version 7.00.05, the Edit buttons would not work, and the page would repeatedly redirect to the homepage when clicking Edit. I did not experience this issue on installations which I upgraded.  I have uncovered three solutions which work, or at least work around, to solve the problem.

Method 1

One way to get around this problem is to use the Ribbon Bar instead of the Control Bar as the Control Panel setting. To make this change, navigate to the “Host” panel, click “Host Settings”, click the “Other Settings” tab. Set the “Control Panel” setting to “RibbonBar”.

Method 2

The second method, and one of the methods which actually solves the “ControlBar” issue, is to edit the web.config file. I found this solution at chaydigital. This method does work to solve the problem, but I have concerns about the waste of system resources it could cause as well as possibly creating other errors.
Open the web.config file in Notepad.exe or another editor. Find the system.webServer section, and change this section:

<system.webServer>
   <modules>
To this:
<system.webServer>
   <modules runAllManagedModulesForAllRequests="true" >

Method 3

Due to my concerns with placing a global fix in my web.config which might cause other errors to crop up, I decided to create two new installs on the same machine. One install was with the 7.00.05 full install package of DotNetNuke. The other install was with an older version of DotNetNuke 6 to which I applied the 7.00.05 upgrade. As suspected, in the full install website, the Edit button would not work. In the upgraded website, the Edit button worked as expected.
I decided to pull the two web.config files and compare them using a Powershell script. There were many differences in the two, but I found one difference in particular which seems to have solved my problem. The upgraded website had an entry for the FormsAuthentication module in the system.webServer section. and this entry was missing from the full install. This may be by design, I am not sure. But putting that entry in web.config on the full install version solved my issue.
Please attempt editing your web.config file at your own risk. Note that the system.webServer and modules nodes should already be there along with several other entries. The only entries you should add are in red type.

<system.webServer>
   <modules>
      <remove name="FormsAuthentication" />
     <add name="FormsAuthentication" type="System.Web.Security.FormsAuthenticationModule" preCondition="" />
</modules>
<system.webServer>

Hope this helps you. If you find additional solutions to the issue, let me know. I will gladly add them to the list.

 



DotNetNuke Hosting with ASPHostPortal.com :: GetTab Method without DNN Context

clock November 30, 2014 20:22 by author Mark

GetTab Method without DNN Context

As you know, the simple method GetTab(int tabid) was obsolete and has been replaced by GetTab (ByVal TabId As Integer, ByVal PortalId As Integer, ByVal ignoreCache As Boolean). If you want to call the new method, we have to pass the additional parameter “PortalId”.
In common,  the object PortalSettings can be easy to get with DNN context, such as special dnn module & page; however, it may be inaccessible in some sceneries, such as separate aspx page or handler. Then is there any way to get the correct tab info with this new method? Now there is a simple trick to do it with passing into Null.NullInteger as the parameter PortalId. So the coding looks like that:

var tabController = new TabController();
var blogPage = tabController.GetTab(tabID, Null.NullInteger, false);

Deeping into the source code, you will find out that it always tries to get the correct PortalId for this tab/page object:

//if we do not know the PortalId then try to find it in the Portals Dictionary using the TabId
portalId = GetPortalId(tabId, portalId);
//if we have the PortalId then try to get the TabInfo object
tab = GetTabsByPortal(portalId).WithTabId(tabId) ??
        GetTabsByPortal(GetPortalId(tabId, Null.NullInteger)).WithTabId(tabId);

Hope this trick & tip helps if someone has the same issue.

 



DotNetNUke 7.3 Hosting with ASPHostPortal.com :: TIPS Getting rid of spam users

clock November 18, 2014 06:14 by author Mark

Quick tips : Getting rid of spam users

After getting a couple of questions, I'd like to provide options for getting rid of spam users, which is cumbersome via UI, if thousands of registration have been added by a bot.
Unfortunately, it is not as easy as just deleting items from a single table, as user Information is distributed in multiple tables inside the database, therefore we need.
You are in a comfortable situation, if your site is using verified or private registration - in this case all spam users are unauthorized and you simply need to hit "delete unauthorized users" in Admin > User Accounts.
In all other cases, you will need to identify the users to delete from the database and mark as "deleted", in order to use "remove deleted users" (hard-delete) those users from all tables.

ALWAYS START WITH A DATABASE BACKUP!!

If your site only has a host and admin user you would run the following statement inside Host > SQL (check "run as script" in all DNN versions prior to 7.3):
UPDATE {databaseOwner}[{objectQualifier}UserPortals]
 SET   isDeleted = 1
 WHERE UserID NOT IN (SELECT UserID FROM  {databaseOwner}[{objectQualifier}Users
                                    WHERE isSuperuser = 1 OR UserName Like 'Admin')
If you may identify all users by registration date, e.g. since first of November, you would run
UPDATE {databaseOwner}[{objectQualifier}UserPortals]
 SET   isDeleted = 1
 WHERE UserID NOT IN (SELECT UserID FROM  {databaseOwner}[{objectQualifier}Users]
                                    WHERE isSuperuser = 1 OR UserName Like 'Admin' or CreatedOnDate < 2014-18-11)

Of course, this will become more difficult, if regular users registered the same time. You may consider creating a role "verifiedUsers" and move all regular users manually into this group. Now the command would look like


UPDATE {databaseOwner}[{objectQualifier}UserPortals]
 SET   isDeleted = 1
 WHERE UserID NOT IN (SELECT UserID FROM  {databaseOwner}[{objectQualifier}Users]
                                    WHERE isSuperuser = 1 OR UserName Like 'Admin' or CreatedOnDate < 2014-18-11)
   AND UserID NOT IN (SELECT UserID FROM {databaseOwner}[{objectQualifier}vw_UserRoles]
                                    WHERE RoleName Like 'verifiedUsers')


Afterwards you may use "Remove Deleted Users" link in Admin > User Management, to delete all rows.
For DNN Versions prior to DNN 7.3.1, you need to delete user folders manually, which reside nested inside users subfolder of the portal folder. Unfortunately, it is difficult to identify all folders from deleted users, but you may delete all empty folders without subfolder and files inside, as the folder for a still existing user will be re-created, once the user logs in again for the first time. You may use the following command (sing a command line on the server, while being inside the users folder)
for /f "delims=" %i in ('dir /ad /s /b') do @rd "%i"
Finally, you should enter file manager in DNN Admin menu and perform a recursive sync to get rid of all folder entries and folder permissions in the database



DotNetNuke 7.3 Hosting with ASPHostPortal.com :: DNN Spam Registrations

clock November 11, 2014 08:14 by author Mark

Introduction

Recently there has been a lot of discussion in the community around DNN Spam registrations and methods and processes to prevent or fix the issues that are associated with them.  I've been debating on if/when I should actually write about this given that there is an Official DNN Software response on the issue, as well as many other community comments.  Well, when I had a server go down and guess what it was because of this very issue so I think its time to give my quick perspective and recommended action points for those of you that are running a DNN site.  These recommendations apply for ALL DNN versions!

Update Registration Mode Setting

If possible, set your registration mode to "none" if you don't need public registration.  This is a great first defense.  If this isn't possible, then go with the next best step and that is to create a custom registration page.  If you do this, though make sure that you follow the instructions in the next step.

Optional: Add IIS Request Filtering

One of the recommended "stop gap" items that DNN Corporation recommends for those that cannot set registration to "none" is to set a filter in IIS for request filtering.  I STRONGLY recommend this solution and am rolling this out to ALL DNN sites that I manage or have any control over that need to allow user registration.  This will prevent the most basic backdoor used by these scripters which should at least help limit things a bit.

Post Change Investigation & Resolution

This is the key, the above changes are quick & easy, but it is the investigation that is key.  I'm writing this post because of the investigation and resolution that I had to do tonight while on vacation.  I had a server that went down, with a clients database that grew from 45mb to almost 1gb in 7 days, had a user count grow from 2 users to 197,000 users in that same 7 day period.  All of this happened silently, without stressing server resources, without setting off any DDOS alerts or anything.  How did it become an issue today?  The site owner tried to make a change and then it fell on its face.

So, given that this can be a silent threat to your site, what do you need to look for, and what actions can you take to fix?  Lets look at these next.

Do you have impacted Users?

If you are lucky, your site will not have any impacted users and you can stop here.  However, if you go to "Admin" -> "User Accounts" and see that you have 50,000 users when you should only have 10 you have some work to do.  This is the fastest way to look at things and identify what is going on.  If you have rogue users you will need to do two things to truly 'clean' your installation from these user accounts.

Delete the User Accounts

The first step in resolution is to get rid of the users that are impacting the site.  How you accomplish this is going to vary a bit.  If you have 5, 10, 20 SPAM users, just manually use the DNN delete features, but make sure to note the User Id value for each user.  If you have a lot of users, for example in my case more than 100K users to remove, you are going to want to investigate a scripting solution.

I will not post direct SQL here as you NEED to be a user with proper SQL knowledge to do this, but you can do this VERY fast and very clean within DNN.  Simply set all of the users that you need to remove to "Deleted" in the database, then use the "Remove Deleted Users."  Now, this process of having DNN remove the users might need to be repeated as there is a 30 second timeout on DNN database queries.  In my case it took 10 attempts to remove all.

Delete the Folders & Re-Sync Files/Folders

This is one area that is not often remembered by administrators with fake accounts.  Each user that is created in more current versions of DNN have a folder created for them inside of the users folder within DNN.  You will want ot go in and delete all of these folders from the filesystem.  Then once that is completed you will want to go to "Admin" -> "File Manager" and sync the filesystem.  This is imperative as more entries in the folders and permissions table will slow down areas of the site that interact with these tables.

Conclusion

We need to see what the final fix is for this issue, but in the meantime we need to be vigilant and keep our own sites as protected as possible.  Given the nature of this issue I am being a bit vague in recommendations as the exact solution isn't going to be the same for all users and sites.

 

 



DotNetNuke 7.3 Hosting with ASPHostPortal.com :: Skinning Responsively The DDR Menu with Bootstrap for DotNetNuke

clock Oktober 7, 2014 06:01 by author Ben

With all the introduction of the DDRMenu to DotNetNuke, we've experienced much more manage above what is rendered from the menu. This has authorized for a a lot more semantic menu and custom made styling for easy menus to mega menus. There are numerous methods to create the template that the DDR makes use of but we'll be using the token primarily based templating because it is quite easy.


Menu Template (Bootstrap Nav)

I copied the easy folder from your Gravity pores and skin that will come with DNN 7, which incorporates a manifest file “menudef.xml” and the “SimpleToken.txt” file. I updated the SimpleToken.txt file as follows:
Notice: this isn’t a tutorial on DDRMenu, just how to apply Bootstrap.

<ul class="nav nav-pills">
    [*>NODE]
    </ul>
    [>NODE]
        <li class="[?NODE]dropdown [/?][?SELECTED]active[/?]">
        [?ENABLED]
            <a href="[=URL]">[=TEXT] [?NODE]<b class="caret"></b>[/?]</a>
        [?ELSE]
            <a href="#">[=TEXT] [?NODE]<b class="caret"></b>[/?]</a>
        [/?]
        [?NODE]
            <ul class="dropdown-menu">
            [*>NODE]
            </ul>
        [/?]
        </li>
    [/>]

  1. Add the classes nav and nav-pills to the outer ul. Individually, I favor the simplicity in the Simple tablets nav that bootstrap gives. This appears to be the easiest to override with my own custom design and style as I have a tendency to use more flat UI’s in my style.
  2. Include the category “dropdown” for the list merchandise if it's youngsters using the [?NODE] examination.
  3. Add the category “active” for the listing product whether it is selected utilizing the [?SELECTED] examination.
  4. Add a caret to the merchandise if it's a baby item.

Up coming, we are able to include the HTML and pores and skin object within the pores and skin as follows:


Logo and Menu pores and skin objects (Bootstrap Navbar)

<div class="navbar">
        <div class="navbar-inner">
            <span class="brand">
                <dnn:LOGO runat="server" id="dnnLOGO" />
            </span><!--/Logo-->
            <dnn:MENU MenuStyle="Simple" runat="server"></dnn:MENU>
        </div><!-- END navbar-inner -->
    </div><!-- END navbar -->


  1. add link with class “btn” and btn-navbar”. Also, requires markup for collapse. You are able to use either JavaScript or information attributes.
  2. Wrap dnn:MENU pores and skin item using a div using the adhering to class
    “nav-collapse” and “collapse” - this permits the menu to break down at smaller display screen sizes
    “pull-right” to drift the menu to the correct side, if you so desire.

 

Note: making use of this process will disable a menu merchandise which has children. In order that this is a click to open up motion. This can be to make things function much better for contact units.



DotNetNuke 7.3 Hosting with ASPHostPortal.com :: The Simple Way to Install DotNetNuke

clock September 17, 2014 09:18 by author Kenny

The Simple Way to Install DotNetNuke

DotNetNuke is a Web-content management platform for those who use the Microsoft ASP.NET framework. Based on your company needs, whatever version of DNN you choose, it will be a significant cost saving venture over other options. Installing DotNetNuke is not a task well-suited for beginners to this sort of website framework. If you are familiar with websites, databases, and ASP.NET, you can use these instructions to learn how to install DotNetNuke.

Check the DotNetNuke installation requirements before getting started. To install DotNetNuke, you need a database with either Microsoft SQL Server 2005/2008 or SQL Express. If you have an older version of DotNetNuke 5.2 or earlier, you can use SQL Server 2000. You should also have a Microsoft IIS (Internet Information Services) with version 5 or higher, and the Microsoft .NET 3.5 SP1 framework. This service pack is available through the Windows Update feature.

Download the latest version of DotNetNuke to your computer, and unzip the file.

Use the FTP software of your choice to connect to your website, and upload the installation files into the directory of your choice. If necessary, create the directory where you want to install DotNetNuke on your server.

Select the folder where DotNetNuke is located. Click "Properties," choose the "Security" tab, and add the necessary user permissions. Use either the local ASP.NET service (for Windows 2000 and XP) or the local Network Service account (for Windows 2003, Vista, 2008, or 7). You should have permission to modify the folder.

  • Open the IIS server console. Go to "Start" > "Run" > INETMGR. Click on the "websites" node, and select the "Default website" node.
  • Right click on the DotNetNuke folder. Click "Convert to Application." If this option is not available, select "Properties" and add the application.

Install DotNetNuke with SQL Express.

  • Open your web browser, and go to: http://yoursite.com/dotnetnuke.
  • Walk through the installation wizard as presented on the screen. The database information should already be configured, and you should not need to change it.
  • Look for the default login information for the "host" and "admin" users, which is shown when installation is complete.
  • Log in immediately, and change the passwords to protect against hacking.

Install DotNetNuke with SQL Server 2005/2008 for your database server.

  • Open SQL Management Studio, and connect to your database server.
  • Walk through the installation wizard as presented on the screen.
  • Create a new database by expanding the server node, then the databases node, and filling in necessary values for all the database properties.
  • Set up the SQL user and security account, and choose the appropriate integrated-security or user-security setting under the "server/security" node.
  • Open your web browser, and go to: http://yoursite.com/dotnetnuke.
  • Walk through the installation wizard as presented on the screen. Choose SQL 2000/2005/2008, and follow the security steps according to the option chosen in the previous steps. Test the database connection.
  • Finish the installation wizard, and look for the default login information for the "host" and "admin" users.
  • Log in, and immediately change the passwords for those accounts to protect against a hack.

Best and Cheap DotNetNuke Hosting Provider

Are you looking for best and cheap DotNetNuke Hosting Provider? ASPHostPortal is the answer. ASPHostPortal.com is a windows-based hosting service provider. ASPHostPortal.com offers the most reliable and stable DotNetNuke 7.3 web hosting infrastructure on the net with great features, fast and secure servers. Our hosting can be done via USA, Amsterdams or Singapore based server. Depending on your requirements, we can scale so we can deliver the right service for the right price. All of our windows hosting plan supports DotNetNuke 7.3 and you can install DotNetNuke 7.3 with just one click.



About ASPHostPortal.com

We’re a company that works differently to most. Value is what we output and help our customers achieve, not how much money we put in the bank. It’s not because we are altruistic. It’s based on an even simpler principle. "Do good things, and good things will come to you".

Success for us is something that is continually experienced, not something that is reached. For us it is all about the experience – more than the journey. Life is a continual experience. We see the Internet as being an incredible amplifier to the experience of life for all of us. It can help humanity come together to explode in knowledge exploration and discussion. It is continual enlightenment of new ideas, experiences, and passions

Author Link


 photo ahp banner aspnet-01_zps87l92lcl.png

Corporate Address (Location)

ASPHostPortal
170 W 56th Street, Suite 121
New York, NY 10019
United States

Tag cloud

Sign in