On saving a region, images disappear

  • I am using XAMPP to test a site locally. When I edit a region then save it, all images in that region disappear. By this I mean it is as if I had not added any images. It was working as it should for a while until it started behaving like this.


    When the region is opened, all the images are present. On clicking 'Save' they disappear. On visiting the html page, the src of the img tag(s) is/are empty while that of alt is present. Clicking Undo on the region rolls it back and restores the image(s).


    On making any change to a text field and saving the region, such a change appears on the resulting HTML page, so it is saving.


    I am running XAMPP Control Panel V3.2.24 with PHP 7.3.25 and MariaDB V10.4.17 in Windows 7 SP1 Premium 64 bit.


    Examination of the JSON stored in the database for the two revisions reveals the following. These are excerpts which begin and end at the same point. As you can see, the latter is missing some data.


    The immediate prior revision, with the image present:

    Code
    1. "product_name":"Physio high back 24 hour task chair (PH1)","product_image":{"assetID":"8021","title":"Physio high back 24 hour task chair ph1 1","_default":"\/images\/seating\/physio-high-back-24-hour-task-chair-ph1-1.jpg","bucket":"imgSeating","path":"physio-high-back-24-hour-task-chair-ph1-1.jpg","size":11256,"w":327,"h":448,"mime":"image\/jpeg","sizes":{"thumb":{"w":"109","h":"150","target_w":150,"target_h":150,"density":2,"path":"physio-high-back-24-hour-task-chair-ph1-1-thumb@2x.jpg","size":8349,"mime":"","assetID":"8022"}}},"alt":"Physio high back 24 hour task chair (PH1)","price":"465.50"


    The latest revision where the image has disappeared:

    Code
    1. "product_name":"Physio high back 24 hour task chair (PH1)","product_image":{"assetID":"8021","title":"Physio high back 24 hour task chair ph1 1","_default":"\/images\/seating\/physio-high-back-24-hour-task-chair-ph1-1.jpg","bucket":"imgSeating"},"alt":"Physio high back 24 hour task chair (PH1)","price":"465.50"
  • Gareth S

    Approved the thread.
  • Thanks for replying Clive, and apologies for the delay in responding. It appears the issue may be caused by corruption of some of the database tables.


    I tried myisamchk (the check and repair tool) with various parameters and it made no difference. Running -r for recover resulted in it finding some errors and supposedly recovering them, only for the same thing to happen when it was run again.


    I am working on restoring the database from a copy.


    I think that it may have got corrupted when XAMPP crashed out. I was getting the error about not being able to create xampp-control.ini, a common issue it would seem. Each time I found the only way out was to end the process through Task Manager. I have rectified this and XAMPP now closes without issue.