Wednesday, 10th March 2010     Good Afternoon Register | Login  
MODULES
MODULES
SKINS
SKINS
NEWS
NEWS
FORUMS
FORUMS
FEEDBACK
FEEDBACK
SEARCH GO

MENU
 
 
  Print   

ADS
 
 
   


ADS
 
 
   

CODE LIBRARY
 
 

Current Articles | Categories | Search | Syndication

Tuesday, June 06, 2006
MinMax persistance type of cookie requires a moduleId
By SuperUser Account @ 12:26 PM :: 1486 Views :: 0 Comments ::
There have been numerous posts on DNN forums about this error message. 

MinMax persistance type of cookie requires a moduleId

The most common reason related specific to DNN 4 custom module development is possible a typo:
 
A typo or mismatch between the DesktopModule/<custom module folder> and ControlSrc field in the DNN ModuleControls table. 

A solution is to copy the folder name and paste it directly into the database ControlSrc field.
Wednesday, March 29, 2006
Enabling ISS Compression in IIS6
By SuperUser Account @ 1:46 PM :: 1587 Views :: 0 Comments ::

This article refers to Windows Server 2003 which without a doubt offers the best platform for running ASP.NET available. Turning on the compression built into IIS6 allows you to save valuable bandwidth and improve load times of both static and dynamic ASP.NET content.

IIS Compression in IIS6

  • From the IIS snap-in, right-click on the Web Sites node and click on Properties.
  • Select the Service tab - Enable Compress application files.
  • Enable Compress static files.
  • Change Temporary Directory to the folder that you created above, or leave it at it's default
  • Set the max size of the temp folder to something that the hard drive can handle. i.e. 1000
  • Save and close the Web Site Properties dialog

Note: The temporary compress directory is only used for static pages.  Dynamic pages aren't saved to disk and are recreated every time so there is some CPU overhead used on every page request for dynamic content.

Compressible Content

If you are using Windows 2003 Server and enable compression in IIS6, you'll have compression enabled, but it will still be non-functional for ASP.NET! 

The reason for this is that the ASP.NET file extension (.aspx) is not set as a valid compressible file extension in the Metabase file.

To edit the servers ‘Metabase’ find the \Windows\System32\inetsrv\MetaBase.xml and using your preferred text editor make the following changes.  Under ‘IIsCompressionScheme’ there are two XML elements, one used for deflate and the other for gzip.  Both elements have properties called ‘HcFileExtensions’ and ‘HcScriptFileExtensions’ which contain a space-delimited list of file extension for compressible content.  You will need to add ‘aspx’ to the ‘HcScriptFileExtensions’ list and any other file type you wish to compress.  Beware as certain media types do not compress as desired.

Note: if the properties for ‘HcScriptFileExtensions’ are left blank, then all content, regardless of file extension, will be compressed.

One further issue

The following step is only required unless you find compression isn't working even after completing the ‘Metabase’ changes.

  1. Open the IIS admin tool.
  2. Expand your server > right-click on "Web Service Extensions". Select "Add a new web service extension" (for the extension name, use whatever name desire as the identifier in the list)
  3. Add a single required file if missing (the ISAPI file responsible for ‘.gzip’ and deflate compression is \Windows\System32\inetsrv\gzip.dll)
  4. Make sure the "Set extension status to allowed" is checked
  5. Click OK.

You should now have a new web service extension of your selected name in the list with a status set to "Allowed".

Testing Tools

There are a number of testing tools available to monitor page load speeds and compression which will have to be the subject of another article!

 

Saturday, March 25, 2006
ControlType value chart
By SuperUser Account @ 12:38 PM :: 1182 Views :: 0 Comments ::

Reference chart for the module ControlType used in the ModuleControls table.

ControlType

Value

Skin Object

-2

Anonymous

-1

View

0

Edit

1

Admin

2

Host

3

The ControlType value sets the modules state when viewed.

Sunday, March 12, 2006
Why can't I move my module to another page?
By SuperUser Account @ 2:58 AM :: 1138 Views :: 0 Comments ::

Whenever you attempt to move a module to another page the request is ignored.  There have been a number of posts explaining it could be down to a core framework bug, but the most common reason is very simple once you track down the cause!

This is a common mistake in a number of third party and even core modules!  The only modules that show this behaviour utilize a settings page that Inherits ModuleSettingsBase.

The reason the module will not move is because of the following code:

Public Overrides Sub UpdateSettings()

    Try

    'Your update code....

    'Code causing problem....
    Response.Redirect(NavigateURL())

    
End Try
        Catch exc As Exception
    End
Try

End
Sub


Removing the Redirect code allows the parent Module Settings page to handle the redirect, suddenly the module starts to behave as it should!

 

Sunday, March 12, 2006
XML createElement inserting xmlns="" on child elements. How do I stop this?
By SuperUser Account @ 2:39 AM :: 1263 Views :: 0 Comments ::

This happens when the document you are working is using namespaces, but new nodes are being created using the non namespace-aware DOM level 1 functions.

In this case DOM assumes they are in the "empty" namespace, and correctly inserts this namespace declararation. Use createNode instead, specifying the proper namespaceURI for the new element (it knows about namespace handling).

For example if you need to add a new node to the system.web of our portals web.config file.

VB Example Code:

Private Sub buildNode(ByRef InnerNode As XmlNode)

Dim xmlDoc As New XmlDocument

Dim attribute1 As XmlAttribute = Me.xmlDoc.CreateAttribute("name")

            attribute1.Value = "HTTPHandler_MyModule"

            Dim attribute2 As XmlAttribute = Me. xmlDoc.CreateAttribute("type")

            attribute2.Value = "MyCompany.DNN.Modules.ModuleName"

            Dim node1 As XmlNode = Me. xmlDoc.CreateNode(XmlNodeType.Element, "add", "http://schemas.microsoft.com/.NetConfiguration/v2.0")

            node1.Attributes.Append(attribute1)

            node1.Attributes.Append(attribute2)

            InnerNode.AppendChild(node1)

End Sub

This will take care of any empty and unneeded xmlns="".

  Print   

Google Analytics
 
 
  Print   

     
Copyright 2005 - 2009 24DNN.com   |  Terms of Use  |  Privacy Statement
DotNetNuke
DotNetNuke
[ Join Now | Ring Hub | Random | << Prev | Next >> ]
Page generated in 0.125 seconds.