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...Administration ...Administration ...Logout Link in a Text/HTML Module for registrated UsersLogout Link in a Text/HTML Module for registrated Users
Previous
 
Next
New Post
9/30/2009 3:15 AM
 

Hello Folks,

I want a button everywhere on my DNN webpage in one of my defined containerareas where I can place modules like Text/HTML Module or Link Module.

First of all I search for the action code I must call, so that the user can logoff.
Here is the code:

javascript:__doPostBack('dnn$dnnLOGIN$cmdLogin','')

This code can then placed as content in the Text/HTML Module (important is to place this code in the Source view of the editor).

<span class="Normal">
<a href=" __doPostBack('dnn$dnnLOGIN$cmdLogin','')">
I want logout ...
</a>
</span>

Then you can config that only Registered Users can see the Text\HTML Module.

I use this on my own website and it works very fine: www.click-a-ticket.de

That's it ... Perhaps this tip save somebody some time.

_________________________
kostenlose Gewinne

 
New Post
9/30/2009 10:15 AM
 

You have to access an actual URL to log off, not the postback script you have above. 

Here is a sample:

http://localhost/testdnn494/Home/tabid/38/ctl/Logoff/Default.aspx?returnurl=%2fTestDNN494%2fdefault.aspx

In the example above you have the URL plus a redirect path to the page you want to send the user to after log off, however the return path is optional, but I recommend.

Here are the important parts:

The Website URL
http://localhost/testdnn494/

The Logoff Parameters (appended to the URL)
/Home/tabid/38/ctl/Logoff/Default.aspx
NOTE You can change the /Home/ to anything or even remove, your call.  Also the tabid can be a different number if you want, just so long as it is there.

The Return Path (Option but Recommended)
?returnurl=%2fTestDNN494%2fdefault.aspx
Again, this can be to any DNN Page... I have the example above redirecting to the home page.

So here is an Example using your sires URL
http://www.click-a-ticket.de/tabid/38/ctl/logoff/default.aspx?returnurl=%2fdefault.aspx
NOTE: TabId may differ in your installation.


Best Regards,

Robert J Collins | Co-Founder & President

Netlogic Corporation

 
New Post
9/30/2009 2:43 PM
 

Hi Robert,

thanx's for this solution, I try it out and change my code like in our example!

Ciao Totti

 

 
New Post
9/30/2009 7:35 PM
 

Let me know if it does not work for some reason.


Best Regards,

Robert J Collins | Co-Founder & President

Netlogic Corporation

 
New Post
10/1/2009 6:41 AM
 

Actually, you don't need all of the stuff with tabid's and the rest of the url.

The siteurls.config file contains a rewriting rule for the /logoff.aspx Url.

Thus you can just go http://www.domain.com/logoff.aspx and the logoff procedure will run.  This can be put anywhere as a simple Url.

 
Previous
 
Next
HomeHomeUsing DNN Platf...Using DNN Platf...Administration ...Administration ...Logout Link in a Text/HTML Module for registrated UsersLogout Link in a Text/HTML Module for registrated Users


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