3

How can i add more pages that can be accessed like a contact us page with website restriction turned on

UPDATE

Found a file \vendor\magento\module-website-restriction\etc\webrestrictions.xml

How would i add my action to that xml without editing core file

1 Answer 1

2

In your custom-module , create a file \etc\webrestrictions.xml and add the required action path

<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_WebsiteRestriction:etc/webrestrictions.xsd">

    <action path="customer_account_createpost" type="register" />
</config>
1
  • I have the website restrictions set to website closed and I'm trying to allow access to example.com/newsletter/subscriber/new. I'm using path="newsletter_manage_index" but it doesn't work. Am I doing something wrong?
    – Radu
    Commented Sep 24, 2021 at 23:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.