Changeset 992 in ExiteCMS for trunk/administration/download_cats.php


Ignore:
Timestamp:
10/23/07 12:18:49 (5 years ago)
Author:
hverton
Message:

Added a checkbox to force the update of the category datestamp

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/administration/download_cats.php

    r861 r992  
    8787        $cat_cat_sorting = "download_cat_id DESC"; 
    8888    } 
    89     $cat_datestamp = time(); 
     89    $update_datestamp = isNum($_POST['update_datestamp']) ? true : false; 
    9090    if (cat_not_recursive($cat_id, $cat_sub)) { 
    9191        if (isset($step) && $step == "edit") { 
    92             $result = dbquery("UPDATE ".$db_prefix."download_cats SET download_cat_name='$cat_name', download_cat_description='$cat_description', download_cat_sorting='$cat_sorting', download_cat_cat_sorting='$cat_cat_sorting', download_cat_access='$cat_access', download_cat_image='$cat_image', download_parent='$cat_sub', download_datestamp='$cat_datestamp' WHERE download_cat_id='$cat_id'"); 
     92            $result = dbquery("UPDATE ".$db_prefix."download_cats SET download_cat_name='$cat_name', download_cat_description='$cat_description', download_cat_sorting='$cat_sorting', download_cat_cat_sorting='$cat_cat_sorting', download_cat_access='$cat_access', download_cat_image='$cat_image', download_parent='$cat_sub' ".($update_datestamp ? (", download_datestamp='".time()."'") : "")." WHERE download_cat_id='$cat_id'"); 
    9393        } else { 
    9494            $result = dbquery("INSERT INTO ".$db_prefix."download_cats (download_cat_name, download_cat_description, download_cat_sorting, download_cat_cat_sorting, download_cat_access, download_cat_image, download_parent, download_datestamp) VALUES('$cat_name', '$cat_description', '$cat_sorting', '$cat_cat_sorting', '$cat_access', '$cat_image', '$cat_sub', '".time()."')"); 
Note: See TracChangeset for help on using the changeset viewer.