MOON
Server: Apache
System: Linux server.royaltuning.hu 4.18.0-425.13.1.el8_7.x86_64 #1 SMP Tue Feb 21 04:20:52 EST 2023 x86_64
User: royaltuning (1001)
PHP: 8.2.30
Disabled: exec,passthru,shell_exec,system
Upload Files
File: /home/royaltuning/www/public/wp-content/uploads/wpallexport/functions.php
<?php
function getNetto($price)
{
    $netto = round($price / 1.27);

    return $netto;
}

function getCategoryId($product_id)
{
    $terms = get_the_terms($product_id, 'product_cat');

    $cat_id = [];
    foreach ($terms as $term) {

        $cat_id[] = $term->term_id;
    }

    return implode(",", $cat_id);
}

function delete_all_between($beginning, $end, $string)
{
    $string = strip_tags($string);
    $beginningPos = strpos($string, $beginning);
    $endPos = strpos($string, $end);
    if ($beginningPos === false || $endPos === false) {
        return $string;
    }

    $textToDelete = substr($string, $beginningPos, ($endPos + strlen($end)) - $beginningPos);

    return delete_all_between($beginning, $end, str_replace($textToDelete, '', $string));
}

?>