Drupal has a form cache that maintains uniqueness of form ids (a good thing) but there seems to be an issue with the Panels IPE where if you save the IPE that it double builds the form (or at least doesnt reset the cache) resulting in the form having a non-standard form (i.e. #edit-submit--1) which breaks various CSS.

This use to be a much wider problem, but #1555352: Panels IPE Doesn't Maintain Form IDs solved in during general IPE usage. However, when a user *saves* the IPE it causes this issue. This can be seen in Panopoly Demo when you edit/save the front page since Bartik has custom CSS for the #search-form #edit-submit which doesn't work on #search-form #edit-submit--1.

This is probably going to ultimately be a patch to the Panels IPE module.

CommentFileSizeAuthor
#2 1711494-double-ids.patch1.18 KBbeeradb

Comments

populist’s picture

Assigned: Unassigned » beeradb
beeradb’s picture

Project: Panopoly » Panels
Version: 7.x-1.x-dev » 7.x-3.x-dev
Status: Active » Needs review
StatusFileSize
new1.18 KB

This looks to be fixed by moving the clear of $_POST['ajax_html_ids'] = array(); to happen a bit earlier. This fixes the double id generation issue for me, and I can't find any repercussions to doing it (at least within Panopoly).

merlinofchaos’s picture

Status: Needs review » Fixed

Committed, pushed!

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

  • Commit e7a7fc8 on 7.x-3.x, 7.x-3.x-i18n, 8.x-3.x authored by beeradb, committed by merlinofchaos:
    Issue #1711494 by beeradb: Prevent Double Form Building on Panels IPE...