Account created on 7 August 2013, over 11 years ago
#

Recent comments

🇨🇳China hongqing

The discussion at Wrong front pages for all domains using the domain.config overrides. gives me some hints.

It works after I uncheck 'Account administration pages' in Detection and selection of languages. Although it is not perfect, it allows me to add contents at least.

🇨🇳China hongqing

More update:

After adding content, the frontpage will be changed to others if I browse the frontpage with the same user, which is a created role with permission to add products. While after adding content, the frontpage will not be changed to others if I browse the frontpage with an anonymous user then with the user added the products.

🇨🇳China hongqing

After checking the saved configuration, I found the following records:

domain.config.master.en.system.site	system.site	Masters	English	
domain.config.master.system.site	system.site	Masters	all
domain.config.master.zh-hans.system.site	zh-hans.system.site	Masters	all

The domain.config.master.zh-hans.system.site should apply to Chinese only, but it always apply to all languages. Not sure if this causes this issue.

🇨🇳China hongqing

This is caused by issue #3280884, which change the frontpage to another one which cannot be accessed.

🇨🇳China hongqing

I encountered the same problem with Drupal 10.3.0 and Domain 2.0.0-beta1.

The frontpage will be changed to the main domain frontpage /node after I add some products in drupal commerce. This can be solved by cleaning cache many times.

It seems this only happens with a role that I created to manage products, but not with admin role.

🇨🇳China hongqing

#20 does not solve my problem, I still have to clean cache many times to show the assigned frontpage, or it will show the frontpage of the main domain, which is /node.

🇨🇳China hongqing

I am closing this as it seems working in my clean installation now. I cannot reproduce it. I am further investigating my production website.

🇨🇳China hongqing

I have clean installation to test the module. The steps are as below:
1. Install Drupal 10.3.0
2. Install Domain module
3. Enable Domain, Domain Access, Domain Configuration, and Domain Configuration UI modules.
4. apply patch 3450485-domain-form-builder.patch
5. Add domain records, named as main and sub respectively.
6. Create two view pages in a view with path /main and /sub respectively.
7. Create two basic pages, which are node/1 and node/2
8. Assign frontpages for each domain through Configuration--> System-->Basic site settings, the frontpage for the main and sub domain is /main and /sub, respectively.
9. Then, try to change the frontpages for each domain through Configuration--> System-->Basic site settings to node/1 and node/2 respectively. The changes are successfully saved in the form.
10. Clean cache.
11. Browse main and sub domain respectively, the frontpage for the main domain is changed, but the frontpage for the subdomain remains the same.
12. In my production website, not the test one (I didn't test it with the test one), the frontpage for the sub domain may be changed to the frontpage of the main domain after adding some contents, I need to resave the domains frontpages to ensure the keep their own frontpages.

🇨🇳China hongqing

Thank you for quick response. Now I found it may be related to users. This occurs when I login with a role I created, there is no error with admin and authenticated roles.

🇨🇳China hongqing

I found this issues is closed because issue #3257541 fixed. I do no think they are the same issues. #3257541 is about the log, while the issue here is user cannot access even being granted permissions.

🇨🇳China hongqing

I encountered the issue after add products to drupal commerce, it happens sometimes, I am not sure which action triggers the issues.

Path: /. Drupal\Core\Http\Exception\CacheableAccessDeniedHttpException: in Drupal\Core\Routing\AccessAwareRouter->checkAccess() (line 115 of /www/wwwroot/xxxx/core/lib/Drupal/Core/Routing/AccessAwareRouter.php).
🇨🇳China hongqing

Thanks. Product type does not include the field by default. I am adding one.

🇨🇳China hongqing

The patch has solved the issue to assign separate frontpage for each domain, but I cannot change the frontpage assigned to the domains.

🇨🇳China hongqing

I have the same issue with Metatag 2.0.0 and Drupal 10.3.0 when add tags to custom route.

🇨🇳China hongqing

@cilefen, you are right. I have resolve it with a patch of Facets.

🇨🇳China hongqing

Same issue after upgrading from 10.2.6 to 10.3.0, 3052574-212.patch resolve it.

🇨🇳China hongqing

@mtalt do you only change the one line code? I tried it but it does not work. I granted the users the permissions to create products on assigned domains.

🇨🇳China hongqing

This should be a Domain Access Entity issue.

🇨🇳China hongqing

I installed Domain with simplytest.me, there is an option there, but there is none on my website.

🇨🇳China hongqing

#2 does not work with D10.2.6 as D10.2.6 has already added tokens, but the tokens are very limited.

🇨🇳China hongqing

I forgot that I used View Entity Reference for the location field.

🇨🇳China hongqing

The post here provide me a direction to modify the theme template.

🇨🇳China hongqing

I find one hierarchy taxonomy works, but another does not work. I need further investigate it.

🇨🇳China hongqing

Finally I find it's a problem of Facets to filter items belong to taxonomy terms.

🇨🇳China hongqing

It could be hided with css, for example:

.topbar-currency-region .commerce-currency-resolver-select-form .button {
    display: none;
}
🇨🇳China hongqing

It seems the patch cannot be applied to Facet Pretty path 2.01. I got the following error:

Checking patch src/Plugin/facets/url_processor/FacetsPrettyPathsUrlProcessor.php...
error: while searching for:
      }
      $pretty_paths_presort_data = $this->sortByWeightAndName($pretty_paths_presort_data);
      $pretty_paths_string = implode('', array_column($pretty_paths_presort_data, 'pretty_path_alias'));
      $url = Url::fromUri('internal:' . $facet->getFacetSource()->getPath() . $pretty_paths_string);
      $url->setOption('attributes', ['rel' => 'nofollow']);

      // First get the current list of get parameters.

