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

HomeHomeUsing DNN Platf...Using DNN Platf...Skins, Themes, ...Skins, Themes, ...Changing Login/Logout link to a button?Changing Login/Logout link to a button?
Previous
 
Next
New Post
12/7/2007 9:43 AM
 

I'm sure there is a way to do this, I'm just not sure how.  I have the standard style of login link in my skin:

<dnn:USER runat="server" id="dnnUSER" /> <span class="Skinobject">|</span> <dnn:LOGIN runat="server" id="dnnLOGIN" />

I want to change that to show up as a button instead of a link, is there an easy way of doing this?

 

 
New Post
12/7/2007 10:15 AM
 

Hi Dan,

you have to update the ascx file Login.ascx at \admin\skins\

you will see there one hyperlink control

<asp:hyperlink id="hypLogin" runat="server" cssclass="SkinObject" enableviewstate="False"></asp:hyperlink>

now you have two options either to do that using css setting. or you can have your image button in between the starting tag and end tag of this hyperlink control

<asp:hyperlink id="hypLogin" runat="server" cssclass="SkinObject" enableviewstate="False"><img src="/images/btn_login.gif" border="0"></asp:hyperlink>

same for the other skin object dnnUser but at the file User.ascx which exist at the same folder

try it

 
New Post
12/7/2007 1:35 PM
 

I don't see those lines...

Here is what I have in the login.ascx file:

<%@ Control language="vb" AutoEventWireup="false" Explicit="True" Inherits="DotNetNuke.UI.Skins.Controls.Login" CodeFile="Login.ascx.vb" %>
<asp:LinkButton ID="cmdLogin" runat="server" cssclass="SkinObject" CausesValidation="false"></asp:LinkButton>

 

 
New Post
12/8/2007 5:01 AM
 

 You don't have to change the login.ascx (which would affect all portals in your DNN installation), if you set the Text and LogoffText attributes of the <dnn:LOGIN skin object with HTML instead of pure text:

Text='<img src="logon.gif">

If you want to use image files from your skin directory, there's a little trick I learned from Erik van Ballegoij in this thread (thanks again, Erik!), which makes the image path portable:

Text='<%# "<img src=""logon.gif"">" %>'

 
New Post
12/8/2007 12:18 PM
 

Modifying the Login.ascx is not recommended because it would affect all portals throughout your dnn instance (as xws-mika mentioned) and your changes would no longer be available once you upgrade to the newer version of dnn.

My recommendation for this is to set different CSS classes for your LOGIN and LOGOFF token. By doing this, you will have more control with styling and make your button with a hover state a different image.

Hope this helps!


Cuong Dang
Co-founder: Enliven, dnnGallery
LinkedIn | Twitter
I'm the author of DNN and Web Standards Wrox Blox

 
Previous
 
Next
HomeHomeUsing DNN Platf...Using DNN Platf...Skins, Themes, ...Skins, Themes, ...Changing Login/Logout link to a button?Changing Login/Logout link to a button?


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