ZF-10409: Zend_View_Helper_Navigation_HelperAbstract#_normalizeId(...): prefixes of A-tag IDs

Issue Type: Sub-task Created: 2010-09-02T05:11:20.000+0000 Last Updated: 2012-06-19T20:43:41.000+0000 Status: Closed Fix version(s): - 1.12.0 (27/Aug/12)

Reporter: Ilya Khanataev (automatix) Assignee: Frank Brückner (frosch) Tags: - Zend_Navigation

  • FixForZF1.12
  • zf-crteam-padraic
  • zf-crteam-priority
  • zf-crteam-review

Related issues: Attachments:


The method Zend_View_Helper_Navigation_HelperAbstract#_normalizeId($value) builds IDs for the anchor tags of the navigation elements according to the following pattern:

$prefix + "-" + $value

The developer can just set the $value. The $prefix is always the lower cased name of the navigation helper type (e.g. "menu" for Menu or "breadcrumbs" for Breadcrumbs).

It would be great to have the ability to customize the complete ID and not only the part after the hyphen.


Posted by Kai Uwe (kaiuwe) on 2011-02-16T02:55:08.000+0000

The patch should include the following points:

  • Zend_View_Helper_Navigation_HelperAbstract gets a new property "prefixForId" and getter and setter for this property
  • Zend_View_Helper_Navigation_HelperAbstract gets a new option to skip the prefix (bool)
  • Zend_View_Helper_Navigation_HelperAbstract::_normalizeId() uses/extends Zend_View_Helper_HtmlElement::_normalizeId()

Posted by Frank Brückner (frosch) on 2012-06-17T08:04:44.000+0000

Fixed in trunk (1.12.0): r24962 (by Adam Lundrigan)

Have you found an issue?

See the Overview section for more details.


© 2006-2018 by Zend, a Rogue Wave Company. Made with by awesome contributors.

This website is built using zend-expressive and it runs on PHP 7.