Results 1 to 3 of 3
  1. #1
    Join Date
    Jun 2006
    Posts
    298
    Plugin Contributions
    0

    Default Make Admin language dropdown visible on all Admin pages?

    My store is in English and French. I'd like to have the language selection dropdown box on the admin page stay visible no matter what admin page I'm on. Currently, it hides the dropdown when I view an order, which is a pain when trying to toggle back and forth between French and English orders. (I have SuperOrders 3.0 installed, if that makes a difference.)

    Is there a way to make the language dropdown remain visible on all admin pages?

    Thanks.

  2. #2
    Join Date
    Jan 2004
    Posts
    66,373
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: Make Admin language dropdown visible on all Admin pages?

    You would need to edit the /admin/includes/header.php file to not only change the limits on which pages it displays for, but also to include all page parameters when the language is changed, else when you choose the other language you'll lose which order you're looking at, etc.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  3. #3
    Join Date
    Aug 2007
    Location
    Gijón, Asturias, Spain
    Posts
    2,589
    Plugin Contributions
    30

    Default Re: Make Admin language dropdown visible on all Admin pages?

    I removed the test years ago and I don't think I have needed to do anything else regarding passing parameters.
    I think it should be on all admin pages: for checking translations, and on re-entry back into whatever page in admin after a timeout.
    //steve removed IF to always show language dropdown
    // if ((basename($PHP_SELF) != FILENAME_DEFINE_LANGUAGE . '.php') and (basename($PHP_SELF) != FILENAME_PRODUCTS_OPTIONS_NAME . '.php') and empty($action)) {
    $languages_array = array();
    $languages = zen_get_languages();
    if (sizeof($languages) > 1) {
    //$languages_selected = $_GET['language'];
    $languages_selected = $_SESSION['language'];
    $missing_languages = '';
    $count = 0;
    for ($i = 0, $n = sizeof($languages); $i < $n; $i++) {
    $test_directory = DIR_WS_LANGUAGES . $languages[$i]['directory'];
    $test_file = DIR_WS_LANGUAGES . $languages[$i]['directory'] . '.php';
    if (file_exists($test_file) and file_exists($test_directory)) {
    $count++;
    $languages_array[] = array('id' => $languages[$i]['code'],
    'text' => $languages[$i]['name']);
    if ($languages[$i]['directory'] == $_SESSION['language']) {
    $languages_selected = $languages[$i]['code'];
    }
    } else {
    $missing_languages .= ' ' . ucfirst($languages[$i]['directory']) . ' ' . $languages[$i]['name'];
    }
    }


    // if languages in table do not match valid languages show error message
    if ($count != sizeof($languages)) {
    $messageStack->add('MISSING LANGUAGE FILES OR DIRECTORIES ...' . $missing_languages, 'caution');
    }
    $hide_languages = false;
    } else {
    $hide_languages = true;
    } // more than one language
    /* steve removed IF} else {
    $hide_languages = true;
    } // hide when other language dropdown is used
    eof */
    Steve
    github.com/torvista: Spanish Language Pack, Google reCaptcha, Structured Data, Multiple Copy-Move-Delete, Image Checker, BackupMySQL Admin/Auto...

 

 

Similar Threads

  1. I can't make changes to any pages in admin area
    By meesh in forum Basic Configuration
    Replies: 6
    Last Post: 23 May 2010, 05:20 AM
  2. Cant show the toolbar(no options are visible like ez pages, prods) in admin page????
    By sricharankatrue in forum Templates, Stylesheets, Page Layout
    Replies: 0
    Last Post: 18 Aug 2009, 07:36 PM
  3. Language selection visible at all pages?
    By pe7er in forum Basic Configuration
    Replies: 4
    Last Post: 10 Jan 2008, 02:15 AM
  4. [to do in v1.5] https not triggering on all admin pages
    By Website Rob in forum Bug Reports
    Replies: 6
    Last Post: 27 Oct 2006, 10:55 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR