Jump to content

Needing to save twice in front-end editor [SOLVED]


Recommended Posts

For some reason, in the new site I am building, every time I use the front-end editor on a field, I have to save the changes twice - the first time just reloads the module with the previous value. I've not come across this before. I disabled hooks and auto-save but it still happens. Any ideas?

Link to comment
Share on other sites

  • 3 weeks later...

A bit more info. In fact the first save is OK, but returns to the modal with the original value. If I just close the modal (i.e do not change and re-save) then the change has been made. I have no idea why it returns to the (unchanged) modal rather than the FE page - poking around in FEE but no light yet.

I also notice that if I click the close x  immeditelay after loading the modal, the background lightens and then any changes (followed by clicking 'save') are taken and the modal closes. Seems like something to do the the js, but still in the dark

Link to comment
Share on other sites

Further info (in what seems to be a monologue so far 😉 )

What is actually happening is that PW is opening TWO modals when I double click the item. The HTML looks perfectly OK - e.g. (from developer tools after PW has applied its classes etc.)

<div id="pw-edit-modal-1017-100-104-107-113" class="pw-modal pw-modal-dblclick pw-edit-modal" data-href="/processwire/page/edit/?id=1017&amp;fields=weight,volume,gravity,acidity&amp;modal=1" data-fields="weight,volume,gravity,acidity" data-buttons="button.ui-button[type=submit]" data-autoclose="">
    <p><span style="font-weight: bold">Default units: </span>
    Weight: pound        , Volume: litre        , Gravity: SG        , Acidity: ppt malic</p>

The work-round is just to close one modal and then work in the other one, but why is it happening ....?

SOLVED (sort of) Something was wrong in my front-end template - possibly mis-matching div tags. Code double checked and all ok now

Link to comment
Share on other sites

  • MarkE changed the title to Needing to save twice in front-end editor [SOLVED]

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...