public function getHref() {

		if(is_null($this->href)) {

			if($this->localPage) {

				$pathSegments = [];
				$e = $this;

				do {
					$pathSegments[] = $e->path;
				} while ($e = $e->menu->getParentEntry());

				if(Application::getInstance()->getRouter()->getServerSideRewrite()) {

					if(($script = basename($this->menu->getScript(), '.php')) == 'index') {
						$script = '/';
					}

					else {
						$script = '/'. $script . '/';
					}
				}

				else {
					$script = '/' . $this->menu->getScript() . '/';
				}

				$this->href = $script . implode('/', array_reverse(array_map('rawurlencode', $pathSegments)));

			}

			else {

				$this->href = $this->path;

			}
		}

		return $this->href;
	}
public function getHref() {

		if(is_null($this->href)) {

			if($this->localPage) {

				$pathSegments = [];
				$e = $this;

				do {
					$pathSegments[] = $e->path;
				} while ($e = $e->menu->getParentEntry());

				if(Application::getInstance()->getRouter()->getServerSideRewrite()) {

					if(($script = basename($this->menu->getScript(), '.php')) == 'index') {
						$script = '/';
					}

					else {
						$script = '/'. $script . '/';
					}
				}

				else {
					$script = '/' . $this->menu->getScript() . '/';
				}

				$this->href = $script . implode('/', array_reverse(array_map('rawurlencode', $pathSegments)));

			}

			else {

				$this->href = $this->path;

			}
		}

		return $this->href;
	}
public function getHref ( ) { if ( is_null ( $ this -> href ) ) { if ( $ this -> localPage ) { $ pathSegments = [ ] ; $ e = $ this ; do { $ pathSegments [ ] = $ e -> path ; } while ( $ e = $ e -> menu -> getParentEntry ( ) ) ; if ( Application :: getInstance ( ) -> getRouter ( ) -> getServerSideRewrite ( ) ) { if ( ( $ script = basename ( $ this -> menu -> getScript ( ) , '.php' ) ) == 'index' ) { $ script = '/' ; } else { $ script = '/' . $ script . '/' ; } } else { $ script = '/' . $ this -> menu -> getScript ( ) . '/' ; } $ this -> href = $ script . implode ( '/' , array_reverse ( array_map ( 'rawurlencode' , $ pathSegments ) ) ) ; } else { $ this -> href = $ this -> path ; } } return $ this -> href ; }
get href attribute value of menu entry
get href attribute value of menu entry