error: patch failed: src/Plugin/facets/url_processor/FacetsPrettyPathsUrlProcessor.php:162
error: src/Plugin/facets/url_processor/FacetsPrettyPathsUrlProcessor.php: patch does not apply
🇨🇳China hongqing

It's my fault, I should use AND instead of OR logic.

🇨🇳China hongqing

Thanks for the contribution. It works with Drupal 10.1.4.

🇨🇳China hongqing

It is my first time using this module with Drupal 10.1.4 and Domain Access Logo 2.0.2. I have tried to check and uncheck "Use the logo supplied by the theme" in the appearance setting, but it always shows the Site name and slogan from Configuration > Basic Site Settings.

🇨🇳China hongqing

Just simply change line 103 in CurrencyHelper.php from

$active_currencies[$currency->getCurrencyCode()] = $currency->getName();

to

$active_currencies[$currency->getCurrencyCode()] = $currency->getCurrencyCode();
🇨🇳China hongqing

\Drupal::service('domain.negotiator')->getActiveId(); returns the correct active domain id. There was a error in my code, I am closing it.

🇨🇳China hongqing

I did not print Domain Access to the anonymous users directly. It is hidden and used as the condition of View Conditional field, Therefore, the web can show different page title for each domain.

🇨🇳China hongqing

@agentrickard Thanks for your help. Finally, I find it is a permission issue. I have to grant anonymous users the permission "View all registered domains in the administration list", while the permission "View assigned domains in the administration list" is not enough for anonymous users to view the domains that the content is assigned to. I am not sure if there is a security issue to give anonymous users such permission.

🇨🇳China hongqing

@agentrickard Thanks for your prompt reply. These domains are active. It will not show the domain access directly to anonymous users, it will show a View Conditional field, where Domain Access is the condition.

🇨🇳China hongqing

I found it is because that Facets Pretty Paths is enabled.

🇨🇳China hongqing

I have the same issue with the parent terms.

🇨🇳China hongqing

I encountered the program after enabling multi-languages. Patch #2 solved my problem. Thanks very much!

🇨🇳China hongqing

After further searching, I find it is a duplicate of feature request #923934.

🇨🇳China hongqing

There is the same bug in version 2.0 with D 10.

🇨🇳China hongqing

Thanks for the patch. It works with D10.0.9.

🇨🇳China hongqing

I tested patch #10, it works well with PHP 8.1, MySql 5.7, and Drupal 10.0.9. Thanks.

🇨🇳China hongqing

@TR. Thank you very much. I apply the patch you contributed, now it works with Drupa 10.0.9. I am closing this for it is a duplicate of 3338673 🐛 [10.0] Remove jQuery dependency from the once feature Fixed

🇨🇳China hongqing

Encountered the error again and the report has more information.

