Small width layout Medium width layout Maximum width layout Small text Medium text Large text
     Search
Downloads Downloads Directory Directory Forums Forums Forge Forge Blogs Blogs        Marketplace Marketplace Careers Program Careers
Community › Forums Register  |  

AppTheory specializes in solutions based on the DotNetNuke platform and has 2 employees on the DotNetNuke Core Team.
  Need Help?  
Professional technical support for DotNetNuke is available from DotNetNuke Corporation.
 


  Ads  
 


  Sponsors  

Meet Our Sponsors

Red-Gate Software
MaximumASP
SourceGear - Tools for Developers
.: CounterSoft :.
telerik
ExactTarget email software solutions
 


DotNetNuke Forums
 
  Forum  DotNetNuke® Pro...  Documents Modul...  Use of portal:url control
Previous Previous
 
Next Next
New Post 5/17/2007 1:40 AM
User is offline Alessandro
1 posts
10th Ranked


Use of portal:url control 

I am a very beginner of DNN and am trying to create a module using the portal:url control. I have a couple of easy questions (not for me):

1) Speficying an existing File (URLType=F) I get URL="FileID=20"

how do I get the file in order to use it in the module?  How do I get the file name corrsponding to FileID=20 ?

2) How is it possible not to show the details like Track Number, Log the users Open Link...  ?

Thanks

Alessandro

 
New Post 2/12/2008 6:18 AM
User is offline Dario Rossa
249 posts
dotnetnuke.dariorossa.it
9th Ranked




Re: Use of portal:url control 

Hi Alessandro,

To the first question, here is my answer: you should catch the url coming out of the urlControl and format it before storing it to the database. I resolved this way:

Dim ImageUrl As String = ""
Select Case MyUrlControl.UrlType
  Case "F"
    Dim ImageFileId As Integer = Integer.Parse(MyUrlControl.Url.Substring(7))
    Dim objFileController As New FileController
    Dim objImageInfo As DotNetNuke.Services.FileSystem.FileInfo = objFileController.GetFileById(ImageFileId, PortalId)
    ImageUrl = PortalSettings.HomeDirectory & objImageInfo.Folder & objImageInfo.FileName
  Case "U"
    ImageUrl = urlImage.Url
End Select

In addition, check this post:

http://forums.asp.net/p/873170/986848.aspx

Answering the second question, you can manage it in your control.ascx file with:

<dnn:URL ID="MyUrlControl" runat="server" FileFilter=".jpg,.gif"
            ShowFiles="true" ShowTrack="false" ShowLog="false" />

Hope it helps,

Dario Rossa.


Dario RossaDario Rossa
Personal WebSite: http://www.dariorossa.it
DotNetNuke: http://dotnetnuke.dariorossa.it
 
New Post 2/13/2008 6:20 AM
User is offline Mitch Sellers
5575 posts
www.mitchelsellers.com
3rd Ranked




Re: Use of portal:url control 

Another option to get the file path, to avoid the direct file path is to use the following method.

DotNetNuke.Common.

Globals.LinkClick("FileId=20", this.TabId, this.ModuleId)


-Mitchel Sellers
MCITP, MCPD, MCTS
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 Consulting Quotes, and DNN Technical Support Services

I reccomend 3Essentials for shared hosting and BaseCamp for project management
 
New Post 6/7/2008 4:48 PM
User is offline toadkicker
30 posts
10th Ranked


Re: Use of portal:url control 

FWIW, I know this is a bit of an older post but I just implemented this on my page and URLControl seems to not work with multiple values in the FileFilter when uploading. I'm on DNN 4.8.3 and couldn't upload a file with it until I had filefilter only showing 'jpg'. Which in my case is fine, but really just annoying to figure out.

 
New Post 7/21/2008 8:04 PM
User is offline Briana Tarrance
46 posts
www.virtual-essentials.com
10th Ranked


Re: Use of portal:url control 

Hey there toadkicker - you can use FileFilter="jpg,bmp,gif,jpeg,png"  to have multiple files -- just make sure there are not any spaces in between. Also, when I'm doing multiple extensions, I don't use the "." on the extension..not sure if it will accept it or not, but it works for me. I do have a single FileFilter using a . with the extension however. Hope that helps fix your annoyance.

 

 

 
Previous Previous
 
Next Next
  Forum  DotNetNuke® Pro...  Documents Modul...  Use of portal:url control
 


Forum Policy

These Discussion Forums are dedicated to the discussion of the DotNetNuke Web Application Framework.

For the benefit of the community and to protect the integrity of the project, 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 DotNetNuke.
2. Discussion or promotion of DotNetNuke product releases under a different brand name are strictly prohibited.
3. No Flaming or Trolling.
4. No Profanity, Racism, or Prejudice.
5. Site Moderators have the final word on approving/removing a thread or post or comment.
6. English language posting only, please.

 


Lucede Systems Group
Providing a full range of IT services for large and medium sized companies
www.lucede.com
Adaptive InfoSystems, Inc.
We provide custom programming and various levels of support for DotNetNuke and the .Net framework.
www.aisysweb.com
Multipartner Virtual Data Rooms
The Virtual Data Rooms (VDR) provided by an expert advisor, far from any ordinary software company!, supporting the sellers and their consultants. Multipartner builds and services higly professional Virtual Data Rooms (VDR) specifically tailored to M&A, Real Estate and NPL deals.
www.multipartner.com

DotNetNuke Corporation   Terms Of Use  Privacy Statement
DotNetNuke®, DNN®, and the DotNetNuke logo are trademarks of DotNetNuke Corporation
Hosted by MaximumASP