Great Ideas. Always Flowing.

We are not happy until you are happy. Client satisfaction guaranteed. Whatever your needs and requirements, we have the skills and resources for the job!

Quick login...


Or... now make it easy with Facebook Integration
Connect via Facebook



Top Sellers

Frustrated over the lack of customization for your user's registration fields? Dynamically setup your DNN Portal with custom registration fields, layout, questions, and other core integration options......

Ultra Video Gallery is a brother product of Ultra Media Gallery, UVG allows you to upload videos in various format and automatically encode them to flv or H264 format, you also can add videos from internet or record live videos from your webcam.

Build high performance, completely customizable data-entry forms and views driven by your DNN and external databases. New built-in tools make it a snap to quickly create data entry forms, data views, and even database tables. Plus, add your own HTML, CSS, Javascript, SQL commands, stored procedures,

The most advanced DotNetNuke shopping cart on the planet. Easy to use e-Commerce, Secure Shopping Cart Software and SEO friendly. B2C / B2B Ecommerce Sites.

One stop solution for events calendar and events registration! FREE DOWNLOAD is available now!

How do display image field
Last Post 03-18-2010 06:06 AM by David To. 13 Replies.
AddThis - Bookmarking and Sharing Button Printer Friendly
  •  
  •  
  •  
  •  
  •  
Sort:
PrevPrev NextNext
You are not authorized to post a reply.
Author Messages
Robert KabacoffUser is Offline
new to the springs
new to the springs
Posts:4
Avatar

