The following warnings occurred:
Warning [2] Undefined variable $unreadreports - Line: 26 - File: global.php(961) : eval()'d code PHP 8.1.2-1ubuntu2.18 (Linux)
File Line Function
/global.php(961) : eval()'d code 26 errorHandler->error
/global.php 961 eval
/printthread.php 16 require_once



UserSpice
Page Permission Bug (volatile) - Printable Version

+- UserSpice (https://userspice.com/forums)
+-- Forum: Support Center (https://userspice.com/forums/forumdisplay.php?fid=23)
+--- Forum: UserSpice 4.3 and Below (https://userspice.com/forums/forumdisplay.php?fid=26)
+--- Thread: Page Permission Bug (volatile) (/showthread.php?tid=862)



Page Permission Bug (volatile) - sanbuild - 11-30-2017

Hi,
I have a problem similar to topic reply #6796 in that pages are disappearing from the database & admin panel, however this did topic not show the solution.

I have a folder with files, and have added the path, I have been controlling the pages via the page permissions panel in admin ,however the pages are volatile. They can be recorded both in the database and the admin, only to disappear within 15 minutes or several login/out cycles.

I have followed your comments about adding the init/header lines etc & putting the path of the folders in the z_us_root path ,ie

From: Controlled Pages:
<?php //DO NOT DELETE THIS FILE.&
require_once 'users/init.php';
require_once $abs_us_root.$us_url_root.'users/includes/header.php';
require_once $abs_us_root.$us_url_root.'users/includes/navigation.php';
if (!securePage($_SERVER['PHP_SELF'])){die();}

From z_us_root:
$path=['','users/','usersc/','snag1/','snag2/'];
//Only add or remove values in the $path variable separated by commas above


I have seen the pages in the database together with the permissions, and later they disappear my pages db is now showing an id of 302, the id between 77 and 302 have been previously logged and now automatically dropped the data with empty rows.

Any advice appreciated,
Steve


Page Permission Bug (volatile) - Brandin - 11-30-2017

In your z_us_root you have backticks instead of single quotes. Change that line to this:
$page=['users/','usersc/','snag1/','snag2/'];


Page Permission Bug (volatile) - sanbuild - 11-30-2017

Hi Brandin,
I have previously checked this from the comments by mudmin, my code is the same as he pasted into pastebin, and the actual file, I copied the file syntax as well to double check.

Have you anything else I can try, I ran this on on ver 4.2 and it holds OK!

Regards
Steve


Page Permission Bug (volatile) - Brandin - 11-30-2017

Can you post this on hastebin.com instead?