locked
getting error while showing the images from database to img tag using handler RRS feed

  • Question

  • User-155579095 posted

    hi friends i developed a site wer users will upload images which will be converted into binary and stored in the database again using handler im retriving the image and show to the user using <img>.this works fine in localhost but wen hosted online the images are not visible rather showing as 'submit query' in the place of <img>tag

    my code is like this

    <asp:DataList ID="datalist1" runat="server" RepeatDirection="Horizontal" RepeatColumns="5"
                BorderStyle="Double" OnItemCommand="datalist1_ItemCommand" Width="953px">
                <HeaderTemplate>
                </HeaderTemplate>
                <ItemTemplate>
                    <table cellspacing="12px" -border-radius:"8px 8px 8px 8px">
                        <tr>
                            <td>
                                <asp:ImageButton ID="Image1" runat="server" ImageUrl='<%# "Handler2.ashx?AdID="+ Eval("AdID") %>'
                                     Height="150px" Width="195px" CommandArgument='<%#Eval("AdID") %>'                                             ForeColor="Transparent"    Alt="Loading..." />
                                    <asp:Image ImageUrl="~/Images/alarm-clock.png" runat="server" Height="30px"/>
                                <asp:Label ID="lbl1" Text="60Sec" runat="server" Height="5" Width="5"></asp:Label>
                               <%-- <asp:Label ID="lbl2"  runat="server"></asp:Label>--%>
                            </td>
                        </tr>
                    </table>
                </ItemTemplate>
            </asp:DataList>

    Tuesday, May 22, 2012 12:11 AM

Answers

All replies