[fix] Yet more fallout from the PHP8.1 stuff

master
Solomon Peachy 1 week ago
parent 133e21bc46
commit f7c0c14163
  1. 1
      src/admin.volume.edit.php
  2. 3
      src/album.del.2.php
  3. 3
      src/album.edit.2.php
  4. 3
      src/bulk.update.php
  5. 1
      src/camera.add.2.php
  6. 1
      src/film.add.2.php
  7. 3
      src/folder.content.php
  8. 3
      src/folder.del.2.php
  9. 3
      src/folder.edit.2.php
  10. 1
      src/location.add.2.php
  11. 4
      src/location.del.2.php
  12. 4
      src/location.edit.2.php
  13. 1
      src/manufacturer.add.2.php
  14. 5
      src/manufacturer.del.2.php
  15. 2
      src/manufacturer.del.php
  16. 4
      src/manufacturer.edit.2.php
  17. 2
      src/manufacturer.edit.php

@ -21,7 +21,6 @@
include_once "include/config.php";
include_once "include/admin.php";
include_once "include/site.php";
;
include_once "include/common.php";
$database = site_prolog(PO_USER_TYPE_ADMIN);

@ -20,9 +20,10 @@
include_once "include/config.php";
include_once "include/site.php";
$database = site_prolog(PO_USER_TYPE_CLIENT);
$album_id = pg_escape_string($database, $_REQUEST['album']);
$database = site_prolog(PO_USER_TYPE_CLIENT);
$go = TRUE;
/* Ensure mere users don't erase an album that isn't theirs! */

@ -20,6 +20,8 @@
include_once "include/config.php";
include_once "include/site.php";
$database = site_prolog(PO_USER_TYPE_CLIENT);
$album_id = pg_escape_string($database, $_REQUEST['album']);
$album_name = pg_escape_string($database, $_REQUEST['album_caption']);
$album_description = pg_escape_string($database, $_REQUEST['album_description']);
@ -32,7 +34,6 @@ $keep_thumb = $_REQUEST['keep_thumb'];
if ($event != "null") $event = "'$event'";
$database = site_prolog(PO_USER_TYPE_CLIENT);
$go = TRUE;
/* Ensure mere users don't edit an album that isn't theirs! */

