Nextras\SecuredLinks a Call to undefined method …::createSecuredLink()

Notice: This thread is very old.
Facedown
Member | 38
+
0
-

Hi,

I use last version of Nette and PHP 7 and I'm trying to run Nextras\SecuredLinks but I still get an error:

Call to undefined method Bulletpoint\Page\DefaultPage::createSecuredLink()

Part from compiled view:

title="bulletpoint" href="<?php echo Latte\Runtime\Filters::escapeHtml($_control->link("Default:"), ENT_COMPAT) ?>

This is also the first link in my layout.latte.

My BasePresenter(BasePage):

abstract class BasePage extends Nette\Application\UI\Presenter {
    use \Nextras\Application\UI\SecuredLinksControlTrait;
}

Thank you for response.

CZechBoY
Member | 3608
+
+2
-

You should probably use trait for Presenter instead of Control.

use \Nextras\Application\UI\SecuredLinksPresenterTrait;
Facedown
Member | 38
+
0
-

CZechBoY wrote:

You should probably use trait for Presenter instead of Control.

use \Nextras\Application\UI\SecuredLinksPresenterTrait;

Great, thanks!