My Blog

Author:Philip BeadleCreated:Monday, September 15, 2008 10:40 AM
This blog is more general than my Blog at http://www.dotnetnuke.com/Community/Blogs/tabid/825/Default.aspx. You'll find mostly technical tips and tricks and things i am doing in the MS user group community.

In case you aren’t aware (or you’ve forgotten) you might be interested to know that Readify are conducting a series of free events for developers covering the various new .NET technologies.  No strings attached, no sales pitches.  Just our way of contributing to the local developer community.
 
It’s a great opportunity for you to get your head around some of the new stuff coming out of Redmond, and even if you can’t use it for your current projects it makes for some good professional development time J
 
These events get under way in a few weeks so it might be worth having a think about which ones are of interest to you and registering.
 
For a bit more of a run down on why we’re doing it have a look at Greg Low’s blog entry.
 

You can also see the calendar of events on the Readify site.  The first one is my session October 2, 3 and 4 on Silverlight.

 

Jon Flanders will come down under, 13-16 November 2007 to Melbourne to deliver his 4 day Applied WF intensive course which affords experienced .NET developers training in WF tools and services needed to add rich workflow capabilities to their ASP.NET and Smart Client applications as well as Web and Windows services.
For More information and to book your place http://www.readify.net.au/Default.aspx?tabid=281 or email training@readify.net.au

Juval Lowy is returning to Australia by popular demand to deliver his best-of-breed WCF Master Class from 15-19 October 2007 in Sydney. This 5 day intensive course covers WCF programming, design guidelines, pitfalls, original techniques and best practices.
For More information and to book your place http://www.readify.net.au/Default.aspx?tabid=241 or email training@readify.net.au

Just made it to Star Contributor on ASP.Net after countless hours of moderating and posting.

asp.net star contributor

So next target is an All Star....

I have been using more and more CSS in my designs lately and decided to do an all CSS form.  This worked fine for normal labels and text boxes but when I used the DotNetNuke label control the form got all messed up.  This is because the DNNLabel has a hidden div with a break in it that messed up the layout.  So to get around this I developed the form like this:

<div id="inputform">
<
fieldset>
    <legend>Person of Interest</legend>
    <div class="dnnlabel">
        <dnn:Label ID="lblLastName" ControlName="txtLastName" ResourceKey="lblLastName" runat="server" />
    </div>
    <asp:TextBox ID="txtLastName" runat="server" TabIndex="2"></asp:TextBox>
    <asp:RequiredFieldValidator ID="rfvLastName" runat="server" ErrorMessage="Last name is required."
        Text="*" ControlToValidate="txtLastName" CssClass="NormalRed"></asp:RequiredFieldValidator><br />
    <div class="dnnlabel">
        <dnn:Label ID="lblFirstName" ControlName="txtFirstName" ResourceKey="lblFirstName"
            runat="server" />
    </div>
    <asp:TextBox ID="txtFirstName" runat="server" TabIndex="3"></asp:TextBox>
    <asp:RequiredFieldValidator ID="rfvFirstName" runat="server" ErrorMessage="First name is required."
        Text="*" ControlToValidate="txtFirstName" CssClass="NormalRed"></asp:RequiredFieldValidator><br />
    <div class="dnnlabel">
        <dnn:Label ID="lblDateOfBirth" ControlName="txtDateOfBirth" ResourceKey="lblDateOfBirth"
            runat="server" />
    </div>
    <asp:TextBox ID="txtDateOfBirth" runat="server"></asp:TextBox>
    <asp:RequiredFieldValidator ID="rfvDateOfBirth" runat="server" ErrorMessage="Date of birth is required."
        Text="*" ControlToValidate="txtDateOfBirth" CssClass="NormalRed"></asp:RequiredFieldValidator>&nbsp;<asp:HyperLink
            ID="cmdDOBCalendar" CssClass="CommandButton" runat="server" TabIndex="4" >[cmdDOBCalendar]</asp:HyperLink><br />

</fieldset>

</div>

With the corresponding CSS:

#inputform/* set width in inputform, not fieldset (still takes up more room w/ fieldset width */
 font:100%;
 font-family: Tahoma, Arial, Helvetica;
 margin: 0;
 padding: 0;
 min-width: 500px;
 max-width: 600px;
 width: 560px;
 text-align:left;
}
 
#inputform fieldset {
 /* clear: both; note that this clear causes inputs to break to left in ie5.x mac, commented out */
 border-color: #000;
 border-width: 1px;
 border-style: solid;
 margin-top:10px;
 padding:20px;
}
 
#inputform fieldset legend {
      font-size:1.1em; /* bump up legend font size, not too large or it'll overwrite border on left */
                       /* be careful with padding, it'll shift the nice offset on top of border */
}
 
.dnnlabel {
      display: block/* block float the labels to left column, set a width */
      float: left;
      width: 150px;
      padding: 0;
      text-align: right;
      margin-right:10px;
      margin-top:5px;
}
 
