Bill Effin Murray
Bill Effin Murray

Reputation: 436

Extending on DNN Users and Roles, possible?

The way I create my menus is causing a slight problem. I define the style in my style-sheet and create a module with html in it, here's an example of the HTML:

<ul class="cmenu">
    <li><a href="">Link1</a></li>
    <li><a href="">Link2</a></li>
    <li><a href="">Link3</a></li>
    <li><a href="">Link4</a></li>
</ul>

My reason being I need multiple menus through out the site all with different links (much more simple than using dnn:NAV with options) and it's working very well.

But trying to create a link to a user profile in this way doesn't seem possible. When visiting my user profile for example I am taken to this link: "../UserProfile/tabid/57/userId/1/Default.aspx" which means to me that DNN is dynamically creating the link and the page is created from the provided link. Please correct me if I'm wrong here.

Also I would like to create new input fields, how do I go about this?

I've been developing in PHP/HTML/CSS/JS for years now, ASP.NET is quite new to me and I couldn't find anything on the subject, thus my questions.

I'm very familiar with C# and Visual Studio, I would like to use these tools to extend on the current Users and Roles structure if possible.

Thanks in advance!!

Upvotes: 0

Views: 503

Answers (1)

Mitchel Sellers
Mitchel Sellers

Reputation: 63126

The URL for the profile is generated server side using the NavigateUrl method within the core.

To solve your HTML module issue in a primitive manner you could enable token replacement and use [User:UserID] as a token in the URL (Replace the 1 with the token in your example).

However, that doesn't work well for unauthenticated users as it will try to take them to -1. Honestly creating a menu might result you to create a custom module for it.

Upvotes: 1

Related Questions