? 000-big-form.patch ? 200-node.patch ? 819904-domain0.patch ? 940762-path.patch ? 945420-auto-node-path.patch ? 969022-menu-conf.patch ? 969022-menu.patch ? 970274-conf-ignore.patch ? domain_conf/domain_conf.drush.inc Index: domain.api.php =================================================================== RCS file: /cvs/drupal-contrib/contributions/modules/domain/domain.api.php,v retrieving revision 1.4 diff -u -p -r1.4 domain.api.php --- domain.api.php 10 Dec 2010 18:47:25 -0000 1.4 +++ domain.api.php 10 Dec 2010 20:15:09 -0000 @@ -534,19 +534,25 @@ function hook_domain_bootstrap_full($dom * Prefix, we only include this function if we know it is necessary. * * @see domain_prefix_init() + * @see hook_url_outbound_alter() * * @param $domain_id * The domain_id taken from {domain}. * @param $path * The internal drupal path to the node. - * @param $path_language - * Language code to look up the path in. + * @param $options + * The path options. + * @param $original_path + * The raw path request from the URL. * * @ingroup domain_hooks */ -function hook_domain_path($domain_id, &$path, $path_language = '') { +function hook_domain_path($domain_id, &$path, &$options, $original_path) { // Give a normal path alias $path = drupal_get_path_alias($path); + // In D7, path alias lookups are done after url_alter, so if the + // alias is set, the option must be flagged. + $options['alias'] = TRUE; } /** Index: domain.module =================================================================== RCS file: /cvs/drupal-contrib/contributions/modules/domain/domain.module,v retrieving revision 1.220 diff -u -p -r1.220 domain.module --- domain.module 31 Oct 2010 20:14:18 -0000 1.220 +++ domain.module 10 Dec 2010 20:15:11 -0000 @@ -1410,21 +1410,25 @@ function domain_get_path($domain) { * Determine an absolute path to the current page * * @param $domain - * The currently active $domain array, provided by domain_lookup(). + * The currently active $domain array, provided by domain_lookup(). * @return - * The absolute url to the current page on the requested domain. + * The absolute url to the current page on the requested domain. */ function domain_get_uri($domain) { + global $base_path; $request_uri = request_uri(); $modules = _domain_path_modules(); if (!empty($modules) && !drupal_is_front_page()) { // If needed, let modules modify the path alias. - $alias = domain_path($domain['domain_id'], $_GET['q']); + $request_uri = str_replace($base_path, '', $request_uri); + $request_uri = trim($request_uri, '/'); + // We cannot use URL here because we need the domain_id data. + // TODO: use url() but pass a domain_id option? + domain_path($domain['domain_id'], $request_uri, $options, $request_uri, $_GET['q']); // Run the result through url() for proper language and path handling. - $request_uri = url($alias); + $request_uri = url($request_uri, $options); } - - $path = domain_check_scheme($domain['scheme']) . '://' . $domain['subdomain'] . $request_uri; + $path = check_url($domain['scheme'] . '://' . $domain['subdomain'] . $request_uri); return $path; } @@ -2683,7 +2687,7 @@ function domain_warning_check($form_id) } /** - * Helper function for passing hook_domain_path() by reference. + * Helper function for passing hook_domainpath() by reference. * * @param $domain_id * The domain_id taken from {domain}. @@ -2692,18 +2696,17 @@ function domain_warning_check($form_id) * @param $path_language * Optional language code to look up the path in. * @return - * The $path, modified by reference by hook_domain_path() implementations. + * The $path, modified by reference by hook_domainpath() implementations. */ -function domain_path($domain_id, $path, $path_language = '') { +function domain_path($domain_id, &$path, &$options, $original_path) { $modules = _domain_path_modules(); if (!empty($modules)) { foreach ($modules as $module) { // Cannot use module_invoke_all() since these are passed by reference. $function = $module . '_domain_path'; - $function($domain_id, $path, $path_language); + $function($domain_id, $path, $options, $original_path); } } - return $path; } /**