Forum: how to truncate special charactors

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
9d6568ce3aa2afda64fb5dfa2625e14c?d=identicon&s=25 Sunny B. (sunny_bogawat)
on 2008-09-18 12:14
   In my application I am using a list box where i am showing different
   name. I am using
   for truncating the name but it gives me problem when group name come
   like Shital's friends from "Office" Group this

    In list box it showing as a Shital's friends from & quote..
    how to avoid such a thing? whats a proper way for handling such a

  character like single quote, double quote, ampersand not truncated
  please give me a standers way for doing it.
This topic is locked and can not be replied to.