Title: spmakingwp's Replies | WordPress.org

---

# spmakingwp

  [  ](https://wordpress.org/support/users/spmakingwp/)

 *   [Profile](https://wordpress.org/support/users/spmakingwp/)
 *   [Topics Started](https://wordpress.org/support/users/spmakingwp/topics/)
 *   [Replies Created](https://wordpress.org/support/users/spmakingwp/replies/)
 *   [Reviews Written](https://wordpress.org/support/users/spmakingwp/reviews/)
 *   [Topics Replied To](https://wordpress.org/support/users/spmakingwp/replied-to/)
 *   [Engagements](https://wordpress.org/support/users/spmakingwp/engagements/)
 *   [Favorites](https://wordpress.org/support/users/spmakingwp/favorites/)

 Search replies:

## Forum Replies Created

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

 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Multisite Language Switcher] The plugin is not capturing the slug on the store page correctly.](https://wordpress.org/support/topic/the-plugin-is-not-capturing-the-slug-on-the-store-page-correctly/)
 *  Thread Starter [spmakingwp](https://wordpress.org/support/users/spmakingwp/)
 * (@spmakingwp)
 * [6 years ago](https://wordpress.org/support/topic/the-plugin-is-not-capturing-the-slug-on-the-store-page-correctly/#post-13399567)
 * Perfect, problem solved.
 * Thank you very much Dennis, excellent support.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Multisite Language Switcher] The plugin is not capturing the slug on the store page correctly.](https://wordpress.org/support/topic/the-plugin-is-not-capturing-the-slug-on-the-store-page-correctly/)
 *  Thread Starter [spmakingwp](https://wordpress.org/support/users/spmakingwp/)
 * (@spmakingwp)
 * [6 years ago](https://wordpress.org/support/topic/the-plugin-is-not-capturing-the-slug-on-the-store-page-correctly/#post-13398290)
 * Hi, thanks for your response.
 * I added the following code and it works perfect for switching from English to
   Spanish:
    ———————– function my_msls_options_get_permalink( $url, $language ) {
   if ( ‘es_ES’ == $language ) { $url = str_replace( ‘/shop/’, ‘/tienda/’, $url );}
   return $url; } add_filter( ‘msls_options_get_permalink’, ‘my_msls_options_get_permalink’,
   10, 2 ); ——————————–
 * But adding the following, to switch from Spanish to English, it gives me an error.
 * ————————————–
    function my_msls_options_get_permalink( $url, $language ) { if(‘
   en_US’ == $language ) { $url = str_replace( ‘/tienda/’, ‘/shop/’, $url ); } return
   $url; } add_filter( ‘msls_options_get_permalink’, ‘my_msls_options_get_permalink’,
   10, 2 ); ————————————–
 * I studied and tried various ways, but I don’t know how to add both.
 * Link to the English version: [https://ruizbazan.com/rugs/shop/](https://ruizbazan.com/rugs/shop/)
 * Link to the Spanish version: [https://ruizbazan.com/tienda/](https://ruizbazan.com/tienda/)
    -  This reply was modified 6 years ago by [spmakingwp](https://wordpress.org/support/users/spmakingwp/).
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Multisite Language Switcher] The plugin is not capturing the slug on the store page correctly.](https://wordpress.org/support/topic/the-plugin-is-not-capturing-the-slug-on-the-store-page-correctly/)
 *  Thread Starter [spmakingwp](https://wordpress.org/support/users/spmakingwp/)
 * (@spmakingwp)
 * [6 years ago](https://wordpress.org/support/topic/the-plugin-is-not-capturing-the-slug-on-the-store-page-correctly/#post-13358072)
 * Update:
 * New link: [https://ruizbazan.com/tienda](https://ruizbazan.com/tienda)
 * The problem may be in ‘Rewrites Settings’, with the automatic capture of ‘Products
   Slug’
 * There’s no problem with the database, we tried another installation and it gave
   the same error.

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