Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeDNN Open Source...DNN Open Source...Provider and Extension ForumsProvider and Extension ForumsAuthenticationAuthenticationDNN with new AD ProviderDNN with new AD Provider
Previous
 
Next
New Post
5/25/2009 4:18 PM
 

I have upgraded DNN to 05.00.01 and applied the AD provider 5.0.1 and this script no longer works anymore.

I can login using the DOMAIN\UserName but the users are now used to not having to do that.

Any ideas?

<

script runat="server"> change(ByVal sender As Object, ByVal e As EventArgs)

Select

Case txtUsername.Text

Case

"admin"

Case

"host"

Case

Else

 

If txtUsername.Text.StartsWith("UCMASHERS") Then

 

'The user added the wrong domain information

 

If txtUsername.Text.Contains("/") Then

txtUsername.Text = txtUsername.Text.Replace(

 

Else

"/", "\")End If

 

'The user didn't enter the domain so add it for them

txtUsername.Text =

 

End

End

</

String.format("UCMASHERS\{0}", txtUsername.Text)End If Select Subscript>

Cheers,

Tim

Sub

 
New Post
5/26/2009 12:39 AM
 

Where have you got that script Tim? In the login.ascx for the AD Provider? Did you remember to make the change to txtUsername object (I don't have the script handy or the URL for the post that it's originally in).

 
New Post
5/29/2009 9:14 AM
 

Yep, updated the login.ascx and did adjust the txtUsername object.

 

Here is the full code of the login.ascx file.

 

<%@ Control language="vb" Inherits="DotNetNuke.Authentication.ActiveDirectory.Login, DotNetNuke.Authentication.ActiveDirectory" AutoEventWireup="false" Explicit="True" Codebehind="Login.ascx.vb" %>
<%@ Register TagPrefix="dnn" Assembly="DotNetNuke" Namespace="DotNetNuke.UI.WebControls"%>
<%@ Register TagPrefix="dnn" TagName="Label" Src="controls/LabelControl.ascx" %>

<script runat="server">

Sub change(ByVal sender As Object, ByVal e As EventArgs)

Select Case txtUsername.Text

Case "admin"

Case "host"

Case Else

   If txtUsername.Text.StartsWith("UCMASHERS") Then

      'The user added the wrong domain information

      If txtUsername.Text.Contains("/") Then

         txtUsername.Text = txtUsername.Text.Replace("/", "\")

      End If

Else

      'The user didn't enter the domain so add it for them

      txtUsername.Text = String.format("UCMASHERS\{0}", txtUsername.Text)

   End If

End Select

End Sub

</script>

<table cellspacing="0" cellpadding="3" border="0" summary="SignIn Design Table" width="160">
 <tr>
  <td colspan="2" class="SubHead" align="center"><dnn:label id="plUsername" controlname="txtUsername" runat="server" text="UserName:"></dnn:label></td>
 </tr>
 <tr>
  <td colspan="2"  align="center"><asp:textbox id="txtUsername" ontextchanged="change" columns="9" width="130" cssclass="NormalTextBox" runat="server" /></td>
 </tr>
 <tr>
  <td colspan="2" class="SubHead" align="center"><dnn:label id="plPassword" controlname="txtPassword" runat="server" text="Password:"></dnn:label></td>
 </tr>
 <tr>
  <td colspan="2" align="center"><asp:textbox id="txtPassword" columns="9" width="130" textmode="password" cssclass="NormalTextBox" runat="server" /></td>
 </tr>
    <tr id="trCaptcha1" runat="server">
     <td colspan="2" class="SubHead" align="center"><dnn:label id="plCaptcha" controlname="ctlCaptcha" runat="server" text="Password:"></dnn:label></td>
    </tr>
    <tr id="trCaptcha2" runat="server">
     <td colspan="2" align="center"><dnn:captchacontrol id="ctlCaptcha" captchawidth="130" captchaheight="40" cssclass="Normal" runat="server" errorstyle-cssclass="NormalRed" /></td>
    </tr>
    <tr>
     <td id="tdLogin" runat="server" colspan="2" align="center"><asp:button id="cmdLogin" resourcekey="cmdLogin" cssclass="StandardButton" text="Login" runat="server" /></td>
    </tr>
</table>

 

 

Thanks,

Tim

 
Previous
 
Next
HomeHomeDNN Open Source...DNN Open Source...Provider and Extension ForumsProvider and Extension ForumsAuthenticationAuthenticationDNN with new AD ProviderDNN with new AD Provider


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out