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

HomeHomeDevelopment and...Development and...Getting StartedGetting Starteddatabinder.eval being stripped/ignored in DataListdatabinder.eval being stripped/ignored in DataList
Previous
 
Next
New Post
3/15/2010 5:35 PM
 

Hello, I am new to DNN module development and I'm having a very hard time getting it to do what I want. What I want to do is so simple too! For some reason when I try to set the Text property for a asp:HyperLink control it just removes what I've set. Here is the specific code.

 

asp:DataList ID="lstMembers" runat="server" CellPadding="0" CellSpacing="0" repeatedirection="Horizontal" RepeatColumns="2" RepeatLayout="Table" ItemStyle-VerticalAlign="Bottom" DataSourceID="obs_RandomUsers" DataKeyField="UserID">

 

<ItemTemplate>

 

<table style="width: 100px; text-align: center; margin-left: auto; margin-right: auto;"

 

cellpadding="0" cellspacing="0">

 

<tr>

 

<td style="height: 55px;">

 

<asp:Image ID="img_ProPic" runat="server" />

 

</td>

 

</tr>

 

<tr>

 

<td>

 

<div class="asfont2">

 

<asp:HyperLink ID="a_ProfileLink" runat="server" Text='<%# DataBinder.Eval(Container.DataItem,"Username") %>'></asp:HyperLink></div>

 

</td>

 

</tr>

 

</table>

 

</ItemTemplate>

 

</asp:DataList>

 It looks right to me, I'm just not sure what to do. I'm running version 05.02.00 (275)

 

 

<

 
New Post
3/15/2010 6:00 PM
 

Nowhere do I see (in your markup anyway) where you are setting the NavigateUrl property of the hyperlink control. As I recall, if no value is provided for the NavigateUrl, the hyperlink control will not be visible.


Bill, WESNet Designs
Team Lead - DotNetNuke Gallery Module Project (Not Actively Being Developed)
Extensions Forge Projects . . .
Current: UserExport, ContentDeJour, ePrayer, DNN NewsTicker, By Invitation
Coming Soon: FRBO-For Rent By Owner
 
New Post
3/15/2010 8:54 PM
 
William Severance wrote:

Nowhere do I see (in your markup anyway) where you are setting the NavigateUrl property of the hyperlink control. As I recall, if no value is provided for the NavigateUrl, the hyperlink control will not be visible.

 

That is actually set in the code behind.

 
New Post
3/15/2010 8:57 PM
 

This is an example of the resulting HTML.

<table style="width: 100px; text-align: center; margin-left: auto; margin-right: auto;"
                            cellpadding="0" cellspacing="0">

                            <tr>
                                <td style="height: 55px;">
                                        <img id="dnn_ctr481_View_List_lstMembers_ctl00_img_ProPic" src="/desktopmodules/activesocial/profilepic.ashx?PortalId=0&amp;uid=10&amp;h=45&amp;w=45" style="border-width:0px;" />
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    <div class="asfont2">
                                        <a id="dnn_ctr481_View_List_lstMembers_ctl00_a_ProfileLink" href="/MyProfile/tabid/60/asuid/10/Default.aspx"></a></div>

                                </td>
                            </tr>
                        </table>
 

As you can see, the link is being created it is just ignoring my text property setting.

 
New Post
3/17/2010 6:39 PM
 
Well, I ended up just recreating the project completely and it is working now. I don't know.
 
Previous
 
Next
HomeHomeDevelopment and...Development and...Getting StartedGetting Starteddatabinder.eval being stripped/ignored in DataListdatabinder.eval being stripped/ignored in DataList


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