Quantcast
Channel: SharePoint 2010 - Development and Programming forum
Viewing all articles
Browse latest Browse all 11508

User Profile URL Property

$
0
0

Hoping someone can help me figure this out or point me in a better direction.

We are trying to use Google translate to pronounce user names on the person.aspx page. We put the full URLs for each name in AD and I’ve mapped it to Web site field in the User Profile.  I want the URL title to display instead of the full URL from AD. I’m not able to substitue the SPSWC:ProfilePropertyValue for website into the a href or use JavaScript.  I’ve tried the SPSWC:ProfilePropertyValue for website with both ApplyFormatting="false" and ApplyFormatting="true"

JavaScript I’ve tried:
<script>               
varURL1='<SPSWC:ProfilePropertyValue ApplyFormatting="false" PropertyName="Website" runat="server" PrefixBrIfNotEmpty="true"/>';
document.write('<a href="'+URL1+'">Translate User Name</a>');
</script>

Page Result (Good):
Link says Translate User Name

URL Result (Not so Good):
http://mysite-xx.xxx.com/%3Cspan%3E%3Cbr%3Ehttp://translate.google.com/translate_tts?tl=en&q=User Name</span>


I found one possible solution that could help here on Technet, but I’m not a .NET developer http://social.technet.microsoft.com/Forums/sharepoint/en-US/1d4565c3-3801-42a3-80bf-639016796b06/how-to-customize-spswcprofilepropertyvalue-at-ascx-usercontrol?forum=sharepointdevelopmentprevious and the answer was to “Subclass ProfilePropertyValueby inheriting into your own class, then override the Render method to output your own HTML”.

Any help would be much appreciated even if it’s a total different / easier solution.

Thanks in advance


Viewing all articles
Browse latest Browse all 11508

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>