<?php
/**
 * @copyright (c) Kufer Software GmbH, Loisachstrasse 4, D-84453 Mühldorf
 */

  session_start();
  
  define('ISKUFERTOOLS', true);
  

  if (!defined('BASEDIR')) {
    include_once '..' . DIRECTORY_SEPARATOR . 'classes' . DIRECTORY_SEPARATOR . 'constants.php';
  }



  
  $tool_id = PostOperations::getVarValue('tool');
  $sight_id = PostOperations::getVarValue('sightid');
  $user_id = SessionOperations::getUserID();
  $dbsight = new DBWorkSightsSettings();
  $writecolumns = new writeColumns();
  if ($user_id != -1) {
    switch (PostOperations::getVarValue('art')) {
      case 'TwitterAPI':


        $objsettings = ToolSettingsAPI::getToolSettings($tool_id);
        $widget = explode('&lt;script', PostOperations::getVarValue('widget'));
        $objsettings->widget = $widget[0];
        ToolSettingsAPI::setToolSettings($objsettings);
        echo $writecolumns->getLink($tool_id, $sight_id);
        break;

    }
  }