• Resolved codecide

    (@codecide)


    Hi,
    Can you add a getter method to retrieve the base restriction for a mapped domain? The objects are private so the property cannot be accessed within a hook/action. Or is there another way to access the property that I didn’t see?

    Thank you

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Contributor Gustavo Straube

    (@gustavostraube)

    Hello @codecide

    The latest release (0.10.3) adds a new public method called getDomainBase. It expects one optional param, the domain name. In case you call it without passing a domain name, it’ll get the base path for the current domain.

    Sample usage:

    $multipleDomain = MultipleDomain::instance();  
    $baseForCurrentDomain = $multipleDomain->getDomainBase();  
    $baseForExampleDotCom = $multipleDomain->getDomainBase('example.com');  
    
    Thread Starter codecide

    (@codecide)

    That’s great. Thank you very much.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Getter for base restriction param’ is closed to new replies.