AjaxControlToolkit fixes

As great as the AjaxControlToolkit is, it still contains a couple of (big) annoyances. The good thing is, that you can change the source-code yourself. So here it is, the changes I need to remember, when I do another custom build of the AjaxControlToolkit.

TabControls
The TabControl has the annoyance, that on Internet Explorer, a small rectangle of the tab is not displayed. Adding the following lines to the web page or changing the TabControl stylesheet Tabs.css will solve the problem:

<style type="text/css">
.ajax__tab_xp .ajax__tab_tab
{ height: 21px; }
</style>

ModalPopupExtender
Why should the ModalPopupExtender actually work on Microsoft's own browser? Well it does, as long as the DOCTYPE of the web page is set correctly (meaning transitional). But when IE is in quirks mode, the popup shows up centered to the top left corner, and when scrolling, the page gets larger and larger, because the background element created, to prevent clicks on other elements is moved down. Thanks to this great blog entry.   

  • Change the function 'getClientBounds' in common.js. In the browser switch, change the IExplorer part:
  • 	
    switch(Sys.Browser.agent) {
    case Sys.Browser.InternetExplorer:
    if (document.documentElement && document.documentElement.clientWidth)
    clientWidth
    = document.documentElement.clientWidth;
    else if (document.body)
    clientWidth
    = document.body.clientWidth;
    if (document.documentElement && document.documentElement.clientHeight)
    clientHeight
    = document.documentElement.clientHeight;
    else if (document.body)
    clientHeight
    = document.body.clientHeight;
    break;
  • Change the function 'initialize' in ModalPopupBehavior.js. Replace the lines

    this._backgroundElement.style.position = 'fixed';
    ...
    this._foregroundElement.style.position = 'fixed';

    with

    this._backgroundElement.style.position = 'absolute';

    ...
    this._foregroundElement.style.position = 'absolute';

  • To get the background element hiding all the links and other elements on the web page, you'll need to give it a separate CSS stylesheet (BackgroundCssClass) and just use a transparent image for the background. That's it.
    		.PopupBackground { background:url(spacer.gif); }
    	
Digg It!DZone It!StumbleUponTechnoratiRedditDel.icio.usNewsVineFurlBlinkList

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Compatibility Regex

To prevent the installation of a DotNetNuke module on a not supported version of DotNetNuke, you can set the compatibility regex in the module definitions. In the following case, I want the module to be installed on every version of DotNetNuke equal or bigger than 04.08.00. This lead me to the following regex: ^04.0[8-9]{1}.[0-9]{2}|04.[1-9]{1}[0-9]{1}.[0-9]{2}|0[5-9]{1}.[0-9]{2}.[0-9]{2}|[1-9]{1}[0-9]{1}.[0-9]{2}.[0-9]{2}$ It will grab possible versions of 04.10.00 up to versions 99.99.99. But I wonder if the module will still work on .NET 2042...
Digg It!DZone It!StumbleUponTechnoratiRedditDel.icio.usNewsVineFurlBlinkList

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Versions in InnoSetup

Using the InnoSetup preprocessor, you can automatically give the setup file the same version as the program file you're packaging with InnoSetup. Predefined functions are

  • GetFileVersion, e.g. 3.3.3117.29914
  • GetFileProductVersion, e.g. 3.3.0.0

Additionally, you can add the following macro to your InnoSetup script found here. It supports only single digit version numbers though.

; ; Inno Setup Preprocessor macro to simplify the version string. ; ; The following situations are covered: ; ; (1) 1.2.4.3 -> 1.2.4 ; (2) 1.2.4.0 -> 1.2.4 ; (3) 1.2.0.0 -> 1.2 ; (4) 1.0.0.0 -> 1.0 ; (5) 1.0.0.2 -> 1.0 ; (6) 1.3.0.1 -> 1.3 ; #define SimpleVersion(str S) \ Local[0] = Pos (".0.0.", S), \ /* (4) and (5) */ \ (Local[0] > 0) ? Copy (S, 1, 3) : \ ( \ Local[0] = Pos (".0.0", S), \ /* (3) */ \ (Local[0] > 0) ? Copy (S, 1, 3) : \ ( \ Local[0] = Pos (".0", S), \ /* (2) */ \ (Local[0] > 5) ? Copy (S, 1, Local[0] - 1) : \ ( \ Local[0] = Pos (".0.", S), \ /* (6) */ \ (Local[0] > 0) ? Copy (S, 1, 3) : \ ( \ Copy (S, 1, 5) \ ) \ ) \ ) \ );

and then use that macro to define the version

#define MyAppVersion   SimpleVersion(GetFileVersion("app.exe"))

Digg It!DZone It!StumbleUponTechnoratiRedditDel.icio.usNewsVineFurlBlinkList

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Ping Services

We are using the following pingservices.xml file for BlogEngine.NET.

<?xml version="1.0" encoding="utf-8" standalone="yes"?> <services> <!-- Wikipedia: Open Ping Servers --> <service>http://rpc.weblogs.com/rpc2</service> <service>http://ping.blo.gs/</service> <!-- Wikipedia: Aggregators --> <service>http://api.blogblogs.com.br/api/ping</service> <service>http://bulkfeeds.net/rpc</service> <service>http://ping.feedburner.com</service> <service>http://blogsearch.google.com/ping/RPC2</service> <service>http://rpc.icerocket.com:10080/</service> <service>http://rpc.technorati.com/rpc/ping</service> <service>http://api.my.yahoo.com/RPC2</service> <service>http://api.my.yahoo.com/rss/ping</service> <!-- Wikipedia: Multi-Pinging services --> <service>http://pinger.blogflux.com/rpc</service> <service>http://blogpinger.de/</service> <service>http://www.kping.com/</service> <service>http://ping.in/</service> <service>http://pingoat.com/</service> <service>http://rpc.pingomatic.com/rpc2</service> <service>http://mohanjith.net/pnp</service> <!-- Various --> <service>http://www.bloglines.com/ping</service> <service>http://services.newsgator.com/ngws/xmlrpcping.aspx</service> <service>http://xping.pubsub.com/ping/</service> <service>http://xmlrpc.blogg.de/</service> <service>http://api.moreover.com/RPC2</service> <service>http://ping.weblogs.se/</service> <service>http://www.weblogues.com/RPC/</service> <service>http://coreblog.org/ping</service> <service>http://ping.myblog.jp</service> <service>http://ping.bloggers.jp/rpc</service> <service>http://ping.bitacoras.com</service> <service>http://ping.weblogalot.com/rpc.php</service> <service>http://bblog.com/ping.php</service> <service>http://blog.goo.ne.jp/XMLRPC</service> <service>http://effbot.org/rpc/ping.cgi</service> <service>http://mod-pubsub.org/kn_apps/blogchatt</service> <service>http://ping.exblog.jp/xmlrpc</service> <service>http://ping.syndic8.com/xmlrpc.php</service> <service>https://phobos.apple.com/WebObjects/MZFinance.woa/wa/pingPodcast</service> <service>http://www.blogdigger.com/RPC2</service> <service>http://www.blogoole.com/ping</service> <service>http://www.blogoon.net/ping</service> <service>http://www.blogshares.com/rpc.php</service> <service>http://rpc.blogrolling.com/pinger</service> <service>http://www.blogpeople.net/servlet/weblogUpdates</service> <service>http://www.wasalive.com/ping/</service> <service>http://www.popdex.com/addsite.php</service> <service>http://rpc.blogbuzzmachine.com/RPC2</service> <service>http://www.bitacoles.net/ping.php</service> <service>http://www.focuslook.com/ping.php</service> </services>

Digg It!DZone It!StumbleUponTechnoratiRedditDel.icio.usNewsVineFurlBlinkList

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Install BlogEngine.NET in a virtual directory underneath a DotNetNuke installation

If you want to install BlogEngine.NET or any other web application in a virtual directory (or subdirectory) underneath a DotNetNuke installation, you'll have to make sure, that the configuration settings of DotNetNuke are not inherited by BlogEngine.Net. In order to prevent this, you need to change the web.config file of DotNetNuke and surround the <system.web> part with the following tag:

<location path="." inheritInChildApplications="false"> <system.web> ... </system.web> </location>

Digg It!DZone It!StumbleUponTechnoratiRedditDel.icio.usNewsVineFurlBlinkList

Currently rated 5.0 by 1 people

  • Currently 5/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Missing Login on Login Page

If the username and password textboxes don't show up on the login page of a BlogEngine.NET installation, you probably have uncommented the following line in the BlogEngine.NET web.config file:

<add name="CleanPageModule" type="BlogEngine.Core.Web.HttpModules.CleanPageModule, BlogEngine.Core"/>

Comment this line out again, and it will work. 

Digg It!DZone It!StumbleUponTechnoratiRedditDel.icio.usNewsVineFurlBlinkList

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5