<commit_before><?php
/*-------------------------------------------------------+
| PHP-Fusion Content Management System
| Copyright (C) PHP-Fusion Inc
| https://www.php-fusion.co.uk/
+--------------------------------------------------------+
| File Category: Core Rewrite Modules
| Author: Hien (<NAME>)
+--------------------------------------------------------+
| This program is released as free software under the
| Affero GPL license. You can redistribute it and/or
| modify it under the terms of this license which you
| can read by viewing the included agpl.txt or online
| at www.gnu.org/licenses/agpl.html. Removal of this
| copyright header is strictly prohibited without
| written permission from the original author(s).
+--------------------------------------------------------*/
if (!defined("IN_FUSION")) { die("Access Denied"); }

$regex = array(
	"%album_id%" => "([0-9]+)",
	"%album_title%" => "([0-9a-zA-Z._\W]+)",
    "%photo_id%" => "([0-9]+)",
    "%photo_title%" => "([0-9a-zA-Z._\W]+)",
    "%rowstart%" => "([0-9]+)",
    "%c_start%" => "([0-9]+)",
    "%s_type%" => "(p)",
    "%comment_id%" => "([0-9]+)",
    "%hash_stop%" => "\#(?=\s*|)",
);

$pattern = array(
    "gallery/browse/%rowstart%" => "infusions/gallery/gallery.php?rowstart=%rowstart%",
    "gallery/browse/%album_id%/%rowstart%" => "infusions/gallery/gallery.php?album_id=%album_id%&amp;rowstart=%rowstart%",
    "photo/comments-%c_start%/%photo_id%/%photo_title%" => "infusions/gallery/gallery.php?photo_id=%photo_id%&amp;c_start=%c_start%",
    "photo/%photo_id%/%photo_title%" => "infusions/gallery/gallery.php?photo_id=%photo_id%",
    "submit/photos" => "submit.php?stype=%s_type%",
    "gallery/%album_id%/%album_title%" => "infusions/gallery/gallery.php?album_id=%album_id%",
    "gallery" => "infusions/gallery/gallery.php",
);


$pattern_tables["%album_id%"] = array(
    "table" => DB_PHOTO_ALBUMS,
    "primary_key" => "album_id",
    "id" => array("%album_id%" => "album_id"),
    "columns" => array(
        "%album_title%" => "album_title"
    )
);

$pattern_tables["%photo_id%"] = array(
    "table" => DB_PHOTOS,
    "primary_key" => "photo_id",
    "id" => array("%photo_id%" => "photo_id"),
    "columns" => array(
        "%photo_title%" => "photo_title"
    )
);<commit_msg>#505 - Photo driver update (submit)<commit_after><?php
/*-------------------------------------------------------+
| PHP-Fusion Content Management System
| Copyright (C) PHP-Fusion Inc
| https://www.php-fusion.co.uk/
+--------------------------------------------------------+
| File Category: Core Rewrite Modules
| Author: Hien (<NAME>)
+--------------------------------------------------------+
| This program is released as free software under the
| Affero GPL license. You can redistribute it and/or
| modify it under the terms of this license which you
| can read by viewing the included agpl.txt or online
| at www.gnu.org/licenses/agpl.html. Removal of this
| copyright header is strictly prohibited without
| written permission from the original author(s).
+--------------------------------------------------------*/
if (!defined("IN_FUSION")) { die("Access Denied"); }

$regex = array(
	"%album_id%" => "([0-9]+)",
	"%album_title%" => "([0-9a-zA-Z._\W]+)",
    "%photo_id%" => "([0-9]+)",
    "%photo_title%" => "([0-9a-zA-Z._\W]+)",
    "%rowstart%" => "([0-9]+)",
    "%c_start%" => "([0-9]+)",
    "%stype%" => "(p)",
    "%comment_id%" => "([0-9]+)",
    "%hash_stop%" => "\#(?=\s*|)",
);

$pattern = array(
    "submit/%stype%/photos" => "submit.php?stype=%stype%",
    "submit/%stype%/photos/submitted-and-thank-you" => "submit.php?stype=%stype%&amp;submitted=p",

    "gallery/browse/%rowstart%" => "infusions/gallery/gallery.php?rowstart=%rowstart%",
    "gallery/browse/%album_id%/%rowstart%" => "infusions/gallery/gallery.php?album_id=%album_id%&amp;rowstart=%rowstart%",
    "photo/comments-%c_start%/%photo_id%/%photo_title%" => "infusions/gallery/gallery.php?photo_id=%photo_id%&amp;c_start=%c_start%",
    "photo/%photo_id%/%photo_title%" => "infusions/gallery/gallery.php?photo_id=%photo_id%",
    "gallery/%album_id%/%album_title%" => "infusions/gallery/gallery.php?album_id=%album_id%",
    "gallery" => "infusions/gallery/gallery.php",
);


$pattern_tables["%album_id%"] = array(
    "table" => DB_PHOTO_ALBUMS,
    "primary_key" => "album_id",
    "id" => array("%album_id%" => "album_id"),
    "columns" => array(
        "%album_title%" => "album_title"
    )
);

$pattern_tables["%photo_id%"] = array(
    "table" => DB_PHOTOS,
    "primary_key" => "photo_id",
    "id" => array("%photo_id%" => "photo_id"),
    "columns" => array(
        "%photo_title%" => "photo_title"
    )
);
{'fraction_non_alphanumeric': 0.29867916489135066, 'fraction_numerical': 0.006604175543246698, 'mean_word_length': 2.807785888077859, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 62, 'https://': 2, 'lorem ipsum': 0, 'www.': 4, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5210962', 'n_tokens_mistral': 1656, 'n_tokens_neox': 1593, 'n_words': 280}