Custom Post Types and MLS
-
Thanks for this great plugin!
Quick question: what´s the best way to localize custom post types?
At the moment I have set up two different post types: activities (en_US) and actividades (es_ES).
This results in this permalink structure:
example.com/activities/english-activity/example.com/es/actividades/spanish-activity/
I´d like to connect the English post type to the Spanish post type.
I´ve used your permalink filter in the functions.php file of my Spanish site and updated permalinks settings. However MLS doesn´t seem to find a translatable post yet.
I´ll look into this further, just wondering if you could tell me if I´m on the right track or if I should take a different approach.
Here´s the filter I used:
function my_msls_options_get_permalink( $url, $language ) { if ( 'es_ES' == $language ) { $url = str_replace( '/activities/', '/actividades/', $url ); } return $url; } add_filter( 'msls_options_get_permalink', 'my_msls_options_get_permalink', 10, 2 );http://wordpress.org/extend/plugins/multisite-language-switcher/
The topic ‘Custom Post Types and MLS’ is closed to new replies.