Deprecated function: strtolower(): Passing null to parameter #1 ($string) of type string is deprecated in Drupal\commerce_currency_resolver\Resolver\CommerceCurrencyResolver->resolve() (line 101 of /www/wwwroot/myweb/modules/contrib/commerce_currency_resolver/src/Resolver/CommerceCurrencyResolver.php) 
#0 /www/wwwroot/myweb/core/includes/bootstrap.inc(158): _drupal_error_handler_real()
#1 [internal function]: _drupal_error_handler()
#2 /www/wwwroot/myweb/modules/contrib/commerce_currency_resolver/src/Resolver/CommerceCurrencyResolver.php(101): strtolower()
#3 /www/wwwroot/myweb/modules/contrib/commerce/modules/price/src/Resolver/ChainPriceResolver.php(49): Drupal\commerce_currency_resolver\Resolver\CommerceCurrencyResolver->resolve()
#4 /www/wwwroot/myweb/modules/contrib/commerce/modules/order/src/PriceCalculator.php(106): Drupal\commerce_price\Resolver\ChainPriceResolver->resolve()
#5 /www/wwwroot/myweb/modules/contrib/commerce/modules/order/src/Plugin/Field/FieldFormatter/PriceCalculatedFormatter.php(171): Drupal\commerce_order\PriceCalculator->calculate()
#6 /www/wwwroot/myweb/core/lib/Drupal/Core/Field/FormatterBase.php(89): Drupal\commerce_order\Plugin\Field\FieldFormatter\PriceCalculatedFormatter->viewElements()
#7 /www/wwwroot/myweb/core/lib/Drupal/Core/Entity/Entity/EntityViewDisplay.php(265): Drupal\Core\Field\FormatterBase->view()
#8 /www/wwwroot/myweb/core/lib/Drupal/Core/Entity/EntityViewBuilder.php(339): Drupal\Core\Entity\Entity\EntityViewDisplay->buildMultiple()
#9 /www/wwwroot/myweb/core/lib/Drupal/Core/Entity/EntityViewBuilder.php(281): Drupal\Core\Entity\EntityViewBuilder->buildComponents()
#10 /www/wwwroot/myweb/core/lib/Drupal/Core/Entity/EntityViewBuilder.php(238): Drupal\Core\Entity\EntityViewBuilder->buildMultiple()
#11 [internal function]: Drupal\Core\Entity\EntityViewBuilder->build()
#12 /www/wwwroot/myweb/core/lib/Drupal/Core/Security/DoTrustedCallbackTrait.php(101): call_user_func_array()
#13 /www/wwwroot/myweb/core/lib/Drupal/Core/Render/Renderer.php(788): Drupal\Core\Render\Renderer->doTrustedCallback()
#14 /www/wwwroot/myweb/core/lib/Drupal/Core/Render/Renderer.php(374): Drupal\Core\Render\Renderer->doCallback()
#15 /www/wwwroot/myweb/core/lib/Drupal/Core/Render/Renderer.php(204): Drupal\Core\Render\Renderer->doRender()
#16 /www/wwwroot/myweb/core/lib/Drupal/Core/Template/TwigExtension.php(477): Drupal\Core\Render\Renderer->render()
#17 /www/wwwroot/myweb/sites/default/files/php/twig/645bfc4e1b80d_field.html.twig_FT-k8xbvR2ajoh_gP42oEizl-/hwILbJyq0DS0jKfIk3qE98T9QNrvYJslSUOOeEa2pqY.php(68): Drupal\Core\Template\TwigExtension->escapeFilter()
#18 /www/wwwroot/myweb/vendor/twig/twig/src/Template.php(394): __TwigTemplate_883fc710d1c808415b290870817d143e->doDisplay()
#19 /www/wwwroot/myweb/vendor/twig/twig/src/Template.php(367): Twig\Template->displayWithErrorHandling()
#20 /www/wwwroot/myweb/vendor/twig/twig/src/Template.php(379): Twig\Template->display()
#21 /www/wwwroot/myweb/vendor/twig/twig/src/TemplateWrapper.php(40): Twig\Template->render()
#22 /www/wwwroot/myweb/core/themes/engines/twig/twig.engine(53): Twig\TemplateWrapper->render()
#23 /www/wwwroot/myweb/core/lib/Drupal/Core/Theme/ThemeManager.php(372): twig_render_template()
#24 /www/wwwroot/myweb/core/lib/Drupal/Core/Render/Renderer.php(433): Drupal\Core\Theme\ThemeManager->render()
#25 /www/wwwroot/myweb/core/lib/Drupal/Core/Render/Renderer.php(446): Drupal\Core\Render\Renderer->doRender()
#26 /www/wwwroot/myweb/core/lib/Drupal/Core/Render/Renderer.php(446): Drupal\Core\Render\Renderer->doRender()
#27 /www/wwwroot/myweb/core/lib/Drupal/Core/Render/Renderer.php(446): Drupal\Core\Render\Renderer->doRender()
#28 /www/wwwroot/myweb/core/lib/Drupal/Core/Render/Renderer.php(204): Drupal\Core\Render\Renderer->doRender()
#29 /www/wwwroot/myweb/core/lib/Drupal/Core/Template/TwigExtension.php(477): Drupal\Core\Render\Renderer->render()
#30 /www/wwwroot/myweb/sites/default/files/php/twig/645bfc4e1b80d_commerce-product.html.twi_NNI0iGwpIgeDSyLjF1ZOaHZVq/YpDiCXi03JEx4goU51Q33biuAgvW4aghVwGAmeCzFcs.php(50): Drupal\Core\Template\TwigExtension->escapeFilter()
#31 /www/wwwroot/myweb/vendor/twig/twig/src/Template.php(394): __TwigTemplate_ea47ffd63e92996f51b7fb1d1be1e85c->doDisplay()
#32 /www/wwwroot/myweb/vendor/twig/twig/src/Template.php(367): Twig\Template->displayWithErrorHandling()
#33 /www/wwwroot/myweb/vendor/twig/twig/src/Template.php(379): Twig\Template->display()
#34 /www/wwwroot/myweb/vendor/twig/twig/src/TemplateWrapper.php(40): Twig\Template->render()
#35 /www/wwwroot/myweb/core/themes/engines/twig/twig.engine(53): Twig\TemplateWrapper->render()
#36 /www/wwwroot/myweb/core/lib/Drupal/Core/Theme/ThemeManager.php(372): twig_render_template()
#37 /www/wwwroot/myweb/core/lib/Drupal/Core/Render/Renderer.php(433): Drupal\Core\Theme\ThemeManager->render()
#38 /www/wwwroot/myweb/core/lib/Drupal/Core/Render/Renderer.php(204): Drupal\Core\Render\Renderer->doRender()
#39 /www/wwwroot/myweb/core/lib/Drupal/Core/Render/MainContent/HtmlRenderer.php(238): Drupal\Core\Render\Renderer->render()
#40 /www/wwwroot/myweb/core/lib/Drupal/Core/Render/Renderer.php(580): Drupal\Core\Render\MainContent\HtmlRenderer->Drupal\Core\Render\MainContent\{closure}()
#41 /www/wwwroot/myweb/core/lib/Drupal/Core/Render/MainContent/HtmlRenderer.php(239): Drupal\Core\Render\Renderer->executeInRenderContext()
#42 /www/wwwroot/myweb/core/lib/Drupal/Core/Render/MainContent/HtmlRenderer.php(128): Drupal\Core\Render\MainContent\HtmlRenderer->prepare()
#43 /www/wwwroot/myweb/core/lib/Drupal/Core/EventSubscriber/MainContentViewSubscriber.php(90): Drupal\Core\Render\MainContent\HtmlRenderer->renderResponse()
#44 [internal function]: Drupal\Core\EventSubscriber\MainContentViewSubscriber->onViewRenderArray()
#45 /www/wwwroot/myweb/core/lib/Drupal/Component/EventDispatcher/ContainerAwareEventDispatcher.php(111): call_user_func()
#46 /www/wwwroot/myweb/vendor/symfony/http-kernel/HttpKernel.php(168): Drupal\Component\EventDispatcher\ContainerAwareEventDispatcher->dispatch()
#47 /www/wwwroot/myweb/vendor/symfony/http-kernel/HttpKernel.php(74): Symfony\Component\HttpKernel\HttpKernel->handleRaw()
#48 /www/wwwroot/myweb/core/lib/Drupal/Core/StackMiddleware/Session.php(58): Symfony\Component\HttpKernel\HttpKernel->handle()
#49 /www/wwwroot/myweb/core/lib/Drupal/Core/StackMiddleware/KernelPreHandle.php(48): Drupal\Core\StackMiddleware\Session->handle()
#50 /www/wwwroot/myweb/core/modules/page_cache/src/StackMiddleware/PageCache.php(191): Drupal\Core\StackMiddleware\KernelPreHandle->handle()
#51 /www/wwwroot/myweb/core/modules/page_cache/src/StackMiddleware/PageCache.php(128): Drupal\page_cache\StackMiddleware\PageCache->fetch()
#52 /www/wwwroot/myweb/core/modules/page_cache/src/StackMiddleware/PageCache.php(82): Drupal\page_cache\StackMiddleware\PageCache->lookup()
#53 /www/wwwroot/myweb/core/lib/Drupal/Core/StackMiddleware/ReverseProxyMiddleware.php(48): Drupal\page_cache\StackMiddleware\PageCache->handle()
#54 /www/wwwroot/myweb/core/lib/Drupal/Core/StackMiddleware/NegotiationMiddleware.php(51): Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle()
#55 /www/wwwroot/myweb/core/lib/Drupal/Core/StackMiddleware/StackedHttpKernel.php(51): Drupal\Core\StackMiddleware\NegotiationMiddleware->handle()
#56 /www/wwwroot/myweb/core/lib/Drupal/Core/DrupalKernel.php(686): Drupal\Core\StackMiddleware\StackedHttpKernel->handle()
#57 /www/wwwroot/myweb/index.php(19): Drupal\Core\DrupalKernel->handle()
#58 {main}


🇨🇳China hongqing

Thanks for the contribution. It works well with Drupal 10.0.9.

🇨🇳China hongqing

@jsacksick Thanks for your prompt reply. I know how to add and configure the address module, while the Address Field in Store type is not configurable. I looked at the commerce_store_field_data in the database, the street field is optional, but it is required in the form display. That's why I ask how to change it.

🇨🇳China hongqing

Patch #3 fix fixed the error, but the default value is not set on the form display even though a default value is set.

Production build 0.71.5 2024