We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 12151
    • 115 Posts
    Greetings

    There are many occasions when a pagetitle has a title like "Products & Services". Unless this is changed within MODx to "Products & Services" (and a client is unlikely to know about this or remember if instructed) then any carefully developed valid XHTML immediately fails using Wayfinder.

    I would like to suggest that you add a parameter for htmlspecialchars encoding of fields for menu names and titles.

    I have done so for my installation but I think this would be a very useful parameter going forward?

    Wayfinder snippet ($wf->_config array):

    'htmlspecialchars' => isset($htmlspecialchars) && ($htmlspecialchars=='1') ? TRUE : FALSE,


    Wayfinder include (line 396, v2.0)

    $tempDocInfo['linktext'] = ($this->_config['htmlspecialchars']) ? htmlspecialchars($tempDocInfo[$useTextField], ENT_QUOTES) : $tempDocInfo[$useTextField];
    $tempDocInfo['title'] = ($this->_config['htmlspecialchars']) ? htmlspecialchars($tempDocInfo[$this->_config['titleOfLinks']], ENT_QUOTES) : $tempDocInfo[$this->_config['titleOfLinks']];


    Thanks! smiley