@ -24,6 +24,8 @@ include_once "include/common.php";
include_once "include/site.php";
include_once "include/import.php";
$database = site_prolog(PO_USER_TYPE_USER);
$select_folder = pg_escape_string($database, $_REQUEST['select_folder']);
$select_album = pg_escape_string($database, $_REQUEST['select_album']);
$type = isset($_REQUEST['type']) ? $_REQUEST['type'] : FALSE;
@ -35,7 +37,6 @@ $set_generate_images = $_REQUEST['set_generate_images'];
$compress_pages = false; /* Explicitly disable it here */
set_time_limit(0); /* Explicitly disable timeouts here */
$database = site_prolog(PO_USER_TYPE_USER);
if (!sizeof($to_update) && ($set_generate_images != 't')) {
site_push_error($strings['errors_invalid_options']);

@ -22,7 +22,6 @@ include_once "include/config.php";
include_once "include/profile.php";
include_once "include/calendar.php";
include_once "include/site.php";
;
function add_camera($database, $user_id,
$camera_type_id, $camera_manufacturer_id, $camera_model, $camera_variation,

@ -21,7 +21,6 @@
include_once "include/config.php";
include_once "include/profile.php";
include_once "include/site.php";
;
function add_film($database, $user_id, $film_type_id, $film_manufacturer_id,
$film_model, $film_iso, $film_format_id, $film_access_rights) {

@ -21,9 +21,10 @@ include_once "include/config.php";
include_once "include/site.php";
include_once "include/import.php";
$database = site_prolog();
$return_path = isset($_REQUEST['return']) ? $_REQUEST['return'] : "";
$database = site_prolog();
$owner_id = isset($_REQUEST['user']) ? $_REQUEST['user'] : 0;
$destination_folder = pg_escape_string($database, isset($_REQUEST['destination_folder']) ? $_REQUEST['destination_folder'] : "");

@ -20,10 +20,11 @@
include_once "include/config.php";
include_once "include/site.php";
$database = site_prolog(PO_USER_TYPE_USER);
$folder_id = pg_escape_string($database, $_REQUEST['folder']);
$parent_folder = $_REQUEST['parent'];
$database = site_prolog(PO_USER_TYPE_USER);
$go = TRUE;
/* Ensure mere users don't erase an folder that isn't theirs! */

@ -20,6 +20,8 @@
include_once "include/config.php";
include_once "include/site.php";
$database = site_prolog(PO_USER_TYPE_USER);
$folder_id = pg_escape_string($database, $_REQUEST['folder']);
$folder_name = pg_escape_string($database, $_REQUEST['folder_caption']);
$folder_description = pg_escape_string($database, $_REQUEST['folder_description']);
@ -32,7 +34,6 @@ $keep_thumb = $_REQUEST['keep_thumb'];
if ($event != "null") $event = "'$event'";
$database = site_prolog(PO_USER_TYPE_USER);
/* Ensure mere users don't edit an folder that isn't theirs! */
if ($po_user['type'] != PO_USER_TYPE_ADMIN) {

@ -21,7 +21,6 @@
include_once "include/config.php";
include_once "include/profile.php";
include_once "include/site.php";
;
$database = site_prolog(PO_USER_TYPE_USER);

@ -21,10 +21,10 @@ include_once "include/config.php";
include_once "include/profile.php";
include_once "include/site.php";
$location_id = pg_escape_string($database, $_REQUEST['location']);
$database = site_prolog(PO_USER_TYPE_USER);
$location_id = pg_escape_string($database, $_REQUEST['location']);
if ($location_id!="") {
/* Ensure the user owns it !*/
if ($po_user['type'] != PO_USER_TYPE_ADMIN) {

@ -21,6 +21,8 @@ include_once "include/config.php";
include_once "include/profile.php";
include_once "include/site.php";
$database = site_prolog(PO_USER_TYPE_USER);
$location_id = $_REQUEST['location'];
$location_name = pg_escape_string($database, $_REQUEST['location_name']);
$location_city = pg_escape_string($database, $_REQUEST['location_city']);
@ -30,8 +32,6 @@ $location_latitude = pg_escape_string($database, parse_latitude($_REQUEST['loca
$location_longitude = pg_escape_string($database, parse_latitude($_REQUEST['location_longitude']));
$location_private = pg_escape_string($database, $_REQUEST['private']);
$database = site_prolog(PO_USER_TYPE_USER);
if ($location_id!="") {
/* Ensure the user owns it !*/
if ($po_user['type'] != PO_USER_TYPE_ADMIN) {

@ -21,7 +21,6 @@
include_once "include/config.php";
include_once "include/profile.php";
include_once "include/site.php";
;
$database = site_prolog(PO_USER_TYPE_USER);

@ -21,12 +21,11 @@
include_once "include/config.php";
include_once "include/profile.php";
include_once "include/site.php";
;
$manufacturer_id = pg_escape_string($database, $_REQUEST['manufacturer']);
$database = site_prolog(PO_USER_TYPE_USER);
$manufacturer_id = pg_escape_string($database, $_REQUEST['manufacturer']);
if ($manufacturer_id!="") {
/* Ensure the user owns it !*/
if ($po_user['type'] != PO_USER_TYPE_ADMIN) {

@ -24,7 +24,7 @@ include_once "include/common.php";
$database = site_prolog(PO_USER_TYPE_USER);
$manufacturer_id=pg_escape_string($database, $_REQUEST['item']);
$manufacturer_id = pg_escape_string($database, $_REQUEST['item']);
/* Ensure the user owns it !*/
if ($po_user['type'] != PO_USER_TYPE_ADMIN) {

@ -22,12 +22,12 @@ include_once "include/config.php";
include_once "include/profile.php";
include_once "include/site.php";
$database = site_prolog(PO_USER_TYPE_USER);
$manufacturer_id = pg_escape_string($database, $_REQUEST['manufacturer']);
$manufacturer_name = pg_escape_string($database, $_REQUEST['manufacturer_name']);
$manufacturer_url = pg_escape_string($database, $_REQUEST['manufacturer_url']);
$database = site_prolog(PO_USER_TYPE_USER);
if (($manufacturer_id!="") && ($manufacturer_name!="")) {
if ($po_user['type'] != PO_USER_TYPE_ADMIN) {
$result = pg_fetch_row(pg_query($database, "select count(identifier) from manufacturer where identifier=$manufacturer_id and last_modifying_users=$po_user[id]"));

@ -24,7 +24,7 @@ include_once "include/common.php";
$database = site_prolog(PO_USER_TYPE_USER);
$manufacturer_id=pg_escape_string($database, $_REQUEST['item']);
$manufacturer_id = pg_escape_string($database, $_REQUEST['item']);
$manufacturer = pg_fetch_row(pg_query($database, "select name, url, last_modifying_users from manufacturer where identifier=$manufacturer_id"));
/* Ensure the user owns it !*/

Loading…
Cancel
Save