connect_error) { die("Connection failed: " . $conn->connect_error); } $sql="select userid,active,siteurl,timeout,night,callbacktime,multiple,position,tip from widgets where widgetkey='$key'"; $result = $conn->query($sql) or die($conn->error); $row = $result->fetch_assoc(); $userid=$row['userid']; $active=$row['active']; $url=$row['siteurl']; $timeout=$row['timeout']; $night=$row['night']; $multiple=$row['multiple']; $callbacktime=$row['callbacktime']; $position=$row['position']; $tip=$row['tip']; if (!$userid) exit(); $float="true"; $data=array( "user_id"=>"$userid", "widget_key"=>"$key", "active"=>"$active", "country" => "de", // "lang" => "en-us", "lang" => "$tip", "position" => "$position", // "position" => "bottom:50px; right:50px;", "callback_time" => "$callbacktime", "float_button" => "$float", "night_mode" => "$night", "multiple_conversions" => "$multiple", // "tip" => "$tip", "timeout" => "$timeout"); $data=json_encode($data, JSON_PRETTY_PRINT); echo "jsonpCallback(".$data; ?> );