Subversion-Projekte lars-tiefland.content-management

Revision

Blame | Letzte Änderung | Log anzeigen | RSS feed

<?php

    //$Id: save_to_db.php 3361 2011-02-24 15:34:41Z tiefland $

    /**
     * @author Lars Tiefland <tiefland@weban.de>
     * @copyright 2009 Webagentur Niewerth
     * @package Content-management
     * @version $Rev: 3361 $
     * @license propietary
     * @filesource
     * 
     */

    /**
     * 
     * @author Lars Tiefland <tiefland@weban.de>
     * @copyright 2009 Webagentur Niewerth
     * @package Content-management
     */

    require_once  "load_from_db.php";

    if ( $_GET["val"] )
    {
        $val = $_GET["val"];
        $vals = explode( "=", $val );
        $view_data[$vals[0]] = ( bool )$vals[1];
        $val = serialize( $view_data );
        $sql = "UPDATE content_management.Access SET view_data='" . $val .
            "' WHERE user='" . $_SERVER["PHP_AUTH_USER"] . "'";
        $res = mysql_query( $sql, $localhost_dbh );
    }
    else
    {
        echo mysql_error();
    }
?>