append currency to URL

Thanks to @mozboz I figured out the answer to my question. I am posting it here in case it helps somebody else:

WordPress (WPML plugin for multi-language and multi-currency) uses the cookie _wcml_dashboard_currency. I was able to set a cookie with the following code and that handled my problem with the currency selection changing after browsing to a different page. Here the code:

    add_action( 'init', 'set_currency_cookie' );
    
    function set_currency_cookie() {
        if (isset($_GET['wcmlc'])) {
          $name="_wcml_dashboard_currency";
          $id = $_GET['wcmlc'];    
           setcookie( $name, $id, time() + 0, "/", COOKIE_DOMAIN );
        }
    }