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

HomeHomeArchived Discus...Archived Discus...Developing Under Previous Versions of .NETDeveloping Under Previous Versions of .NETASP.Net 2.0ASP.Net 2.0EditUrl() vs. Globals.NavigateURL()EditUrl() vs. Globals.NavigateURL()
Previous
 
Next
New Post
11/15/2007 2:03 PM
 

Maybe somebody here can explain this behavior to me. I am debugging through the code-behind of my module and I use my immediate window:

Globals.NavigateURL("Edit")
"http://localhost/dnn2/VLTest/tabid/55/ctl/Edit/Default.aspx"
EditUrl("Edit")
"http://localhost/dnn2/VLTest/tabid/55/ctl/Edit/mid/371/Default.aspx"
EditUrl()
"http://localhost/dnn2/VLTest/tabid/55/ctl/Edit/mid/371/Default.aspx"

Shouldn't Globals.NavigetURL() return the same thing as EditUrl() when you pass the same control key to each??

 

 
New Post
11/16/2007 10:32 AM
 

No, EditUrl will return a URL that is designed to show JUST the current module, thus the addition of the mid/371 portion in your example above.

Both links though do work, due to DNN's handling of controls


-Mitchel Sellers
Microsoft MVP, ASPInsider, DNN MVP
CEO/Director of Development - IowaComputerGurus Inc.
LinkedIn Profile

Visit mitchelsellers.com for my mostly DNN Blog and support forum.

Visit IowaComputerGurus.com for free DNN Modules, DNN Performance Tips, DNN Consulting Quotes, and DNN Technical Support Services
 
New Post
11/16/2007 10:55 AM
 

Hi Mitch,

I am pointing this out because only the EditUrl method works for me. NavigateURL("controlkey") does not work for ANY control key i give it. Now I do have Friendly URLs turned on, would that make a difference?

Rafe

 
New Post
11/16/2007 11:18 AM
 

Did you make sure you set the control key correctly in the module definition? see: NavigateURL: How to make a link (VB &C#)



Michael Washington
http://ADefWebserver.com
www.ADefHelpDesk.com
A Free Open Source DotNetNuke Help Desk Module
 
New Post
11/16/2007 11:44 AM
 

Yes, the control keys are set correctly. In fact they work great when I use EditUrl("controlkey").

To use the code from your tutorial as an example, what I am seeing is that:

Response.Redirect(Globals.NavigateURL(PortalSettings.ActiveTab.TabID, "mygallery", "mid=" & Cstr(ModuleID)))

will take me the control w/ key "mygallery", but

Response.Redirect(Globals.NavigateURL("mygallery"))

takes me to a blank page that doesn't contain my control.

It is clear from looking at the NavigateURL source that the "mid=" part is not added in like when you use EditUrl. I am curious though to know what the intended behavior is for the NavigateURL(ByVal TabID As Integer) method, because it doesn't work for me as expected.

 
Previous
 
Next
HomeHomeArchived Discus...Archived Discus...Developing Under Previous Versions of .NETDeveloping Under Previous Versions of .NETASP.Net 2.0ASP.Net 2.0EditUrl() vs. Globals.NavigateURL()EditUrl() vs. Globals.NavigateURL()


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