locked
Globalize not working with script RRS feed

  • Question

  • User1223056342 posted

    hi,

    here is my original code.when my mouse over or out is working fine but when i use as globalize resourses then mouse over or out not  working

    <asp:ImageButton ID="r1" runat="server"

    ImageUrl="./imgs/rb_off.png"

    OnMouseOver="src='./imgs/rb_on.png';"

    OnMouseOut="src='./imgs/rb_off.png';"

    PostBackUrl="./rb/Default.aspx" Enabled="False">

    </asp:ImageButton>

     here is example code with globalize resouses.

    <asp:ImageButton ID="r1" runat="server"

    ImageUrl="<%$ Resources:ImgButtons, rb_off %>"

    OnMouseOver="src='<%$ Resources:ImgButtons, rb_on %>';"

    OnMouseOut="src='<%$ Resources:ImgButtons, rb_off %>';"

    PostBackUrl="~/rb/Default.aspx" Enabled="False">

    </asp:ImageButton>

    Could u plz let me know where im making mistake

     

    Sunday, January 25, 2009 9:48 AM

All replies

  • User1747761241 posted

    the original should have ~/   not ./

    Show the group the html that it outputs.

     

    Sunday, January 25, 2009 11:15 AM
  • User1223056342 posted

    is working with ./ but this is not my problem.

    my problem with App_GlobalResources

    Sunday, January 25, 2009 11:20 AM
  • User-1136466523 posted

    Hi,

    From the code you provided, you are using relative path in image url property. When you using resource expression, it just load the image url string you predefined in the resource file. You need to make sure that if the string you defined is in the right path. (e.g:  It should be ./imgs/rb_on.png  but not imgs/rb_on.png or ~/imgs/rb_on.png )

    Thanks.

    Thursday, January 29, 2009 9:36 PM