Skip to content

Commit

Permalink
support for I18N plugin in backend - issue #67
Browse files Browse the repository at this point in the history
use default language in "View post" links
  • Loading branch information
cnb committed Apr 25, 2013
1 parent 82eb228 commit 64b41df
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions news_manager/inc/functions.php
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,9 @@ function nm_get_url($query=false) {
global $PRETTYURLS, $NMPAGEURL, $NMPRETTYURLS, $NMPARENTURL;
$str = '';
$url = find_url($NMPAGEURL, $NMPARENTURL);
if (basename($_SERVER['PHP_SELF']) != 'index.php') // back end only
if (function_exists('find_i18n_url')) // I18N?
$url = find_i18n_url($NMPAGEURL, $NMPARENTURL, return_i18n_default_language());
if ($query) {
if ($PRETTYURLS == 1 && $NMPRETTYURLS == 'Y') {
$str = $query . '/';
Expand Down

0 comments on commit 64b41df

Please sign in to comment.