Title: Encoding bug
Last modified: August 21, 2016

---

# Encoding bug

 *  Resolved [R J](https://wordpress.org/support/users/r-j-1/)
 * (@r-j-1)
 * [12 years, 11 months ago](https://wordpress.org/support/topic/encoding-bug/)
 * I find an encoding problems: when album name truncating (more than 14 simbols),
   you’ll see unexpected simbol in the end of string (see in attach).
 * I modify string #240 in file **app/main/profile/BPMediaAlbum.php**
 * Change it from
 * `<h3 title="<?php echo $this->name ?>"><a href="<?php echo $this->url ?>" title
   ="<?php _e($this->description, BP_MEDIA_TXT_DOMAIN); ?>"><?php echo ( ( strlen(
   $this->name) > 14 ) ? substr($this->name, 0, 14) . "&hellip;" : $this->name );?
   > </a><?php echo ' (' . count($this->media_entries) . ')'; ?></h3>`
 * to
 * `<h3 title="<?php echo $this->name ?>"><a href="<?php echo $this->url ?>" title
   ="<?php _e($this->description, BP_MEDIA_TXT_DOMAIN); ?>"><?php echo ( ( strlen(
   $this->name) > 40 ) ? mb_convert_encoding(substr($this->name, 0, 40), 'UTF-8','
   UTF-8') . "&hellip;" : $this->name ); ?> </a><?php echo ' (' . count($this->media_entries).')';?
   ></h3>`
 * and this solve the problem. I think, “14” simbols in code – not flexible, you
   can include this to the Options page (it will be customizable).
 * Another problem – I cant translate many words (yes, I create .po and .mo files
   in language folder).
    – “All Albums” in Media tab – translated only word “All”,
   so i have “Все Albums”;
 *  – Роман Пупкин добавил(а) Photo 4 дн. назад – I cant translate “Photo” world
 *  – and so on …
 * [http://wordpress.org/extend/plugins/buddypress-media/](http://wordpress.org/extend/plugins/buddypress-media/)

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Plugin Contributor [Saurabh](https://wordpress.org/support/users/saurabhshukla/)
 * (@saurabhshukla)
 * [12 years, 11 months ago](https://wordpress.org/support/topic/encoding-bug/#post-3808478)
 * Hi,
 * I agree. This is not the most elegant piece of code. We inserted it for the display
   issues we kept facing. We the rewritten plugin, we’ll keep this in mind.
 * See:
 * [http://wordpress.org/support/topic/no-more-support-here-use-httprtcampcomgroupsbuddypress-mediaforum](http://wordpress.org/support/topic/no-more-support-here-use-httprtcampcomgroupsbuddypress-mediaforum)
 * [http://rtcamp.com/news/getting-ready-for-rtmedia/](http://rtcamp.com/news/getting-ready-for-rtmedia/)
 *  Plugin Contributor [Saurabh](https://wordpress.org/support/users/saurabhshukla/)
 * (@saurabhshukla)
 * [12 years, 11 months ago](https://wordpress.org/support/topic/encoding-bug/#post-3808479)
 * The Media types are not translatable properly. We’ll fix that with rtMedia.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Encoding bug’ is closed to new replies.

 * ![](https://ps.w.org/buddypress-media/assets/icon-256x256.png?rev=3219705)
 * [rtMedia for WordPress, BuddyPress and bbPress](https://wordpress.org/plugins/buddypress-media/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/buddypress-media/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/buddypress-media/)
 * [Active Topics](https://wordpress.org/support/plugin/buddypress-media/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/buddypress-media/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/buddypress-media/reviews/)

## Tags

 * [encoding](https://wordpress.org/support/topic-tag/encoding/)

 * 2 replies
 * 2 participants
 * Last reply from: [Saurabh](https://wordpress.org/support/users/saurabhshukla/)
 * Last activity: [12 years, 11 months ago](https://wordpress.org/support/topic/encoding-bug/#post-3808479)
 * Status: resolved