--
01-13-2009 06:13 AM

    Using Dynamic Registration V3.2 our users upload a photo of themselves. It displays fine in their own profile page.

     

    In the User Directory (Dynamic User Directory v2.4), I want to include their photo in the details page. When I use the token [Photo], I get an image name (e.g. 13ee2d28-5fa3-42c4-b51c-7cf4ab56d54c.jpg) rather than the photo.

    How can I have the photo display?

    CandaceUser is Offline
    river guide
    river guide
    Posts:2431
    Avatar

    --
    01-13-2009 07:58 AM

    Hi Robert,

    Can you please try this?  If you already have the image field in your registration form, then

    1.  In User Directory, Edit template.  When you click on image button, you'll get a pop up box  for image properties.

    2.  Add this to the URL field:   http://www.yourbusiness.com/portals...Field]
     
    where [ImageField] is the short field name for the image.

    Let me know if that works for you.  Thanks.

    Candace

    Robert KabacoffUser is Offline
    new to the springs
    new to the springs
    Posts:4
    Avatar

    --
    01-13-2009 08:31 AM

     Candice, this is great. It worked like a charm.

    Thanks!

    Rob

    CandaceUser is Offline
    river guide
    river guide
    Posts:2431
    Avatar

    --
    01-14-2009 08:33 AM

    WongUser is Offline
    new to the springs
    new to the springs
    Posts:1
    Avatar

    --
    07-07-2009 05:21 PM
    Another here>>>If im using sharepoint picture library...i upload the photo to the picture library..and now i using the report builder to get the photo from picture library ...can i do that??...
    Miguel ClaraUser is Offline
    going with the flow
    going with the flow
    Posts:56
    Avatar

    --
    02-28-2010 03:31 PM

    I've got to this part easy... but I would like to show a deafult picture in case the user didn't upload anythig.... is this possible?

     

    How could I do it??

    David ToUser is Offline
    river guide
    river guide
    Posts:2719
    Avatar

    --
    03-01-2010 06:43 AM
    HI, it's possible but I believe you will have to use SQL stored procedure to set the profile field to be some default image if the user didn't choose one. Are you using Dynamic Registration as the module for the user to register/update their DNN profile fields? Or are you simply using the default DNN version? -- David
    Miguel ClaraUser is Offline
    going with the flow
    going with the flow
    Posts:56
    Avatar

    --
    03-03-2010 01:48 AM

    Yes David, I am using Dynamic Registration 4!

    David ToUser is Offline
    river guide
    river guide
    Posts:2719
    Avatar

    --
    03-04-2010 07:48 AM
    If you are using Dynamic Registration, you could create an SQL form completion event insert a user profile with default image if they don't have an image.

    1) check the "profilepropertydefinition" sql table to get the "PropertyDefinitionID" of the image property
    2) then check the userprofile table to see if this propertydefintionid for this userid exists
    3) if not add it the the userprofile table with a default image

    I hope this points you in the right direction. -- David
    Miguel ClaraUser is Offline
    going with the flow
    going with the flow
    Posts:56
    Avatar

    --
    03-05-2010 01:03 AM


    Thank you David... but I am a bit dum.. lol


    DR already was the "default value" so I can simply upload a "default_avatar.png" to the DR folder in my portal...


    If the user does change nothing... the avatar will be the one I upload...

    I still have to change that value depending on a choice.... cause this site has "Male" "Female" and "Couple" as gender choice... so it would be nice to have a default picture depending on that selection...


    I can do this with the "Affected Question New Default Value" in the question events...


    So sorry for the time I made you dig this.. I was just not being very thorough, the options exist with no need for SQL

     

    Thanks!

    Miguel ClaraUser is Offline
    going with the flow
    going with the flow
    Posts:56
    Avatar

    --
    03-16-2010 08:52 AM
    Ok this works very well for new users... but for all that already exists its more complicated..

    The query I would have to use is an insert... and I'm afraid I might end up make a big mess to DNN DB... so I've tried another approach..

    I was trying to use Java Script to do this (show a default imagage in cause img src=.... fails...)

    But I can't make this work... no matter what I change DUD allways changes my template source code to some big mess... in IE i get an error loading the page...

    Is DUD not compatible with JavaScript???
    David ToUser is Offline
    river guide
    river guide
    Posts:2719
    Avatar

    --
    03-16-2010 09:30 AM
    HI, I don't know about placing javascript in the listing template but a user have successfully placed javascript in the detail template though. Personally, I believe running an SQL query to insert the record into the user profile is an easier way to go. -- David
    Miguel ClaraUser is Offline
    going with the flow
    going with the flow
    Posts:56
    Avatar

    --
    03-18-2010 04:54 AM

    Hum.. but there are user who have allready a diferent value for that field... I would have to take that in count in the query....

     

    You wouldn't mind sharing the query, you usualy use, would you?
    Does this only needs to "mess" with one table?

    David ToUser is Offline
    river guide
    river guide
    Posts:2719
    Avatar

    --
    03-18-2010 06:06 AM
    Hi, you would use something like the stored procedure (needs to retrieve the ImageUpload field and the UserID):
    create procedure usp_dynamicregistration_setdefaultimage
    (@ImageUpload nvarchar(200),@UserID int)
    as
    begin
    declare @CompanyLogoID int
    set @CompanyLogoID = (select propertydefinitionID from {objectQualifier}profilepropertydefinition
    where propertyname = 'CompanyLogo')

    if (@ImageUpload = '')
    begin
    if not exists (select UserID from {objectQualifier}userprofile where userid=@UserID
    and propertydefinitionID = @CompanyLogoID)
    insert into {objectQualifier}userprofile(UserID,PropertyDefinitionID,PropertyValue,
    PropertyText,Visibility,LastUpdatedDate)
    values(@UserID,@CompanyLogoID,'defaultimage.jpg','',2,getdate())
    end

    if (@ImageUpload != '')
    begin
    if not exists (select UserID from {objectQualifier}userprofile where userid=@UserID
    and propertydefinitionID = @CompanyLogoID)
    insert into {objectQualifier}userprofile(UserID,PropertyDefinitionID,PropertyValue,
    PropertyText,Visibility,LastUpdatedDate)
    values(@UserID,@CompanyLogoID,@ImageUpload,'',2,getdate())
    end
    end

    If @ImageUpload is blank and the userprofile doesn't exist, then insert it with a default image. If @ImageUpload is not blank, and the userprofile doesn't exist, then insert it with the corresponding image.

    Now, what about existing users that don't have an image yet? Let's say the propertydefinitionid for the picture is 223. Then you can do something like this:

    select userid,'223' as PropertyDefinitionID,'defaultimage.jpg' as PropertyValue,space(10) as PropertyText,
    2 as Visibility,getdate() as LastupdatedDate into templogo from users where userid not in
    (select userid from userprofile where propertydefinitionid = 223)

    insert into {objectQualifier}userprofile(UserID,PropertyDefinitionID,PropertyValue,PropertyText,Visibility,LastupdatedDate)
    select * from templogo

    Test it out and see if it works for you. You may have to tweak the SQL query a bit but it points you in the right direction. -- David
    You are not authorized to post a reply.


     
     

    Join our mailing list...

    Get current news and events the easy way
    Subscribe Me

    Recent Blogs...

     
    Copyright 2005 - 2011 by Data Springs, Inc.
     
  • film izle
  • 720 izle
  • film
  • sinema izle
  • film makinesi
  • T�rk�e dublaj film
  • film izle
  • film izle
  • baglan film izle
  • sinema izle
  • 1080 film izle
  • film mercegi