Author Topic: OneForAll deletes its own page  (Read 86 times)

Offline CodeALot

  • Posts: 392
  • Gender: Male
OneForAll deletes its own page
« on: February 12, 2019, 03:51:55 PM »
On several sites using OneForAll I noticed that, for reasons unknown to me, the 'source'page where the OFA-module resides, can disappear if the user (admin/editor) does "something" wrong. What they do, I don't know. All I know is that the pagefile disappears and that is annoying.

So what do I mean?
  • OFA is the only section on page "Example"
  • On the webserver, there is a file called /pages/example.php
  • If the admin or any other editor adds a record/item to the OFA module and does "something" wrong (NO idea what, I can't reproduce the error) the file /pages/example.php is deleted.
  • To solve this, I have to go into SFTP and copy the file again from my local backup.

What can I do to prevent this from happening? Can I 'lock' the file using read/write rights? This file never needs to be edited anyway, so why not "glue" it into place?

Offline dbs

  • Betatester
  • **
  • Posts: 7658
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: OneForAll deletes its own page
« Reply #1 on: February 12, 2019, 04:02:56 PM »
Which old version of OFA you use?
The latest version from Add-ons Repo don't do this.

Offline Ruud

  • Posts: 3647
  • Gender: Male
  • Do not use PM for help! Please use the forum!
    • Dev4Me - Professional WebsiteBaker Development
Re: OneForAll deletes its own page
« Reply #2 on: February 12, 2019, 04:20:58 PM »
I used v 1.0.9 a lot and have seen the same problem. It sometimes happens whenever a new item is created.
I also could not reproduce the problem, but the simpel fix to restore the overviewpage is to go into the settings of that page and click the "save" button.



Offline CodeALot

  • Posts: 392
  • Gender: Male
Re: OneForAll deletes its own page
« Reply #3 on: February 12, 2019, 04:33:01 PM »
but the simpel fix to restore the overviewpage is to go into the settings of that page and click the "save" button.
Ah that's a good one :)

Offline CodeALot

  • Posts: 392
  • Gender: Male
Re: OneForAll deletes its own page
« Reply #4 on: February 12, 2019, 04:35:11 PM »
Which old version of OFA you use?
The latest version from Add-ons Repo don't do this.
It's not the latest version, but because many modifications were made (not in the modify-scripts but in the viewing scripts) upgrading is not an option. I was mostly wondering how this could be happening and what could be done to prevent it.

info.php claims it's 1.0.9

Offline dbs

  • Betatester
  • **
  • Posts: 7658
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: OneForAll deletes its own page
« Reply #5 on: February 12, 2019, 04:45:12 PM »
I also know the bug and was pleased that Dietmar could fix it in the following versions. But I also know that upgrades are difficult when you have made your own adjustments.
My solution was like yours, copy a backup of the accessfile to /pages.

Offline CodeALot

  • Posts: 392
  • Gender: Male
Re: OneForAll deletes its own page
« Reply #6 on: February 12, 2019, 08:19:49 PM »
Thanks dbs for your replies. Maybe if Dietmar could reveal what caused the bug, I may be able to fix my version?

Offline CodeALot

  • Posts: 392
  • Gender: Male
Re: OneForAll deletes its own page
« Reply #7 on: February 12, 2019, 08:22:26 PM »
v 1.0.7 already mentions:
Bugfix: For items without access file the field link is empty and hence the page access file will be deleted instead of the item access file (reported by dbs, thanks to Ruud)


Sounds like my problem, although I am using 1.0.9... (confused now :-)