Web UI for ARGUS server
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

61 lines
2.6 KiB

​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. <?php
  2. require_once('../ajax_asm.php');
  3. if( $CUser->Data['id'] > 1 ){
  4. $Data['success'] = false;
  5. $Data['msg']= 'Module Not Selected!';
  6. if( isset( $_POST['MID'] ) ){
  7. $MID = intval($_POST['MID']);
  8. if( $MID ){
  9. $Data['msg']='Module Does Not Exists!';
  10. $QS = "SELECT * FROM `server_modules` WHERE `id`={$MID}";
  11. $RR = $DATABASE->Query( $QS );
  12. if( count( $RR ) ){
  13. $CMD = $RR[0];
  14. $Data['success'] = true;
  15. $Data['msg']='';
  16. switch( $CMD['type'] ){
  17. case 9:{
  18. // EVE
  19. $SiW = array( 320, 640, 800, 1280, 1024, 1920 );
  20. $SiH = array( 240, 480, 600, 720, 768, 1080 );
  21. $SIZE = intval( $_POST['SIZE'] );
  22. $PORT = intval( $_POST['PORT'] );
  23. $COMP = intval( $_POST['COMPRESSION'] );
  24. $TS_X = intval( $_POST['TS_POSX'] );
  25. $TS_Y = intval( $_POST['TS_POSY'] );
  26. $TS_FF = intval( $_POST['TS_FONT'] );
  27. $TS_FS = intval( $_POST['TS_FONT_SCALE'] );
  28. $TS_FT = intval( $_POST['TS_FONT_THICK'] );
  29. $TS_LT = intval( $_POST['TS_LINE'] );
  30. $TS_TS = intval( $_POST['TS_TRANS'] );
  31. $LB_X = intval( $_POST['LBL_POSX'] );
  32. $LB_Y = intval( $_POST['LBL_POSY'] );
  33. $LB_FF = intval( $_POST['LBL_FONT'] );
  34. $LB_FS = intval( $_POST['LBL_FONT_SCALE'] );
  35. $LB_FT = intval( $_POST['LBL_FONT_THICK'] );
  36. $LB_LT = intval( $_POST['LBL_LINE'] );
  37. $LB_TS = intval( $_POST['LBL_TRANS'] );
  38. $LO_X = intval( $_POST['LOG_POSX'] );
  39. $LO_Y = intval( $_POST['LOG_POSY'] );
  40. $LO_W = intval( $_POST['LOG_W'] );
  41. $LO_H = intval( $_POST['LOG_H'] );
  42. if( $_POST['SHOW1'] ) $STS = 1; else $STS = 0;
  43. if( $_POST['SHOW2'] ) $SLB = 1; else $SLB = 0;
  44. if( $_POST['SHOW3'] ) $SLG = 0; else $SLG = 0;
  45. if( $_POST['TS_TRANS'] ) $TS_TS = 1; else $TS_TS = 0;
  46. if( $_POST['LBL_TRANS'] ) $LB_TS = 1; else $LB_TS = 0;
  47. $QS = "UPDATE `module_embed_video_settings` SET `web_port`={$PORT}, `width`={$SiW[$SIZE]}, `height`={$SiH[$SIZE]}, `compression_quality`={$COMP}, `show_ts`={$STS}, `show_label`={$SLB}, `show_logo`={$SLG}, `ts_x`={$TS_X}, `ts_y`={$TS_Y}, `ts_font_face`={$TS_FF}, `ts_font_thickness`={$TS_FT}, `ts_line_type`={$TS_LT}, `ts_transperant`={$TS_TS}, `label_x`={$LB_X}, `label_y`={$LB_Y}, `label_font_face`={$LB_FF}, `label_font_thickness`={$LB_FT}, `label_line_type`={$LB_LT}, `label_transperant`={$LB_TS}, `logo_x`={$LO_X}, `logo_y`={$LO_Y}, `logo_w`={$LO_W}, `logo_h`={$LO_H} WHERE `id`={$CMD['aux_id']}";
  48. $DATABASE->Query( $QS );
  49. break;
  50. };
  51. };
  52. };
  53. };
  54. };
  55. echo json_encode( $Data );
  56. exit();
  57. };
  58. header( 'location: /');
  59. ?>