Double Tooltips

6 posts, 1 answers
  1. Lucania
    Lucania  avatar
    65 posts
    Member since:
    May 2011

    Posted 02 Mar 2012 Link to this post

    I'm using Jquery qtip for my tooltips, I have it set to "prettify" the tooltips specified in all title attributes. This works fine with most Telerik controls, but with the rating control, I get double tooltips. One is the pretty qtip, but on top of it appears a second "ugly" tooltip, unprocessed by qtip. I've included a screenshot. I'm just wondering how the default rating items are rendered, do the images get an "alt" tag that might be causing this? Any ideas on how I might get around this?

    Thanks

    Ross Crawford
  2. Princy
    Princy avatar
    17421 posts
    Member since:
    Mar 2007

    Posted 02 Mar 2012 Link to this post

    Hello,

    Try setting EnableToolTips property of RadRating as false.

    Thanks,
    Princy.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Lucania
    Lucania  avatar
    65 posts
    Member since:
    May 2011

    Posted 04 Mar 2012 Link to this post

    Hi Princy,

    Yes, that removes both tooltips, however I'd like to keep one of them without the other if possible.

    Regards

    Ross Crawford
  5. Lucania
    Lucania  avatar
    65 posts
    Member since:
    May 2011

    Posted 04 Mar 2012 Link to this post

    Would it be possible to do something similar to what's described in this post for a similar issue in RadEditor? I'm not familiar enough with the client API to work out what would be needed.

    Thanks

    Ross Crawford
  6. Answer
    Slav
    Admin
    Slav avatar
    1355 posts

    Posted 05 Mar 2012 Link to this post

    Hello Ross,

    The jQuery plugin, which you use for modifying the default appearance, does not clear the title attribute of the links in the RadRating control, which causes the standard tooltips to be displayed as well. In order to ensure that the tooltips will be displayed properly, please use the following code after the plugin has finished modifying the tooltips (you can use setTimeout for this purpose):
    var rotator = $find("<%=RadRating1.ClientID %>");
    var items = rotator.get_itemData();
    for (var i = 0; i < items.length; i++) {
        items[i].itemElement.children[0].removeAttribute("title");
    }
    rotator.set_enableToolTips(false);
     
    This will remove the title attribute from the links in the RadRating's items and it will stop the showing of regular tooltips on mouse over the items.

    All the best,
    Slav
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
  7. Lucania
    Lucania  avatar
    65 posts
    Member since:
    May 2011

    Posted 05 Mar 2012 Link to this post

    Thanks Slav, that worked great.
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017