Table Reference to MyPix
Last Post 11 May 2011 07:59 PM by Lewis Hill. 3 Replies.
Printer Friendly
  •  
  •  
  •  
  •  
  •  
Sort:
PrevPrev NextNext
You are not authorized to post a reply.
Author Messages
Lewis Hill New Member New Member Posts:11 Avatar
--
09 May 2011 08:36 PM  
After upgrading to DNN 5.6.2 and User Directory Manager 4.1.4 the user profile path to MyPix has changed. I have some custom code that uses this User Profile Property and its photo path.

Where can I find the database table with the photo path to the MyPix?

Before I could run a select statement and get the Value/path:
SELECT ProfileID, UserID, PropertyDefinitionID, PropertyValue, PropertyText, Visibility, LastUpdatedDate
FROM UserProfile
WHERE (UserID = 40)
-- returns
/Portals/0/MyPix/MBetz/Thumbnail/markbetz100.jpg;

Now with new registrations or adding a photo to a current users record this select does not return the path.

Thanks,
Lewis
Lewis Hill New Member New Member Posts:11 Avatar
--
10 May 2011 01:23 PM  
I thought I would add some clarification to my post.

Below are select statements for 2 users. This first user that registered before the upgrade (DNN 5.6.2 and UDM 4.1.4) has a photo and image path:
SELECT UserID, PropertyDefinitionID, PropertyValue, PropertyText
FROM dnn_UserProfile
WHERE (UserID = 40) and PropertyDefinitionID = 41
Returns: 40 41 /Portals/0/MyPix/MBetz/Thumbnail/markbetz100.jpg; NULL

The second select is a new user that has a photo but the UserProfile table has -1 for the PropertyValue but his photo does show in his profile and in UDM Details.
SELECT UserID, PropertyDefinitionID, PropertyValue, PropertyText
FROM dnn_UserProfile
WHERE (UserID = 551) and PropertyDefinitionID = 41
Returns: 551 41 -1 NULL

Another example:
SELECT TOP (200) ProfileID, UserID, PropertyDefinitionID, PropertyValue, PropertyText, Visibility, LastUpdatedDate
FROM dnn_UserProfile
WHERE (UserID = 40)
Returns: 763 23 User Photo NULL

I am trying to find out where the path to the user photos is now stored in the database and how to access this reference.
Artek New Member New Member Posts:5 Avatar
--
11 May 2011 06:01 AM  
Hi,

With one of latest version of UDM module we not saving all images data do database, this is because PropertyValue column is limited.
Simplify, module just saving image in this location:
~\Portals\PortalID\MyPix\UserName\
to display user MyPix entries module gets all image files from this location

You can use MyPix API to get images, this is an example in C#:


var miCtrl = new DNNMasters.UserMediaComponents.MyPix.ManageImages();
miCtrl.CurrentUser = currentUserInfo;
var code = miCtrl.GetPhotosCode(true, false, true);
Lewis Hill New Member New Member Posts:11 Avatar
--
11 May 2011 07:59 PM  
Thanks for replying to my post. Because we have some custom code running on another Website that looks for the image path in the UserProfile table and then creates employee information pages, is it possible to have you customize your module to insert or update the image path into the UserProfile table like it was in the older version of this module.

Basically, the UDM is working fine on our student website (DotNetNuke) but we would like the image path added to the user profile so our public website (ASP.Net not DNN) can still access the images.

If you can customize this please provide the cost estimate and time required.

Thanks again for help with this.
Lewis

Also, I used your Contact Us for this customization request and included my email.
You are not authorized to post a reply.