The page break function causes problems for Sarafi in that the button labels have "<" and ">" in them.

The code being generated looks like this:

<button type="submit" name="_op" id="edit-next" value="Next Page >" class="Button form-submit"><span class="btn  "><span class="l"></span><span class="r"></span><span class="t">Next Page ></span></span></button>

Where:

value="Next Page >"

needs to be:

value="Next Page"

This can be corrected in the webform.module file at line 1611 and 1612, as well as in any and all translation .po files.

if ($page_count > 1) {
    $next_page = t('Next Page >');
    $prev_page = t('< Previous Page');
    ....
}

Can you guys advise on how you think that this can best be applied into the code?

Thanks,

Comments

quicksketch’s picture

Title: page break form component breaks safari » Arrow brackets < and > in buttons break Safari

Either that or we simply need to HTML entity encode < as &lt;. Thanks for the report, though I've never had this problem myself despite using Safari regularly. I'll see if using the encodings have any negative effect.

quicksketch’s picture

Category: bug » support
Status: Active » Closed (cannot reproduce)

I cannot reproduce this issue. It looks to me like the only way this would possibly happen would be if your theme overrode theme_button() in template.php to remove the call to check_plain() on the button's value. This should escape any special characters like < into &lt; already.

See http://api.lullabot.com/theme_button