.inputspan
{
}
 
#inputform input, textarea, select {
      /* display: inline; inline display must not be set or will hide submit buttons in IE 5x mac */
      width:auto;      /* set width of inputform elements to auto-size, otherwise watch for wrap on resize */
      margin-top:5px;
}
 
#inputform br {
      clear:left; /* setting clear on inputs didn't work consistently, so brs added for degrade */

}

This gives a nicely laid out form with not a table in sight.

 

 

 

 

After my last post I got a response from Joseph Sak.  Joseph told me that I could achieve the same outcome of the

div.float-clear {
   clear: both;
   height: 0px;
   overflow: hidden;
}

<div class="float-clear">div>

by simply adding overflow: hidden; to the parent div of the one with the floating divs.  I tried this out and voilà you get the same effect without having to add the extra div to clear the floats.

So now I have changed the HTML to this

<div class="float-clear">
        <div id="links">
            <a class="SkinObject>Home> | 
            <a class="SkinObject>Contact Us>
        div>
        <div id="user">
            Content goes here
        div>
div>

and the CSS now looks like this

div.overflow-hidden{
 
   overflow: hidden;
}

Less markup for the same effect.

I have been building some new skins using CSS to do the layout.  This is a bit of a challenge but worth it once you get the hang of it.  One of the neat tricks I learnt from Damian Edwards is that when you float a div this can behave differently in IE and Fire Fox.  So a good way to get the divs to behave is to add a clearing div like this:

Add this to your CSS

div.float-clear {
   clear: both;
   height: 0px;
   overflow: hidden;
}

and then add a div like this

<div class="float-clear"></div>

just inside the enclosing div like this

<div>
        <div id="links">
            <a class="SkinObject>Home</a>&nbsp;|&nbsp;
            <a class="SkinObject>Contact Us</a>
        </div>
        <div id="user">
            Content goes here
        </div>
        <div class="float-clear"></div>
</div>

The links and user divs are floated in the CSS and the float-clear div makes the layout work correctly in Fire Fox.

To get my fixed width site design to be centre aligned I used two methods together.  For Fire Fox i used

<div id="pagecontent" style="width:1003px; margin:0px auto 0px auto;">And for Internet Explorer i used

#pagemaster
{
 
      text-align:center;
}

in the CSS file.

So there you have it how to make your CSS layouts behave perfectly in both IE and FF.

 

I wanted to make sure everyone knew that the DotNetNuke crew are putting on our first ever conference in Las Vegas in November this year.  We have a site up here http://www.openforce07.com
This event will be the first time that there is an official DotNetNuke conference and as you would expect we have secured all of the top DotNetNuke practitioners from around the world including yours truly.  We are “Super Excited” (Microsoft over used termJ) about this as it shows that DNN has really matured as a product, eco system and community.  As an added bonus attendees also get complete access to DevConnections which will have lots of the cancelled PDC contentJ.  And as an even better added bonus you can win a Harley Davidson as well and we all know how I feel about that!
There are 24 sessions over 3 days that cover Skin Design, Module Development, Site Administration and panel discussions on Open Source and other interesting subjects.  Its cool having a surname starting with B as Im on top of the speakers list too.
So hope to see you there!!!!

All you need to do is set the spellCheck="IeSpellCheck"  in the web.config

<add name="Ftb3HtmlEditorProvider" type="DotNetNuke.HtmlEditor.Ftb3HtmlEditorProvider, DotNetNuke.Ftb3HtmlEditorProvider" providerPath="~\Providers\HtmlEditorProviders\Ftb3HtmlEditorProvider\" toolbarStyle="Office2003" enableProFeatures="false" spellCheck="IeSpellCheck" />

Today i had to increase the amount of content shown in one of the RSS feeds on www.readify.net.  The feed is from our Media Centre announcements list and it was being truncated to 100 characters which was not what we wanted.  So I increased the Description Length setting on the module and re-indexed the content.  No joy, I was still getting the same output, so I added a new item and tried again and got the desired output. 

So now i had to figure out how to get rid of the existing indexed content in the search system so i could start fresh.

So I ran

delete from searchword

delete from searchitem

against the database and re-indexed a couple of times to make sure it hadnt timed out before completing.  Now I get up to 2000 characters in my RSS feed .

  
DNN Template Maker

Artisteer - Web Design Generator

  
UsersOnline
MembershipMembership:
Latest New UserLatest:Ian
Past 24 HoursPast 24 Hours:0
Prev. 24 HoursPrev. 24 Hours:0
User CountOverall:29

People OnlinePeople Online:
VisitorsVisitors:8
MembersMembers:0
TotalTotal:8

Online NowOnline Now:
  
Talk to me
  
Good Books
My Logos


MVP Logo
From: 2004-2009

Lorraine Young's DNN Site

DotNetNuke Sponsor and Platinum Benefactor logo

 Microsoft ASP.net logo

microsoftcertifiedprofessional.gif

vicnet_logo.gif