Embed Any Document - Version 2.3

Version Description

Download this release

Release Info

Developer awsmin
Plugin Icon Embed Any Document
Version 2.3
Comparing to
See all releases

Code changes from version 2.2.5 to 2.3

awsm-embed.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: Embed Any Document
4
  Plugin URI: http://awsm.in/embed-any-documents
5
  Description: Embed Any Document WordPress plugin lets you upload and embed your documents easily in your WordPress website without any additional browser plugins like Flash or Acrobat reader. The plugin lets you choose between Google Docs Viewer and Microsoft Office Online to display your documents.
6
- Version: 2.2.5
7
  Author: Awsm Innovations
8
  Author URI: http://awsm.in
9
  License: GPL V3
@@ -11,510 +11,578 @@
11
  Domain Path: /language
12
  */
13
 
14
- if( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
 
 
15
 
16
  class Awsm_embed {
17
- private static $instance = null;
18
- private $plugin_path;
19
- private $plugin_url;
20
- private $plugin_base;
21
- private $plugin_file;
22
- private $plugin_version;
23
- private $settings_slug;
24
- private $text_domain = 'embed-any-document';
25
- /**
26
- * Creates or returns an instance of this class.
27
- */
28
- public static function get_instance() {
29
- // If an instance hasn't been created and set to $instance create an instance and set it to $instance.
30
- if ( null == self::$instance ) {
31
- self::$instance = new self;
32
- }
33
- return self::$instance;
34
- }
35
-
36
- /**
37
- * Initializes the plugin by setting localization, hooks, filters, and administrative functions.
38
- */
39
- private function __construct() {
40
-
41
- $this->plugin_path = plugin_dir_path( __FILE__ );
42
- $this->plugin_url = plugin_dir_url( __FILE__ );
43
- $this->plugin_base = dirname( plugin_basename( __FILE__ ) );
44
- $this->plugin_file = __FILE__ ;
45
- $this->settings_slug = 'ead-settings';
46
- $this->plugin_version = '2.2.5';
47
-
48
- add_action( 'media_buttons', array( $this, 'embedbutton' ),1000);
49
-
50
- add_shortcode( 'embeddoc', array( $this, 'embed_shortcode' ));
51
-
52
- //Admin Settings menu
53
- add_action( 'admin_menu', array( $this, 'admin_menu' ));
54
- add_action( 'admin_init', array( $this, 'register_eadsettings' ));
55
- //Add easy settings link
56
- add_filter( 'plugin_action_links_' . plugin_basename( __FILE__ ),array( $this, 'settingslink' ));
57
- //ajax Contact Form
58
- add_action( 'wp_ajax_supportform',array( $this, 'supportform' ));
59
- //default options
60
- register_activation_hook($this->plugin_file, array( $this, 'defaults' ));
61
- //Load plugin textdomain.
62
- add_action( 'plugins_loaded',array( $this, 'load_textdomain' ) );
63
-
64
- $this->run_plugin();
65
- }
66
- /**
67
- * Register admin Settings style
68
- */
69
- function setting_styles(){
70
- wp_register_style( 'embed-settings', plugins_url( 'css/settings.css', $this->plugin_file ), false, $this->plugin_version, 'all' );
71
- wp_enqueue_style('embed-settings');
72
- }
73
- /**
74
- * Load plugin textdomain.
75
- *
76
- * @since 2.2.3
77
- */
78
- function load_textdomain() {
79
- load_plugin_textdomain( $this->text_domain, false, $this->plugin_base. '/language/' );
80
- }
81
- /**
82
- * Embed any Docs Button
83
- */
84
- public function embedbutton( $args = array() ) {
85
- // Check user previlage
86
- if ( !current_user_can( 'edit_posts' )) return;
87
- // Prepares button target
88
- $target = is_string( $args ) ? $args : 'content';
89
- // Prepare args
90
- $args = wp_parse_args( $args, array(
91
- 'target' => $target,
92
- 'text' => __( 'Add Document', $this->text_domain),
93
- 'class' => 'awsm-embed button',
94
- 'icon' => plugins_url( 'images/ead-small.png', __FILE__ ),
95
- 'echo' => true,
96
- 'shortcode' => false
97
- ) );
98
- // Prepare EAD icon
99
- if ( $args['icon'] ) $args['icon'] = '<img src="' . $args['icon'] . '" /> ';
100
- // Print button in media column
101
- $button = '<a href="javascript:void(0);" class="' . $args['class'] . '" title="' . $args['text'] . '" data-mfp-src="#embed-popup-wrap" data-target="' . $args['target'] . '" >' . $args['icon'] . $args['text'] . '</a>';
102
- // Show generator popup
103
- add_action( 'admin_footer', array($this, 'embedpopup' ) );
104
- // Request assets
105
- wp_enqueue_media();
106
- //Loads Support css and js
107
- $this->embed_helper();
108
- // Print/return result
109
- if ( $args['echo'] ) echo $button;
110
- return $button;
111
- }
112
- /**
113
- * Admin Easy access settings link
114
- */
115
- function settingslink( $links ) {
116
- $settings_link = '<a href="options-general.php?page='.$this->settings_slug.'">' . __('Settings', $this->text_domain) . '</a>';
117
- array_unshift( $links, $settings_link );
118
- return $links;
119
- }
120
- /**
121
- * Embed Form popup
122
- */
123
- function embedpopup(){
124
- add_thickbox();
125
- include( $this->plugin_path.'inc/popup.php' );
126
- }
127
- /**
 
 
 
 
 
 
 
 
 
 
 
 
 
128
  * Register admin scripts
129
  */
130
- function embed_helper(){
131
- wp_register_style( 'embed-css', plugins_url( 'css/embed.css', $this->plugin_file ), false, $this->plugin_version, 'all' );
132
- wp_register_script( 'embed', plugins_url( 'js/embed.js', $this->plugin_file ), array( 'jquery' ), $this->plugin_version, true );
133
- wp_localize_script('embed','emebeder', array(
134
- 'height' => get_option('ead_height', '100%'),
135
- 'width' => get_option('ead_width', '100%'),
136
- 'download' => get_option('ead_download', 'none'),
137
- 'text' => get_option('ead_text', __('Download',$this->text_domain)),
138
- 'provider' => get_option('ead_provider', 'google'),
139
- 'ajaxurl' => admin_url( 'admin-ajax.php' ),
140
- 'validtypes' => $this->validembedtypes(),
141
- 'msextension' => $this->validextensions('ms'),
142
- 'drextension' => $this->validextensions('all'),
143
- 'nocontent' => __('Nothing to insert', $this->text_domain),
144
- 'invalidurl' => __('Invalid URL', $this->text_domain),
145
- 'addurl' => __('Add URL', $this->text_domain),
146
- 'verify' => __('Verifying...', $this->text_domain),
147
- 'from_url' => __('From URL', $this->text_domain),
148
- 'select_button' => __('Select', $this->text_domain),
149
-
150
- ) );
151
- wp_enqueue_style('embed-css');
152
- wp_enqueue_script( 'embed' );
153
- }
154
- /**
155
  * Shortcode Functionality
156
  */
157
- function embed_shortcode($atts) {
158
- $embed = "";
159
- $durl = "";
160
- $default_width = $this->sanitize_dims(get_option('ead_width', '100%'));
161
- $default_height = $this->sanitize_dims(get_option('ead_height', '100%'));
162
- $default_provider = get_option('ead_provider', 'google');
163
- $default_download = get_option('ead_download', 'none');
164
- $default_text = get_option('ead_text', __('Download',$this->text_domain));
165
- $show = false;
166
- extract(shortcode_atts(array('url' => '',
167
- 'drive' => '',
168
- 'width' => $default_width,
169
- 'height' => $default_height,
170
- 'language' => 'en',
171
- 'text' => __($default_text,$this->text_domain),
172
- 'viewer' => $default_provider,
173
- 'download' => $default_download), $atts));
174
- if(isset($atts['provider']))
175
- $viewer = $atts['provider'];
176
- if(!isset($atts['provider']) AND !isset($atts['viewer']))
177
- $viewer = 'google';
178
- if ($url):
179
- $filedata = wp_remote_head($url);
180
- $durl = '';
 
 
 
 
 
 
 
181
  $privatefile = '';
182
- if ($this->allowdownload($viewer)) if ($download == 'alluser' or $download == 'all') {
183
- $show = true;
184
- } elseif ($download == 'logged' AND is_user_logged_in()) {
185
- $show = true;
 
 
186
  }
187
- if ($show) {
 
188
  $filesize = 0;
189
- $url = esc_url($url, array('http', 'https'));
190
- if (!is_wp_error($filedata) && isset($filedata['headers']['content-length'])) {
191
- $filesize = $this->human_filesize($filedata['headers']['content-length']);
192
- } else {
193
- $filesize = 0;
194
- }
195
  $fileHtml = '';
196
- if ($filesize) $fileHtml = ' [' . $filesize . ']';
197
- $durl = '<p class="embed_download"><a href="' . $url . '" download >' . __($text, $this->text_domain) . $fileHtml . ' </a></p>';
 
 
198
  }
199
 
200
- $url = esc_url($url, array('http', 'https'));
201
- $providerList = array('google', 'microsoft');
202
- if (!in_array($viewer, $providerList)) $viewer = 'google';
203
- switch ($viewer) {
 
204
  case 'google':
205
  $embedsrc = '//docs.google.com/viewer?url=%1$s&embedded=true&hl=%2$s';
206
- $iframe = sprintf($embedsrc, urlencode($url), esc_attr($language));
207
  break;
208
 
209
  case 'microsoft':
210
  $embedsrc = '//view.officeapps.live.com/op/embed.aspx?src=%1$s';
211
- $iframe = sprintf($embedsrc, urlencode($url));
212
  break;
213
  }
214
- $min_height = '';
215
- if($this->in_percentage($height)){
216
- $min_height = 'min-height:500px;';
217
  }
218
- if($this->check_responsive($height) AND $this->check_responsive($width)){
219
- $iframe_style = 'style="width:100%; height:100%; border: none; position: absolute;left:0;top:0;"';
220
- $doc_style = 'style="position:relative;padding-top:90%;"';
221
- }else{
222
- $iframe_style = sprintf('style="width:%s; height:%s; border: none;'.$min_height.'"',esc_html($width),esc_html($height));
223
- $doc_style = 'style="position:relative;"';
224
  }
225
-
226
- $iframe = '<iframe src="' . $iframe . '" ' . $iframe_style . '></iframe>';
227
- $show = false;
228
- $embed = '<div class="ead-preview"><div class="ead-document" '. $doc_style.'>' . $iframe . $privatefile . '</div>'.$durl.'</div>';
229
  else:
230
- $embed = __('No Url Found', $this->text_domain);
231
  endif;
 
232
  return $embed;
233
  }
234
-
235
- /**
236
  * Admin menu setup
237
  */
238
- public function admin_menu() {
239
- $eadsettings = add_options_page('Embed Any Document', 'Embed Any Document', 'manage_options',$this->settings_slug, array($this, 'settings_page'));
240
- add_action( 'admin_print_styles-' . $eadsettings, array( $this,'setting_styles'));
 
 
241
  }
 
242
  public function settings_page() {
243
- if (!current_user_can('manage_options')) {
244
- wp_die(__('You do not have sufficient permissions to access this page.'));
 
245
  }
246
- include($this->plugin_path.'inc/settings.php');
247
  }
 
248
  /**
249
  * Register Settings
250
  */
251
  function register_eadsettings() {
252
- register_setting( 'ead-settings-group', 'ead_width' ,array( $this, 'sanitize_dims' ));
253
- register_setting( 'ead-settings-group', 'ead_height',array( $this, 'sanitize_dims' ));
254
- register_setting( 'ead-settings-group', 'ead_provider' );
255
- register_setting( 'ead-settings-group', 'ead_download' );
256
- register_setting( 'ead-settings-group', 'ead_text' );
257
- register_setting( 'ead-settings-group', 'ead_mediainsert' );
258
- }
259
-
260
- /**
261
- * Plugin function
262
- */
263
- function run_plugin(){
264
- $this->adminfunctions();
265
  }
 
266
  /**
267
  * Admin Functions init
268
- */
269
- function adminfunctions(){
270
- if(is_admin()){
271
- add_filter('upload_mimes', array($this,'additional_mimes'));
272
- }
 
 
 
 
 
 
273
  }
274
- /**
 
275
  * Adds additional mimetype for meadi uploader
276
- */
277
- function additional_mimes($mimes){
278
- return array_merge($mimes,array (
279
- 'svg' => 'image/svg+xml',
280
- 'ai' => 'application/postscript',
281
- ));
282
- }
283
- /**
 
 
284
  * To get Overlay link
285
  */
286
- function providerlink( $provider) {
287
- $link = 'http://goo.gl/wJTQlc';
288
- $id = "";
289
- $configure = '<span class="overlay"><strong>' . __('Buy Pro Version', $this->text_domain) . '</strong><i></i></span>';
290
- $target = 'target="_blank"';
291
- echo '<a href="' . $link . '" id="' . $id . '" ' . $target . '><span><img src="' . $this->plugin_url . 'images/icon-' . strtolower($provider) . '.png" alt="'.sprintf( esc_html__( 'Add From %1$s', $this->text_domain ), $provider). '" />' . sprintf( esc_html__( 'Add From %1$s', $this->text_domain ), $provider) . $configure . '</span></a>';
 
292
  }
293
- /**
 
294
  * To initialize default options
295
- */
296
- function defaults()
297
- {
298
- $o = array(
299
- 'ead_width' => '100%',
300
- 'ead_height' => '100%',
301
- 'ead_download' => 'none',
302
- 'ead_provider' => 'google',
303
- 'ead_mediainsert' => '1',
304
- );
305
- foreach ( $o as $k => $v )
306
- {
307
- if(!get_option($k)) update_option($k, $v);
308
- }
309
- return;
310
- }
311
- //Functions
312
-
313
- /**
314
- * Dropdown Builder
315
- *
316
- * @since 1.0
317
- * @return String select html
318
- */
319
- function selectbuilder($name, $options, $selected = "", $class = "") {
320
- if (is_array($options)):
321
- echo "<select name=\"$name\" id=\"$name\" class=\"$class\">";
322
- foreach ($options as $key => $option) {
323
- echo "<option value=\"$key\"";
324
- if (!empty($helptext)) {
325
- echo " title=\"$helptext\"";
326
- }
327
- if ($key == $selected) {
328
- echo ' selected="selected"';
329
- }
330
- echo ">$option</option>\n";
331
- }
332
- echo '</select>';
333
- else:
334
- endif;
335
- }
336
-
337
- /**
338
- * Human Readable filesize
339
- *
340
- * @since 1.0
341
- * @return Human readable file size
342
- * @note Replaces old gde_sanitizeOpts function
343
- */
344
- function human_filesize($bytes, $decimals = 2) {
345
- $size = array('B', 'KB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB');
346
- $factor = floor((strlen($bytes) - 1) / 3);
347
- return sprintf("%.{$decimals}f ", $bytes / pow(1024, $factor)) . @$size[$factor];
348
- }
349
-
350
- /**
351
- * Sanitize dimensions (width, height)
352
- *
353
- * @since 1.0
354
- * @return string Sanitized dimensions, or false if value is invalid
355
- * @note Replaces old gde_sanitizeOpts function
356
- */
357
- function sanitize_dims($dim) {
358
-
359
- // remove any spacing junk
360
- $dim = trim(str_replace(" ", "", $dim));
361
- if(!$dim) $dim = '100%';
362
- if (!strstr($dim, '%')) {
363
- $type = "px";
364
- $dim = preg_replace("/[^0-9]*/", '', $dim);
365
- } else {
366
- $type = "%";
367
- $dim = preg_replace("/[^0-9]*/", '', $dim);
368
- if ((int)$dim > 100) {
369
- $dim = "100";
370
- }
371
- }
372
-
373
- if ($dim) {
374
- return $dim . $type;
375
- } else {
376
- return false;
377
- }
378
- }
379
- /**
380
- * Check value in percentage
381
- *
382
- * @since 2.2.3
383
- * @return Int Dimenesion
384
- */
385
- function in_percentage($dim){
386
- if (strstr($dim, '%')) {
387
- return true;
388
- }
389
- return false;
390
- }
391
- /**
392
- * Enable Resposive
393
- *
394
- * @since 2.2.3
395
- * @return Boolean
396
- */
397
- function check_responsive($dim){
398
- if (strstr($dim, '%')) {
399
- $dim = preg_replace("/[^0-9]*/", '', $dim);
400
- if ((int)$dim == 100) {
401
- return true;
402
- }
403
- }
404
- return false;
405
- }
406
-
407
- /**
408
- * Validate Source mime type
409
- *
410
- * @since 1.0
411
- * @return boolean
412
- */
413
- function validmime_types() {
414
- include ('inc/mime_types.php');
415
- return $mimetypes;
416
- }
417
-
418
- /**
419
- * Checks Url Validity
420
- *
421
- * @since 1.0
422
- * @return boolean
423
- */
424
- function valid_type($url) {
425
- $doctypes = $this->validmime_types();
426
- if (is_array($doctypes)) {
427
- $allowed_ext = implode("|", array_keys($doctypes));
428
- if (preg_match("/\.($allowed_ext)$/i", $url)) {
429
- return true;
430
- }
431
- } else {
432
- return false;
433
- }
434
- }
435
-
436
- /**
437
- * Get allowed Mime Types
438
- *
439
- * @since 1.0
440
- * @return string Mimetypes
441
- */
442
- function validembedtypes() {
443
- $doctypes = $this->validmime_types();
444
- return $allowedtype = implode(',', $doctypes);
445
- }
446
-
447
- /**
448
- * Get allowed Extensions
449
- *
450
- * @since 1.0
451
- * @return string Extenstion
452
- */
453
- function validextensions($list = 'all') {
454
- include ('inc/mime_types.php');
455
- return $allowedtype = implode(',', $extensions[$list]);
456
- }
457
-
458
- /**
459
- * Get allowed Mime Types for microsoft
460
- *
461
- * @since 1.0
462
- * @return array Mimetypes
463
- */
464
- function microsoft_mimes() {
465
- $micro_mime = array(
466
- 'doc' => 'application/msword',
467
- 'pot|pps|ppt' => 'application/vnd.ms-powerpoint',
468
- 'xla|xls|xlt|xlw' => 'application/vnd.ms-excel',
469
- 'docx' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',
470
- 'dotx' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.template',
471
- 'dotm' => 'application/vnd.ms-word.template.macroEnabled.12',
472
- 'xlsx' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet',
473
- 'xlsm' => 'application/vnd.ms-excel.sheet.macroEnabled.12',
474
- 'pptx' => 'application/vnd.openxmlformats-officedocument.presentationml.presentation',
475
- 'ppsx' => 'application/vnd.openxmlformats-officedocument.presentationml.slideshow',
476
- );
477
- return $micro_mime;
478
- }
479
-
480
- /**
481
- * Check Allow Download
482
- *
483
- * @since 1.0
484
- * @return Boolean
485
- */
486
- function allowdownload($provider) {
487
- $blacklist = array('drive', 'box');
488
- if (in_array($provider, $blacklist)) {
489
- return false;
490
- } else {
491
- return true;
492
- }
493
- }
494
-
495
- /**
496
- * Get Active Menu Class
497
- *
498
- * @since 1.0
499
- * @return string Class name
500
- */
501
- function getactive_menu($tab, $needle) {
502
- if ($tab == $needle) {
503
- echo 'nav-tab-active';
504
- }
505
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
506
  }
507
 
508
- function embed_doc_activation(){
509
- if ( !defined( 'EAD_PLUS' ) ) {
510
- Awsm_embed::get_instance();
511
- }
 
512
  }
513
- function embed_doc_disable_self(){
514
- if ( defined( 'EAD_PLUS' ) ) {
515
- deactivate_plugins( plugin_basename( __FILE__ ) );
516
- }
 
 
517
  }
518
- // plugin activation hook
 
519
  add_action( 'plugins_loaded', 'embed_doc_activation' );
520
- add_action( 'admin_init', 'embed_doc_disable_self' );
3
  Plugin Name: Embed Any Document
4
  Plugin URI: http://awsm.in/embed-any-documents
5
  Description: Embed Any Document WordPress plugin lets you upload and embed your documents easily in your WordPress website without any additional browser plugins like Flash or Acrobat reader. The plugin lets you choose between Google Docs Viewer and Microsoft Office Online to display your documents.
6
+ Version: 2.3
7
  Author: Awsm Innovations
8
  Author URI: http://awsm.in
9
  License: GPL V3
11
  Domain Path: /language
12
  */
13
 
14
+ if ( ! defined( 'ABSPATH' ) ) {
15
+ exit;
16
+ } // Exit if accessed directly
17
 
18
  class Awsm_embed {
19
+
20
+ private static $instance = null;
21
+ private $plugin_path;
22
+ private $plugin_url;
23
+ private $plugin_base;
24
+ private $plugin_file;
25
+ private $plugin_version;
26
+ private $settings_slug;
27
+
28
+ /**
29
+ * Creates or returns an instance of this class.
30
+ */
31
+ public static function get_instance() {
32
+
33
+ // If an instance hasn't been created and set to $instance create an instance and set it to $instance.
34
+ if ( null == self::$instance ) {
35
+ self::$instance = new self;
36
+ }
37
+
38
+ return self::$instance;
39
+ }
40
+
41
+ /**
42
+ * Initializes the plugin by setting localization, hooks, filters, and administrative functions.
43
+ */
44
+ private function __construct() {
45
+
46
+ $this->plugin_path = plugin_dir_path( __FILE__ );
47
+ $this->plugin_url = plugin_dir_url( __FILE__ );
48
+ $this->plugin_base = dirname( plugin_basename( __FILE__ ) );
49
+ $this->plugin_file = __FILE__;
50
+ $this->settings_slug = 'ead-settings';
51
+ $this->plugin_version = '2.3';
52
+
53
+ add_action( 'media_buttons', array( $this, 'embedbutton' ), 1000 );
54
+
55
+ add_shortcode( 'embeddoc', array( $this, 'embed_shortcode' ) );
56
+
57
+ //default options
58
+ register_activation_hook( $this->plugin_file, array( $this, 'defaults' ) );
59
+ //Load plugin textdomain.
60
+ add_action( 'plugins_loaded', array( $this, 'load_textdomain' ) );
61
+
62
+ $this->adminfunctions();
63
+ }
64
+
65
+ /**
66
+ * Register admin Settings style
67
+ */
68
+ function setting_styles() {
69
+
70
+ wp_register_style( 'embed-settings', plugins_url( 'css/settings.css', $this->plugin_file ), false, $this->plugin_version, 'all' );
71
+ wp_enqueue_style( 'embed-settings' );
72
+ }
73
+
74
+ /**
75
+ * Load plugin textdomain.
76
+ *
77
+ * @since 2.2.3
78
+ */
79
+ function load_textdomain() {
80
+
81
+ load_plugin_textdomain( 'embed-any-document', false, $this->plugin_base . '/language/' );
82
+ }
83
+
84
+ /**
85
+ * Embed any Docs Button
86
+ */
87
+ public function embedbutton( $args = array() ) {
88
+
89
+ // Check user previlage
90
+ if ( ! current_user_can( 'edit_posts' ) ) {
91
+ return;
92
+ }
93
+ // Prepares button target
94
+ $target = is_string( $args ) ? $args : 'content';
95
+ // Prepare args
96
+ $args = wp_parse_args( $args, array(
97
+ 'target' => $target,
98
+ 'text' => __( 'Add Document', 'embed-any-document' ),
99
+ 'class' => 'awsm-embed button',
100
+ 'icon' => plugins_url( 'images/ead-small.png', __FILE__ ),
101
+ 'echo' => true,
102
+ 'shortcode' => false,
103
+ ) );
104
+ // Prepare EAD icon
105
+ if ( $args['icon'] ) {
106
+ $args['icon'] = '<img src="' . esc_url( $args['icon'] ) . '" /> ';
107
+ }
108
+ // Print button in media column
109
+ $button = '<a href="javascript:void(0);" class="' . esc_attr( $args['class'] ) . '" title="' . esc_attr( $args['text'] ) . '" data-mfp-src="#embed-popup-wrap" data-target="' . esc_attr( $args['target'] ) . '" >' . $args['icon'] . esc_html( $args['text'] ) . '</a>';
110
+
111
+ wp_enqueue_media();
112
+
113
+ if ( $args['echo'] ) {
114
+ echo $button;
115
+ }
116
+
117
+ return $button;
118
+ }
119
+
120
+ /**
121
+ * Admin Easy access settings link
122
+ */
123
+ function settingslink( $links ) {
124
+
125
+ $settings_link = '<a href="options-general.php?page=' . esc_attr( $this->settings_slug ) . '">' . esc_html__( 'Settings', 'embed-any-document' ) . '</a>';
126
+ array_unshift( $links, $settings_link );
127
+
128
+ return $links;
129
+ }
130
+
131
+ /**
132
+ * Embed Form popup
133
+ */
134
+ function embedpopup() {
135
+
136
+ if (wp_script_is('ead_media_button')) {
137
+ add_thickbox();
138
+ include( $this->plugin_path . 'inc/popup.php' );
139
+ }
140
+ }
141
+
142
+ /**
143
  * Register admin scripts
144
  */
145
+ function embed_helper() {
146
+
147
+ wp_enqueue_script( 'ead_media_button', plugins_url( 'js/embed.js', $this->plugin_file), array('jquery'), $this->plugin_version, true );
148
+ wp_enqueue_style( 'ead_media_button', plugins_url( 'css/embed.css', $this->plugin_file), false, $this->plugin_version, 'all' );
149
+ wp_localize_script( 'ead_media_button', 'emebeder', array(
150
+ 'height' => get_option( 'ead_height', '100%' ),
151
+ 'width' => get_option( 'ead_width', '100%' ),
152
+ 'download' => get_option( 'ead_download', 'none' ),
153
+ 'text' => get_option( 'ead_text', __( 'Download', 'embed-any-document' ) ),
154
+ 'provider' => get_option( 'ead_provider', 'google' ),
155
+ 'ajaxurl' => admin_url( 'admin-ajax.php' ),
156
+ 'validtypes' => $this->validembedtypes(),
157
+ 'msextension' => $this->validextensions( 'ms' ),
158
+ 'drextension' => $this->validextensions( 'all' ),
159
+ 'nocontent' => __( 'Nothing to insert', 'embed-any-document' ),
160
+ 'invalidurl' => __( 'Invalid URL', 'embed-any-document' ),
161
+ 'addurl' => __( 'Add URL', 'embed-any-document' ),
162
+ 'verify' => __( 'Verifying...', 'embed-any-document' ),
163
+ 'from_url' => __( 'From URL', 'embed-any-document' ),
164
+ 'select_button' => __( 'Select', 'embed-any-document' ),
165
+
166
+ ) );
167
+ }
168
+
169
+ /**
170
  * Shortcode Functionality
171
  */
172
+ function embed_shortcode( $atts ) {
173
+
174
+ $embed = "";
175
+ $durl = "";
176
+ $default_width = $this->sanitize_dims( get_option( 'ead_width', '100%' ) );
177
+ $default_height = $this->sanitize_dims( get_option( 'ead_height', '100%' ) );
178
+ $default_provider = get_option( 'ead_provider', 'google' );
179
+ $default_download = get_option( 'ead_download', 'none' );
180
+ $default_text = get_option( 'ead_text', __( 'Download', 'embed-any-document' ) );
181
+ $show = false;
182
+ $shortcode_atts = shortcode_atts( array(
183
+ 'url' => '',
184
+ 'drive' => '',
185
+ 'width' => $default_width,
186
+ 'height' => $default_height,
187
+ 'language' => 'en',
188
+ 'text' => __( $default_text, 'embed-any-document' ),
189
+ 'viewer' => $default_provider,
190
+ 'download' => $default_download,
191
+ ), $atts );
192
+
193
+ if ( isset( $atts['provider'] ) ) {
194
+ $shortcode_atts['viewer'] = $atts['provider'];
195
+ }
196
+ if ( ! isset( $atts['provider'] ) AND ! isset( $atts['viewer'] ) ) {
197
+ $shortcode_atts['viewer'] = 'google';
198
+ }
199
+
200
+ if ( $shortcode_atts['url'] ):
201
+ $filedata = wp_remote_head( $shortcode_atts['url'] );
202
+ $durl = '';
203
  $privatefile = '';
204
+ if ( $this->allowdownload( $shortcode_atts['viewer'] ) ) {
205
+ if ( $shortcode_atts['download'] === 'alluser' or $shortcode_atts['download'] === 'all' ) {
206
+ $show = true;
207
+ } elseif ( $shortcode_atts['download'] === 'logged' AND is_user_logged_in() ) {
208
+ $show = true;
209
+ }
210
  }
211
+ $url = esc_url( $shortcode_atts['url'], array( 'http', 'https' ) );
212
+ if ( $show ) {
213
  $filesize = 0;
214
+
215
+ if ( ! is_wp_error( $filedata ) && isset( $filedata['headers']['content-length'] ) ) {
216
+ $filesize = $this->human_filesize( $filedata['headers']['content-length'] );
217
+ } else {
218
+ $filesize = 0;
219
+ }
220
  $fileHtml = '';
221
+ if ( $filesize ) {
222
+ $fileHtml = ' [' . $filesize . ']';
223
+ }
224
+ $durl = '<p class="embed_download"><a href="' . esc_url( $url ) . '" download >' . __( $shortcode_atts['text'], 'embed-any-document' ) . $fileHtml . ' </a></p>';
225
  }
226
 
227
+ $provider_list = array( 'google', 'microsoft' );
228
+ if ( ! in_array( $shortcode_atts['viewer'] , $provider_list ) ) {
229
+ $shortcode_atts['viewer'] = 'google';
230
+ }
231
+ switch ( $shortcode_atts['viewer'] ) {
232
  case 'google':
233
  $embedsrc = '//docs.google.com/viewer?url=%1$s&embedded=true&hl=%2$s';
234
+ $iframe = sprintf( $embedsrc, urlencode( $url ), esc_attr( $shortcode_atts['language'] ) );
235
  break;
236
 
237
  case 'microsoft':
238
  $embedsrc = '//view.officeapps.live.com/op/embed.aspx?src=%1$s';
239
+ $iframe = sprintf( $embedsrc, urlencode( $url ) );
240
  break;
241
  }
242
+ $min_height = '';
243
+ if ( $this->in_percentage( $shortcode_atts['height'] ) ) {
244
+ $min_height = 'min-height:500px;';
245
  }
246
+ if ( $this->check_responsive( $shortcode_atts['height'] ) AND $this->check_responsive( $shortcode_atts['width'] ) ) {
247
+ $iframe_style = 'style="width:100%; height:100%; border: none; position: absolute;left:0;top:0;"';
248
+ $doc_style = 'style="position:relative;padding-top:90%;"';
249
+ } else {
250
+ $iframe_style = sprintf( 'style="width:%s; height:%s; border: none;' . $min_height . '"', esc_html( $shortcode_atts['width'] ), esc_html( $shortcode_atts['height'] ) );
251
+ $doc_style = 'style="position:relative;"';
252
  }
253
+
254
+ $iframe = sprintf('<iframe src="%s" title="%s" %s></iframe>', esc_attr( $iframe ), esc_html__( 'Embedded Document', 'embed-any-document-plus'), $iframe_style );
255
+
256
+ $embed = '<div class="ead-preview"><div class="ead-document" ' . $doc_style . '>' . $iframe . $privatefile . '</div>' . $durl . '</div>';
257
  else:
258
+ $embed = esc_html__( 'No Url Found', 'embed-any-document' );
259
  endif;
260
+
261
  return $embed;
262
  }
263
+
264
+ /**
265
  * Admin menu setup
266
  */
267
+ public function admin_menu() {
268
+
269
+ $title = __('Embed Any Document','embed-any-document');
270
+ $eadsettings = add_options_page( $title, $title, 'manage_options', $this->settings_slug, array( $this, 'settings_page' ) );
271
+ add_action( 'admin_print_styles-' . $eadsettings, array( $this, 'setting_styles' ) );
272
  }
273
+
274
  public function settings_page() {
275
+
276
+ if ( ! current_user_can( 'manage_options' ) ) {
277
+ wp_die( __( 'You do not have sufficient permissions to access this page.' ) );
278
  }
279
+ include( $this->plugin_path . 'inc/settings.php' );
280
  }
281
+
282
  /**
283
  * Register Settings
284
  */
285
  function register_eadsettings() {
286
+
287
+ register_setting( 'ead-settings-group', 'ead_width', array( $this, 'sanitize_dims' ) );
288
+ register_setting( 'ead-settings-group', 'ead_height', array( $this, 'sanitize_dims' ) );
289
+ register_setting( 'ead-settings-group', 'ead_provider' );
290
+ register_setting( 'ead-settings-group', 'ead_download' );
291
+ register_setting( 'ead-settings-group', 'ead_text' );
292
+ register_setting( 'ead-settings-group', 'ead_mediainsert' );
 
 
 
 
 
 
293
  }
294
+
295
  /**
296
  * Admin Functions init
297
+ */
298
+ function adminfunctions() {
299
+
300
+ if ( is_admin() ) {
301
+ add_action( 'wp_enqueue_media', array($this, 'embed_helper') );
302
+ add_action( 'admin_menu', array( $this, 'admin_menu' ) );
303
+ add_action( 'admin_init', array( $this, 'register_eadsettings' ) );
304
+ add_action( 'admin_footer', array( $this, 'embedpopup' ) );
305
+ add_filter( 'plugin_action_links_' . plugin_basename( __FILE__ ), array( $this, 'settingslink' ) );
306
+ add_filter( 'upload_mimes', array( $this, 'additional_mimes' ) );
307
+ }
308
  }
309
+
310
+ /**
311
  * Adds additional mimetype for meadi uploader
312
+ */
313
+ function additional_mimes( $mimes ) {
314
+
315
+ return array_merge( $mimes, array(
316
+ 'svg' => 'image/svg+xml',
317
+ 'ai' => 'application/postscript',
318
+ ) );
319
+ }
320
+
321
+ /**
322
  * To get Overlay link
323
  */
324
+ function providerlink( $provider ) {
325
+
326
+ $link = 'http://goo.gl/wJTQlc';
327
+ $id = "";
328
+ $configure = '<span class="overlay"><strong>' . esc_html__( 'Buy Pro Version', 'embed-any-document' ) . '</strong><i></i></span>';
329
+ $target = 'target="_blank"';
330
+ echo '<a href="' . $link . '" id="' . $id . '" ' . $target . '><span><img src="' . esc_url( $this->plugin_url ) . 'images/icon-' . strtolower( $provider ) . '.png" alt="' . sprintf( esc_html__( 'Add From %1$s', 'embed-any-document' ), $provider ) . '" />' . sprintf( esc_html__( 'Add From %1$s', 'embed-any-document' ), $provider ) . $configure . '</span></a>';
331
  }
332
+
333
+ /**
334
  * To initialize default options
335
+ */
336
+ function defaults() {
337
+
338
+ $o = array(
339
+ 'ead_width' => '100%',
340
+ 'ead_height' => '100%',
341
+ 'ead_download' => 'none',
342
+ 'ead_provider' => 'google',
343
+ 'ead_media:t' => '1',
344
+ );
345
+ foreach ( $o as $k => $v ) {
346
+ if ( ! get_option( $k ) ) {
347
+ update_option( $k, $v );
348
+ }
349
+ }
350
+
351
+ return;
352
+ }
353
+ //Functions
354
+
355
+ /**
356
+ * Dropdown Builder
357
+ *
358
+ * @since 1.0
359
+ * @return String select html
360
+ */
361
+ function selectbuilder( $name, $options, $selected = "", $class = "" ) {
362
+
363
+ if ( is_array( $options ) ):
364
+ echo "<select name=\"" . esc_attr( $name ) . "\" id=\"" . esc_attr( $name ) . "\" class=\"" . esc_attr( $class ) . "\">";
365
+ foreach ( $options as $key => $option ) {
366
+ echo "<option value=\"" . esc_attr( $key ) . "\"";
367
+ if ( ! empty( $helptext ) ) {
368
+ echo " title=\"" . esc_attr( $helptext ) . "\"";
369
+ }
370
+ if ( $key == $selected ) {
371
+ echo ' selected="selected"';
372
+ }
373
+ echo ">" . esc_html( $option ) . "</option>\n";
374
+ }
375
+ echo '</select>';
376
+ else:
377
+ endif;
378
+ }
379
+
380
+ /**
381
+ * Human Readable filesize
382
+ *
383
+ * @since 1.0
384
+ * @return Human readable file size
385
+ * @note Replaces old gde_sanitizeOpts function
386
+ */
387
+ function human_filesize( $bytes, $decimals = 2 ) {
388
+
389
+ $size = array( 'B', 'KB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB' );
390
+ $factor = floor( ( strlen( $bytes ) - 1 ) / 3 );
391
+
392
+ return sprintf( "%.{$decimals}f ", $bytes / pow( 1024, $factor ) ) . @$size[ $factor ];
393
+ }
394
+
395
+ /**
396
+ * Sanitize dimensions (width, height)
397
+ *
398
+ * @since 1.0
399
+ * @return string Sanitized dimensions, or false if value is invalid
400
+ * @note Replaces old gde_sanitizeOpts function
401
+ */
402
+ function sanitize_dims( $dim ) {
403
+
404
+ // remove any spacing junk
405
+ $dim = trim( str_replace( " ", "", $dim ) );
406
+ if ( ! $dim ) {
407
+ $dim = '100%';
408
+ }
409
+ if ( ! strstr( $dim, '%' ) ) {
410
+ $type = "px";
411
+ $dim = preg_replace( "/[^0-9]*/", '', $dim );
412
+ } else {
413
+ $type = "%";
414
+ $dim = preg_replace( "/[^0-9]*/", '', $dim );
415
+ if ( (int) $dim > 100 ) {
416
+ $dim = "100";
417
+ }
418
+ }
419
+
420
+ if ( $dim ) {
421
+ return $dim . $type;
422
+ } else {
423
+ return false;
424
+ }
425
+ }
426
+
427
+ /**
428
+ * Check value in percentage
429
+ *
430
+ * @since 2.2.3
431
+ * @return Int Dimenesion
432
+ */
433
+ function in_percentage( $dim ) {
434
+
435
+ if ( strstr( $dim, '%' ) ) {
436
+ return true;
437
+ }
438
+
439
+ return false;
440
+ }
441
+
442
+ /**
443
+ * Enable Resposive
444
+ *
445
+ * @since 2.2.3
446
+ * @return Boolean
447
+ */
448
+ function check_responsive( $dim ) {
449
+
450
+ if ( strstr( $dim, '%' ) ) {
451
+ $dim = preg_replace( "/[^0-9]*/", '', $dim );
452
+ if ( (int) $dim == 100 ) {
453
+ return true;
454
+ }
455
+ }
456
+
457
+ return false;
458
+ }
459
+
460
+ /**
461
+ * Validate Source mime type
462
+ *
463
+ * @since 1.0
464
+ * @return boolean
465
+ */
466
+ function validmime_types() {
467
+
468
+ include( 'inc/mime_types.php' );
469
+
470
+ return $mimetypes;
471
+ }
472
+
473
+ /**
474
+ * Checks Url Validity
475
+ *
476
+ * @since 1.0
477
+ * @return boolean
478
+ */
479
+ function valid_type( $url ) {
480
+
481
+ $doctypes = $this->validmime_types();
482
+ if ( is_array( $doctypes ) ) {
483
+ $allowed_ext = implode( "|", array_keys( $doctypes ) );
484
+ if ( preg_match( "/\.($allowed_ext)$/i", $url ) ) {
485
+ return true;
486
+ }
487
+ } else {
488
+ return false;
489
+ }
490
+ }
491
+
492
+ /**
493
+ * Get allowed Mime Types
494
+ *
495
+ * @since 1.0
496
+ * @return string Mimetypes
497
+ */
498
+ function validembedtypes() {
499
+
500
+ $doctypes = $this->validmime_types();
501
+
502
+ return $allowedtype = implode( ',', $doctypes );
503
+ }
504
+
505
+ /**
506
+ * Get allowed Extensions
507
+ *
508
+ * @since 1.0
509
+ * @return string Extenstion
510
+ */
511
+ function validextensions( $list = 'all' ) {
512
+
513
+ include( 'inc/mime_types.php' );
514
+
515
+ return $allowedtype = implode( ',', $extensions[ $list ] );
516
+ }
517
+
518
+ /**
519
+ * Get allowed Mime Types for microsoft
520
+ *
521
+ * @since 1.0
522
+ * @return array Mimetypes
523
+ */
524
+ function microsoft_mimes() {
525
+
526
+ $micro_mime = array(
527
+ 'doc' => 'application/msword',
528
+ 'pot|pps|ppt' => 'application/vnd.ms-powerpoint',
529
+ 'xla|xls|xlt|xlw' => 'application/vnd.ms-excel',
530
+ 'docx' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',
531
+ 'dotx' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.template',
532
+ 'dotm' => 'application/vnd.ms-word.template.macroEnabled.12',
533
+ 'xlsx' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet',
534
+ 'xlsm' => 'application/vnd.ms-excel.sheet.macroEnabled.12',
535
+ 'pptx' => 'application/vnd.openxmlformats-officedocument.presentationml.presentation',
536
+ 'ppsx' => 'application/vnd.openxmlformats-officedocument.presentationml.slideshow',
537
+ );
538
+
539
+ return $micro_mime;
540
+ }
541
+
542
+ /**
543
+ * Check Allow Download
544
+ *
545
+ * @since 1.0
546
+ * @return Boolean
547
+ */
548
+ function allowdownload( $provider ) {
549
+
550
+ $blacklist = array( 'drive', 'box' );
551
+ if ( in_array( $provider, $blacklist ) ) {
552
+ return false;
553
+ } else {
554
+ return true;
555
+ }
556
+ }
557
+
558
+ /**
559
+ * Get Active Menu Class
560
+ *
561
+ * @since 1.0
562
+ * @return string Class name
563
+ */
564
+ function getactive_menu( $tab, $needle ) {
565
+
566
+ if ( $tab == $needle ) {
567
+ echo 'nav-tab-active';
568
+ }
569
+ }
570
  }
571
 
572
+ function embed_doc_activation() {
573
+
574
+ if ( ! defined( 'EAD_PLUS' ) ) {
575
+ Awsm_embed::get_instance();
576
+ }
577
  }
578
+
579
+ function embed_doc_disable_self() {
580
+
581
+ if ( defined( 'EAD_PLUS' ) ) {
582
+ deactivate_plugins( plugin_basename( __FILE__ ) );
583
+ }
584
  }
585
+
586
+ // Main WPtouch Pro activation hook
587
  add_action( 'plugins_loaded', 'embed_doc_activation' );
588
+ add_action( 'admin_init', 'embed_doc_disable_self' );
css/embed.css CHANGED
@@ -3,58 +3,76 @@
3
  width: 85%;
4
  margin: 0 auto;
5
  }
6
- .ead-popup-on #TB_window{
 
 
 
 
 
7
  background: none;
8
  box-shadow: none;
9
  -webkit-box-shadow: none;
 
10
  }
11
- .ead-popup-on #TB_ajaxContent{
 
 
 
 
 
12
  text-align: center;
13
  }
14
- .ead-popup-on #TB_ajaxContent:after{
 
15
  content: "";
16
  display: inline-block;
17
  width: 1px;
18
  height: 100%;
19
  vertical-align: middle;
20
  }
 
21
  #embed-popup {
22
  position: relative;
23
  width: 99%;
24
- max-width: 1000px;
25
  background: #fff;
26
  -moz-box-sizing: border-box;
27
  -webkit-box-sizing: border-box;
28
  box-sizing: border-box;
29
  display: inline-block;
30
  vertical-align: middle;
31
- -webkit-box-shadow: 0 2px 25px #000;
32
- -moz-box-shadow: 0 2px 25px #000;
33
- box-shadow: 0 2px 25px #000;
34
  text-align: left;
35
-
36
  }
37
- .ead-popup-header{
 
38
  padding: 20px 30px;
39
  }
40
- .ead-popup-header h1{
 
41
  margin: 0;
42
  line-height: 1.3;
43
  }
 
44
  .ead-section {
45
  padding: 0 30px;
46
  border-top: 1px solid #ebebeb;
47
  }
48
- .ead-action-panel{
49
- padding: 20px 30px;
 
50
  background: #f5f5f5;
51
  border-top: 1px solid #ebebeb;
52
  }
 
53
  ul.ead-options {
54
  padding: 30px 0;
55
  overflow: hidden;
56
  margin: 0px;
57
  }
 
58
  .ead-options li {
59
  float: left;
60
  width: 20%;
@@ -63,24 +81,40 @@ ul.ead-options {
63
  -webkit-box-sizing: border-box;
64
  box-sizing: border-box;
65
  }
 
66
  .ead-options li a {
67
  display: block;
68
  text-decoration: none;
69
  color: rgb(33, 33, 33);
70
  }
 
71
  .ead-options li span {
72
- border: 2px dotted #ccc;
73
  -webkit-border-radius: 4px;
74
  border-radius: 4px;
75
  display: block;
76
- padding: 30px 10px 20px;
77
  text-align: center;
78
  position: relative;
 
 
 
 
 
79
  }
 
 
 
 
 
 
 
80
  .ead-options li img {
81
  display: block;
82
  margin: 0 auto 10px;
 
83
  }
 
84
  .ead-options li span span.overlay {
85
  border: none;
86
  -webkit-border-radius: 0;
@@ -93,6 +127,7 @@ ul.ead-options {
93
  top: 0;
94
  background: rgba(255, 255, 255, 0.7);
95
  }
 
96
  .ead-options .overlay strong {
97
  display: inline-block;
98
  max-width: 97%;
@@ -104,23 +139,28 @@ ul.ead-options {
104
  -o-transition: all 0.3s ease;
105
  transition: all 0.3s ease;
106
  }
 
107
  .ead-options li span:hover {
108
  box-shadow: 1px 1px 3px rgba(0, 0, 0, 0.1);
109
  -webkit-box-shadow: 1px 1px 3px rgba(0, 0, 0, 0.1);
110
  }
 
111
  .ead-options li:hover .overlay strong {
112
  opacity: 1;
113
  }
 
114
  .ead-options .overlay i {
115
  display: inline-block;
116
  height: 100%;
117
  width: 1px;
118
  vertical-align: middle;
119
  }
 
120
  .upload-success {
121
  min-height: 70px;
122
  overflow: hidden;
123
  }
 
124
  .upload-success .inner {
125
  padding: 30px 10px;
126
  -moz-box-sizing: border-box;
@@ -129,24 +169,30 @@ ul.ead-options {
129
  float: left;
130
  width: 20%;
131
  }
 
132
  .box {
133
  display: none;
134
- border: 2px dotted #ccc;
135
- -webkit-border-radius: 4px;
136
- border-radius: 4px;
137
  padding: 20px;
138
  margin: 30px 0;
139
  }
 
 
 
 
 
 
140
  a.go-back {
141
  display: inline-block;
142
  margin-top: 20px;
143
  text-decoration: none;
144
  }
 
145
  .box label {
146
  display: block;
147
  font-size: 12px;
148
  margin-bottom: 5px;
149
  }
 
150
  .uploaded-doccument {
151
  padding: 75px 0 5px;
152
  color: #454545;
@@ -154,21 +200,27 @@ a.go-back {
154
  word-wrap: break-word;
155
  text-align: center;
156
  }
 
157
  .uploaded-doccument.ead-link {
158
  background: url(../images/icon-link.png) no-repeat center 5px / 36px 49px;
159
  }
 
160
  .uploaded-doccument.ead-upload {
161
  background: url(../images/icon-upload.png) no-repeat center 5px / 54px 49px;
162
  }
 
163
  .uploaded-doccument.ead-dropbox {
164
  background: url(../images/icon-dropbox.png) no-repeat center 5px / 51px 49px;
165
  }
 
166
  .uploaded-doccument.ead-drive {
167
  background: url(../images/icon-drive.png) no-repeat center 5px / 48px 49px;
168
  }
 
169
  .uploaded-doccument.ead-box {
170
  background: url(../images/icon-box.png) no-repeat center 5px / 54px 49px;
171
  }
 
172
  .wp-core-ui .button#adv-options {
173
  float: right;
174
  height: 40px;
@@ -176,20 +228,24 @@ a.go-back {
176
  font-size: 13px;
177
  padding: 0 20px;
178
  }
 
179
  .uploaded-doccument p {
180
  font-weight: bold;
181
  font-size: 16px;
182
  margin: 0 0 3px;
183
  }
 
184
  input.input-group-text {
185
  padding: 5px 8px;
186
  height: 40px;
187
  min-width: 88%;
188
  }
 
189
  .wp-core-ui .button-primary.input-group-btn {
190
  padding: 5px 10px;
191
  height: 40px;
192
  }
 
193
  .advanced-options {
194
  padding: 30px;
195
  -moz-box-sizing: border-box;
@@ -199,49 +255,44 @@ input.input-group-text {
199
  width: 80%;
200
  border-left: 1px solid #ebebeb;
201
  }
 
202
  .advanced-options h3 {
203
  margin-top: 0px
204
  }
 
205
  .advanced-options h3 span {
206
  color: #aaa;
207
  font-weight: normal;
208
  }
209
- body.mfp-shown .mfp-bg {
210
- z-index: 1010;
211
- }
212
- body.mfp-shown .mfp-wrap {
213
- z-index: 1011;
214
- }
215
- body.mfp-shown .mfp-preloader {
216
- z-index: 1012;
217
- }
218
- body.mfp-shown .mfp-content {
219
- z-index: 1013;
220
- }
221
- body.mfp-shown button.mfp-close, body.mfp-shown button.mfp-arrow {
222
- z-index: 1014;
223
  }
 
224
  .wp-core-ui .ead-btn.button-large {
225
  padding: 0 30px;
226
  height: 54px;
227
  line-height: 52px;
228
  font-size: 16px;
229
  }
 
230
  .wp-core-ui .ead-btn.button-medium {
231
  padding: 0 15px;
232
  height: 36px;
233
  line-height: 34px;
234
  font-size: 14px;
235
  }
 
236
  .text-center {
237
  text-align: center;
238
  }
239
- .mfp-close {
 
240
  position: absolute;
241
  right: 30px;
242
  top: 30px;
243
  font-weight: bold;
244
- background: url(../images/icon-close.png)!important;
245
  width: 22px;
246
  height: 22px;
247
  display: block;
@@ -251,134 +302,181 @@ body.mfp-shown button.mfp-close, body.mfp-shown button.mfp-arrow {
251
  opacity: 0.65;
252
  padding: 0;
253
  }
254
- .mfp-close:hover{
 
255
  opacity: 1;
256
  }
 
257
  .mfp-close .upload-success {
258
  display: none;
259
  }
260
- div.awsm-error, div.awsm-updated {
 
 
 
 
 
 
261
  margin: 5px 0 2px;
262
  border-width: 1px 1px 1px 4px;
263
  border-style: solid;
264
  -webkit-border-radius: 4px;
265
  border-radius: 4px;
266
  }
 
267
  div.awsm-updated {
268
  background-color: #fff;
269
  border-color: #eee #eee #eee #7ad03a;
270
  padding: 1px 12px;
271
  }
 
272
  div.awsm-error {
273
  background: none repeat scroll 0 0 #fff;
274
  border-color: #eee #eee #eee #dd3d36;
275
  padding: 1px 12px;
276
  }
277
- div.awsm-error p, div.awsm-updated p {
 
 
278
  margin: 0.5em 0;
279
  padding: 2px;
280
  }
 
281
  .hidden {
282
  display: none;
283
  }
 
284
  .mceActionPanel {
285
  margin: 0;
286
  }
 
287
  .option-fields {
288
  list-style-type: none;
289
  margin: 0;
290
  padding: 20px 0 0;
291
  }
 
292
  .option-fields li {
293
  padding-bottom: 15px;
294
  overflow: hidden;
 
295
  }
 
296
  .option-fields label {
297
  display: block;
298
  margin-bottom: 5px;
299
  font-weight: bold;
300
  }
301
- .option-fields li.checkbox input{ float: left; margin: 2px 10px 0 0;}
302
- .option-fields li.checkbox label{ float: left; margin: 0 0 0; font-weight: normal;}
 
 
 
 
 
 
 
 
 
 
303
  .f-left {
304
  float: left;
305
  }
 
306
  .option-fields .f-left {
307
  margin-right: 25px;
308
  max-width: 160px;
309
- margin-bottom: 6px;
310
  }
311
- #ead-download-text input{
312
- width: 100px;
313
- }
314
- .option-fields .f-left select, .option-fields .f-left input{
315
- height: 32px;
316
  padding: 6px;
 
317
  }
318
- .option-fields .f-left select{
 
319
  width: 100%;
320
  }
 
 
 
 
 
321
  .option-fields .f-left.last {
322
  margin: 0;
323
  }
 
324
  .clear {
325
  clear: both;
326
  }
 
327
  .input-small {
328
  width: 60px;
329
  }
 
330
  .box .urlerror {
331
  border-color: #D95B5B;
332
  -webkit-box-shadow: 0 0 2px rgba(190, 30, 30, 0.8);
333
  box-shadow: 0 0 2px rgba(190, 30, 30, 0.8);
334
  }
 
335
  .picker-dialog {
336
- z-index: 100091;
337
  }
 
338
  .picker-dialog-bg {
339
- z-index: 100090;
340
  }
341
- .ead-popon #adminmenuwrap{
342
- z-index: 999!important;
 
343
  }
344
- @media (max-width: 915px) {
 
345
  .ead-options li {
346
  width: 33.33%;
347
  padding-bottom: 20px;
348
  margin-bottom: 0;
349
  }
350
- .ead-popup-on #TB_window{
351
- background: #fff;
352
  -webkit-box-shadow: 0 2px 25px #000;
353
- -moz-box-shadow: 0 2px 25px #000;
354
- box-shadow: 0 2px 25px #000;
355
  }
356
  #embed-popup {
357
  box-shadow: none;
358
  -webkit-box-shadow: none;
359
  }
360
  }
361
- @media (max-width: 700px){
362
- .upload-success .inner{
 
 
 
 
363
  width: 100%;
364
- padding: 30px 0;
365
- float: none;
366
  }
367
- .advanced-options{
368
  width: 100%;
369
- padding: 30px 0;
370
- float: none;
371
  border-left: none;
372
  border-top: 1px solid #ebebeb;
373
  }
374
  }
375
- @media (max-width: 600px) {
 
376
  .ead-options li {
377
  width: 50%;
378
  }
 
 
 
 
379
  }
380
- @media (max-width: 440px) {
 
381
  .ead-options li {
382
  width: 100%;
383
  }
384
- }
3
  width: 85%;
4
  margin: 0 auto;
5
  }
6
+
7
+ .ead-popup-on #TB_overlay {
8
+ z-index: 200000 !important;
9
+ }
10
+
11
+ .ead-popup-on #TB_window {
12
  background: none;
13
  box-shadow: none;
14
  -webkit-box-shadow: none;
15
+ z-index: 200001 !important;
16
  }
17
+
18
+ .ead-popup-on .fw-modal .media-modal{
19
+ z-index: 200001 !important;
20
+ }
21
+
22
+ .ead-popup-on #TB_ajaxContent {
23
  text-align: center;
24
  }
25
+
26
+ .ead-popup-on #TB_ajaxContent:after {
27
  content: "";
28
  display: inline-block;
29
  width: 1px;
30
  height: 100%;
31
  vertical-align: middle;
32
  }
33
+
34
  #embed-popup {
35
  position: relative;
36
  width: 99%;
37
+ max-width: 1030px;
38
  background: #fff;
39
  -moz-box-sizing: border-box;
40
  -webkit-box-sizing: border-box;
41
  box-sizing: border-box;
42
  display: inline-block;
43
  vertical-align: middle;
44
+ -webkit-box-shadow: 2px 2px 6px rgba(0, 0, 0, 0.5);
45
+ -moz-box-shadow: 2px 2px 6px rgba(0, 0, 0, 0.5);
46
+ box-shadow: 2px 2px 6px rgba(0, 0, 0, 0.5);
47
  text-align: left;
 
48
  }
49
+
50
+ .ead-popup-header {
51
  padding: 20px 30px;
52
  }
53
+
54
+ .ead-popup-header h1 {
55
  margin: 0;
56
  line-height: 1.3;
57
  }
58
+
59
  .ead-section {
60
  padding: 0 30px;
61
  border-top: 1px solid #ebebeb;
62
  }
63
+
64
+ .ead-action-panel {
65
+ padding: 20px 30px;
66
  background: #f5f5f5;
67
  border-top: 1px solid #ebebeb;
68
  }
69
+
70
  ul.ead-options {
71
  padding: 30px 0;
72
  overflow: hidden;
73
  margin: 0px;
74
  }
75
+
76
  .ead-options li {
77
  float: left;
78
  width: 20%;
81
  -webkit-box-sizing: border-box;
82
  box-sizing: border-box;
83
  }
84
+
85
  .ead-options li a {
86
  display: block;
87
  text-decoration: none;
88
  color: rgb(33, 33, 33);
89
  }
90
+
91
  .ead-options li span {
92
+ border: 1px solid #dfdfdf;
93
  -webkit-border-radius: 4px;
94
  border-radius: 4px;
95
  display: block;
96
+ padding: 44px 10px;
97
  text-align: center;
98
  position: relative;
99
+ -webkit-transition: all 0.3s ease;
100
+ -moz-transition: all 0.3s ease;
101
+ -ms-transition: all 0.3s ease;
102
+ -o-transition: all 0.3s ease;
103
+ transition: all 0.3s ease;
104
  }
105
+
106
+ .ead-options li span:hover {
107
+ -webkit-box-shadow: 1px 1px 3px rgba(0, 0, 0, 0.15);
108
+ box-shadow: 1px 1px 3px rgba(0, 0, 0, 0.15);
109
+ border-color: #ccc;
110
+ }
111
+
112
  .ead-options li img {
113
  display: block;
114
  margin: 0 auto 10px;
115
+ max-height: 50px;
116
  }
117
+
118
  .ead-options li span span.overlay {
119
  border: none;
120
  -webkit-border-radius: 0;
127
  top: 0;
128
  background: rgba(255, 255, 255, 0.7);
129
  }
130
+
131
  .ead-options .overlay strong {
132
  display: inline-block;
133
  max-width: 97%;
139
  -o-transition: all 0.3s ease;
140
  transition: all 0.3s ease;
141
  }
142
+
143
  .ead-options li span:hover {
144
  box-shadow: 1px 1px 3px rgba(0, 0, 0, 0.1);
145
  -webkit-box-shadow: 1px 1px 3px rgba(0, 0, 0, 0.1);
146
  }
147
+
148
  .ead-options li:hover .overlay strong {
149
  opacity: 1;
150
  }
151
+
152
  .ead-options .overlay i {
153
  display: inline-block;
154
  height: 100%;
155
  width: 1px;
156
  vertical-align: middle;
157
  }
158
+
159
  .upload-success {
160
  min-height: 70px;
161
  overflow: hidden;
162
  }
163
+
164
  .upload-success .inner {
165
  padding: 30px 10px;
166
  -moz-box-sizing: border-box;
169
  float: left;
170
  width: 20%;
171
  }
172
+
173
  .box {
174
  display: none;
 
 
 
175
  padding: 20px;
176
  margin: 30px 0;
177
  }
178
+
179
+ .addurl-box.box {
180
+ margin: 10px 0;
181
+ padding: 20px 0;
182
+ }
183
+
184
  a.go-back {
185
  display: inline-block;
186
  margin-top: 20px;
187
  text-decoration: none;
188
  }
189
+
190
  .box label {
191
  display: block;
192
  font-size: 12px;
193
  margin-bottom: 5px;
194
  }
195
+
196
  .uploaded-doccument {
197
  padding: 75px 0 5px;
198
  color: #454545;
200
  word-wrap: break-word;
201
  text-align: center;
202
  }
203
+
204
  .uploaded-doccument.ead-link {
205
  background: url(../images/icon-link.png) no-repeat center 5px / 36px 49px;
206
  }
207
+
208
  .uploaded-doccument.ead-upload {
209
  background: url(../images/icon-upload.png) no-repeat center 5px / 54px 49px;
210
  }
211
+
212
  .uploaded-doccument.ead-dropbox {
213
  background: url(../images/icon-dropbox.png) no-repeat center 5px / 51px 49px;
214
  }
215
+
216
  .uploaded-doccument.ead-drive {
217
  background: url(../images/icon-drive.png) no-repeat center 5px / 48px 49px;
218
  }
219
+
220
  .uploaded-doccument.ead-box {
221
  background: url(../images/icon-box.png) no-repeat center 5px / 54px 49px;
222
  }
223
+
224
  .wp-core-ui .button#adv-options {
225
  float: right;
226
  height: 40px;
228
  font-size: 13px;
229
  padding: 0 20px;
230
  }
231
+
232
  .uploaded-doccument p {
233
  font-weight: bold;
234
  font-size: 16px;
235
  margin: 0 0 3px;
236
  }
237
+
238
  input.input-group-text {
239
  padding: 5px 8px;
240
  height: 40px;
241
  min-width: 88%;
242
  }
243
+
244
  .wp-core-ui .button-primary.input-group-btn {
245
  padding: 5px 10px;
246
  height: 40px;
247
  }
248
+
249
  .advanced-options {
250
  padding: 30px;
251
  -moz-box-sizing: border-box;
255
  width: 80%;
256
  border-left: 1px solid #ebebeb;
257
  }
258
+
259
  .advanced-options h3 {
260
  margin-top: 0px
261
  }
262
+
263
  .advanced-options h3 span {
264
  color: #aaa;
265
  font-weight: normal;
266
  }
267
+
268
+ .ead-popup-on .media-modal {
269
+ z-index: 200003 !important;
 
 
 
 
 
 
 
 
 
 
 
270
  }
271
+
272
  .wp-core-ui .ead-btn.button-large {
273
  padding: 0 30px;
274
  height: 54px;
275
  line-height: 52px;
276
  font-size: 16px;
277
  }
278
+
279
  .wp-core-ui .ead-btn.button-medium {
280
  padding: 0 15px;
281
  height: 36px;
282
  line-height: 34px;
283
  font-size: 14px;
284
  }
285
+
286
  .text-center {
287
  text-align: center;
288
  }
289
+
290
+ .ead-popup-on .ead-close {
291
  position: absolute;
292
  right: 30px;
293
  top: 30px;
294
  font-weight: bold;
295
+ background: url(../images/icon-close.png) !important;
296
  width: 22px;
297
  height: 22px;
298
  display: block;
302
  opacity: 0.65;
303
  padding: 0;
304
  }
305
+
306
+ .mfp-close:hover {
307
  opacity: 1;
308
  }
309
+
310
  .mfp-close .upload-success {
311
  display: none;
312
  }
313
+
314
+ #embed-message {
315
+ margin-top: 20px;
316
+ }
317
+
318
+ div.awsm-error,
319
+ div.awsm-updated {
320
  margin: 5px 0 2px;
321
  border-width: 1px 1px 1px 4px;
322
  border-style: solid;
323
  -webkit-border-radius: 4px;
324
  border-radius: 4px;
325
  }
326
+
327
  div.awsm-updated {
328
  background-color: #fff;
329
  border-color: #eee #eee #eee #7ad03a;
330
  padding: 1px 12px;
331
  }
332
+
333
  div.awsm-error {
334
  background: none repeat scroll 0 0 #fff;
335
  border-color: #eee #eee #eee #dd3d36;
336
  padding: 1px 12px;
337
  }
338
+
339
+ div.awsm-error p,
340
+ div.awsm-updated p {
341
  margin: 0.5em 0;
342
  padding: 2px;
343
  }
344
+
345
  .hidden {
346
  display: none;
347
  }
348
+
349
  .mceActionPanel {
350
  margin: 0;
351
  }
352
+
353
  .option-fields {
354
  list-style-type: none;
355
  margin: 0;
356
  padding: 20px 0 0;
357
  }
358
+
359
  .option-fields li {
360
  padding-bottom: 15px;
361
  overflow: hidden;
362
+ margin-bottom: 0;
363
  }
364
+
365
  .option-fields label {
366
  display: block;
367
  margin-bottom: 5px;
368
  font-weight: bold;
369
  }
370
+
371
+ .option-fields li.checkbox input {
372
+ float: left;
373
+ margin: 2px 10px 0 0;
374
+ }
375
+
376
+ .option-fields li.checkbox label {
377
+ float: left;
378
+ margin: 0 0 0;
379
+ font-weight: normal;
380
+ }
381
+
382
  .f-left {
383
  float: left;
384
  }
385
+
386
  .option-fields .f-left {
387
  margin-right: 25px;
388
  max-width: 160px;
 
389
  }
390
+
391
+ .option-fields .f-left input,
392
+ .option-fields .f-left select {
393
+ height: 34px;
 
394
  padding: 6px;
395
+ margin-bottom: 10px;
396
  }
397
+
398
+ .option-fields .f-left select {
399
  width: 100%;
400
  }
401
+
402
+ #ead-download-text input {
403
+ width: 100px;
404
+ }
405
+
406
  .option-fields .f-left.last {
407
  margin: 0;
408
  }
409
+
410
  .clear {
411
  clear: both;
412
  }
413
+
414
  .input-small {
415
  width: 60px;
416
  }
417
+
418
  .box .urlerror {
419
  border-color: #D95B5B;
420
  -webkit-box-shadow: 0 0 2px rgba(190, 30, 30, 0.8);
421
  box-shadow: 0 0 2px rgba(190, 30, 30, 0.8);
422
  }
423
+
424
  .picker-dialog {
425
+ z-index: 20000091 !important;
426
  }
427
+
428
  .picker-dialog-bg {
429
+ z-index: 20000090 !important;
430
  }
431
+
432
+ .ead-popon #adminmenuwrap {
433
+ z-index: 999 !important;
434
  }
435
+
436
+ @media (max-width:915px) {
437
  .ead-options li {
438
  width: 33.33%;
439
  padding-bottom: 20px;
440
  margin-bottom: 0;
441
  }
442
+ .ead-popup-on #TB_window {
443
+ background: #fff;
444
  -webkit-box-shadow: 0 2px 25px #000;
445
+ -moz-box-shadow: 0 2px 25px #000;
446
+ box-shadow: 0 2px 25px #000;
447
  }
448
  #embed-popup {
449
  box-shadow: none;
450
  -webkit-box-shadow: none;
451
  }
452
  }
453
+
454
+ @media (max-width:700px) {
455
+ .ead-section {
456
+ padding: 0;
457
+ }
458
+ .upload-success .inner {
459
  width: 100%;
 
 
460
  }
461
+ .advanced_options {
462
  width: 100%;
 
 
463
  border-left: none;
464
  border-top: 1px solid #ebebeb;
465
  }
466
  }
467
+
468
+ @media (max-width:600px) {
469
  .ead-options li {
470
  width: 50%;
471
  }
472
+ #ead_downloadc select,
473
+ #new_provider select {
474
+ width: 100%;
475
+ }
476
  }
477
+
478
+ @media (max-width:440px) {
479
  .ead-options li {
480
  width: 100%;
481
  }
482
+ }
css/settings.css CHANGED
@@ -1,93 +1,125 @@
 
 
 
 
 
 
1
  img {
2
  max-width: 100%;
3
  height: auto;
4
  }
 
5
  .clear {
6
  clear: both;
7
  }
 
8
  .f-left {
9
  float: left;
10
  }
 
11
  .fl-right {
12
  float: right;
13
  }
14
- .tabs {
15
- display: none;
16
  background: #fff;
17
- padding: 20px 20px 0;
18
  }
19
- .tabs.visible {
 
 
 
 
20
  display: block;
21
  }
 
 
 
 
 
 
22
  .nav-tab-wrapper a {
23
- background: none;
24
  border: none;
 
 
 
25
  }
 
26
  .nav-tab-wrapper a:hover {
27
  border: none;
 
28
  }
 
29
  .nav-tab-wrapper a.nav-tab-active {
30
  background: #fff;
31
  }
 
32
  .form-table {
33
  margin-top: 0;
34
- padding-top: 0.5em;
35
- margin-bottom: 20px;
36
  }
 
37
  h2.nav-tab-wrapper {
38
  border: none;
39
  padding-left: 0;
40
  }
41
- h2.ead-title {
42
- background: url(../images/icon-ead.png) no-repeat 0 14px;
43
- padding-left: 46px !important;
44
- padding-bottom: 25px !important;
45
  }
 
46
  .ead-left-wrap {
 
 
47
  float: left;
48
- width: 100%;
49
  -moz-box-sizing: border-box;
50
  -webkit-box-sizing: border-box;
51
  box-sizing: border-box;
52
- padding-right: 340px;
53
- margin-right: -340px;
54
  }
55
- .ead-left-wrap h3{
56
- font-weight: 300;
57
- font-size: 20px;
58
- margin: 0 0 20px;
59
- }
60
- .ead-form-footer{
61
  margin: 0 -20px;
62
  padding: 20px;
63
  background: #f5f5f5;
64
  border-top: 1px solid #ddd;
65
- -webkit-box-shadow: 0 1px 2px 0 rgba(0,0,0,0.1);
66
- box-shadow: 0 1px 2px 0 rgba(0,0,0,0.1);
67
  overflow: hidden;
68
  }
69
- .ead-form-footer p{
 
70
  margin: 0;
71
  float: right;
72
  padding: 0;
73
  }
74
- .ead-form-footer .button{
75
- height: 42px;
 
76
  }
 
 
 
77
  .ead-right-wrap {
78
- float: right;
79
- max-width: 300px;
80
  color: #372e2e;
 
 
 
 
81
  }
82
- .ead-banner{
83
- text-align: center;
84
- padding-top: 20px;
 
85
  }
 
86
  .ead-right-inner {
87
  background: #fff;
88
- margin-bottom: 10px;
89
  }
90
- .ead-right-inner h3{
 
91
  margin: 0;
92
  padding: 15px 20px;
93
  border-bottom: 1px solid #ddd;
@@ -96,133 +128,165 @@ h2.ead-title {
96
  color: #5b5b5b;
97
  font-weight: normal;
98
  }
99
- .ead-right-inner ol{
 
100
  padding: 0 20px 15px;
101
  margin: 0 0 0 20px;
102
  }
103
- .ead-right-inner ol a{
 
104
  text-decoration: none;
105
  }
106
- .author-info {
107
- padding: 10px 15px;
108
- text-align: center;
 
 
 
 
 
109
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
110
  .awsm-social {
111
- text-align: center;
112
  list-style-type: none;
113
- padding: 15px;
114
- border-bottom: 1px solid #dadada;
115
- margin: 0;
116
  }
 
117
  .awsm-social li {
118
  display: inline-block;
119
- margin: 0 6px;
120
  }
 
121
  .awsm-icon {
122
- background: url(../images/ead-icon-sprite.jpg) no-repeat;
123
  display: block;
124
  width: 21px;
125
- height: 21px;
126
  text-indent: -999999px;
127
  opacity: 0.46;
 
 
 
 
 
128
  }
 
129
  .awsm-icon:hover {
130
  opacity: 1;
131
  }
132
- .awsm-icon-facebook {} .awsm-icon-twitter {
 
133
  background-position: -26px 0;
134
  }
 
135
  .awsm-icon-github {
136
- background-position: -52px 0;
137
  }
 
138
  .awsm-icon-behance {
139
  background-position: -78px 0;
140
  width: 28px;
141
  }
 
142
  .awsm-icon-dribbble {
143
  background-position: right 0;
144
  }
 
145
  .paypal {
146
  text-align: center;
147
  }
 
148
  .paypal input.small {
149
  vertical-align: top;
150
  margin-right: 20px;
151
  }
 
152
  .paypal .donate-btn {
153
  vertical-align: top;
154
  padding: 0;
155
  }
 
156
  input.small {
157
  max-width: 60px;
158
  }
 
159
  .ead-frame-width {
160
  margin-right: 15px;
161
  margin-bottom: 10px;
162
  }
 
163
  .ead-frame-height {
164
  margin-bottom: 10px;
165
  }
166
- .row-col{
167
- margin: 0 -5px 10px;
168
- overflow: hidden;
169
- }
170
- .col-2{
171
- float: left;
172
- padding: 0 5px;
173
- width: 50%;
174
- -moz-box-sizing: border-box;
175
- -webkit-box-sizing: border-box;
176
- box-sizing: border-box;
177
- }
178
- .col-2 a{
179
- background: #fff;
180
- display: block;
181
- text-align: center;
182
- padding: 25px 10px;
183
- text-decoration: none;
184
- }
185
 
186
- .col-2 a img{
187
- display: block;
188
- margin: 0 auto 10px;
189
- }
190
- span.note, .ead_supported {
191
  font-size: 12px;
192
  color: #999;
193
  }
194
- div.awsm-error, div.awsm-updated {
 
 
195
  margin: 5px 0 2px;
196
  border-width: 1px 1px 1px 4px;
197
  border-style: solid;
198
  -webkit-border-radius: 4px;
199
  border-radius: 4px;
200
  }
 
201
  div.awsm-updated {
202
  background-color: #fff;
203
  border-color: #eee #eee #eee #7ad03a;
204
  padding: 1px 12px;
205
  }
 
206
  div.awsm-error {
207
  background: none repeat scroll 0 0 #fff;
208
  border-color: #eee #eee #eee #dd3d36;
209
  padding: 1px 12px;
210
  }
211
- div.awsm-error p, div.awsm-updated p {
 
 
212
  margin: 0.5em 0;
213
  padding: 2px;
214
  }
215
- .ead_doller {
 
216
  display: inline-block;
217
  vertical-align: top;
218
  margin: 5px 5px 0 0;
219
  font-weight: bold;
220
  }
 
221
  #supportform label {
222
  display: block;
223
  margin-bottom: 5px;
224
  font-weight: bold;
225
  }
 
226
  .text-input {
227
  width: 100%;
228
  height: 40px;
@@ -230,24 +294,30 @@ div.awsm-error p, div.awsm-updated p {
230
  -webkit-box-sizing: border-box;
231
  box-sizing: border-box;
232
  }
 
233
  #supportform textarea {
234
  -moz-box-sizing: border-box;
235
  -webkit-box-sizing: border-box;
236
  box-sizing: border-box;
237
  width: 100%;
 
238
  }
239
- .ead_supported span {
 
240
  display: block;
241
  font-weight: bold;
242
  margin-top: 10px;
243
  }
 
244
  .supportedlist ul {
245
  margin-top: 5px;
246
  }
 
247
  .supportedlist li {
248
  padding-left: 17px;
249
  position: relative;
250
  }
 
251
  .supportedlist li span {
252
  position: absolute;
253
  left: 0;
@@ -256,38 +326,162 @@ div.awsm-error p, div.awsm-updated p {
256
  height: 11px;
257
  margin: 0;
258
  }
 
259
  .supportedlist li span.ead-check {
260
  background: url(../images/icon-yes.png) no-repeat;
261
  }
 
262
  .supportedlist li span.ead-close {
263
  background: url(../images/icon-no.png) no-repeat;
264
  }
 
265
  .col-left {
266
  float: left;
267
  width: 47%;
268
  margin-right: 6%;
269
  }
 
270
  .col-right {
271
  float: right;
272
  width: 47%;
273
  }
274
- @media (max-width: 800px) {
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
275
  .ead-left-wrap {
276
- float: none;
277
  width: 100%;
278
- margin-bottom: 30px;
279
- padding-right: 0;
280
- margin-right: 0;
281
  }
282
  .ead-right-wrap {
283
- float: none;
284
  width: 100%;
285
  }
286
  }
 
287
  @media (max-width: 980px) {
288
- .col-left, .col-right {
 
289
  float: none;
290
  width: 100%;
291
  margin-right: 0%;
292
  }
293
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ .clearfix::after {
2
+ content: "";
3
+ clear: both;
4
+ display: table;
5
+ }
6
+
7
  img {
8
  max-width: 100%;
9
  height: auto;
10
  }
11
+
12
  .clear {
13
  clear: both;
14
  }
15
+
16
  .f-left {
17
  float: left;
18
  }
19
+
20
  .fl-right {
21
  float: right;
22
  }
23
+
24
+ .ead-tabs {
25
  background: #fff;
26
+ padding: 5px 20px 0;
27
  }
28
+ h1.ead-title{
29
+ margin-bottom: 10px;
30
+ }
31
+
32
+ .ead-tabs.visible {
33
  display: block;
34
  }
35
+
36
+ #supportform p.submit {
37
+ border: none !important;
38
+ padding-top: 0px !important;
39
+ }
40
+
41
  .nav-tab-wrapper a {
 
42
  border: none;
43
+ padding: 7px 15px;
44
+ margin: 0 10px 0 0;
45
+ background: none;
46
  }
47
+
48
  .nav-tab-wrapper a:hover {
49
  border: none;
50
+ background: none;
51
  }
52
+
53
  .nav-tab-wrapper a.nav-tab-active {
54
  background: #fff;
55
  }
56
+
57
  .form-table {
58
  margin-top: 0;
59
+ margin-bottom: 30px;
 
60
  }
61
+
62
  h2.nav-tab-wrapper {
63
  border: none;
64
  padding-left: 0;
65
  }
66
+
67
+ .row {
68
+ margin: 0 -15px;
 
69
  }
70
+
71
  .ead-left-wrap {
72
+ width: 66.66666667%;
73
+ padding: 0 15px;
74
  float: left;
 
75
  -moz-box-sizing: border-box;
76
  -webkit-box-sizing: border-box;
77
  box-sizing: border-box;
 
 
78
  }
79
+
80
+ .ead-form-footer {
 
 
 
 
81
  margin: 0 -20px;
82
  padding: 20px;
83
  background: #f5f5f5;
84
  border-top: 1px solid #ddd;
85
+ -webkit-box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.1);
86
+ box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.1);
87
  overflow: hidden;
88
  }
89
+
90
+ .ead-form-footer p {
91
  margin: 0;
92
  float: right;
93
  padding: 0;
94
  }
95
+
96
+ .purchase-key .ead-inputholder{
97
+ width: 90%;
98
  }
99
+
100
+ /*--- Sidebar -----*/
101
+
102
  .ead-right-wrap {
103
+ float: left;
104
+ width: 33.3333%;
105
  color: #372e2e;
106
+ padding: 0 15px;
107
+ -moz-box-sizing: border-box;
108
+ -webkit-box-sizing: border-box;
109
+ box-sizing: border-box;
110
  }
111
+
112
+ .we-are-awsm {
113
+ background: #fff;
114
+ padding: 26px 20px;
115
  }
116
+
117
  .ead-right-inner {
118
  background: #fff;
119
+ margin-bottom: 15px;
120
  }
121
+
122
+ .ead-right-inner h3 {
123
  margin: 0;
124
  padding: 15px 20px;
125
  border-bottom: 1px solid #ddd;
128
  color: #5b5b5b;
129
  font-weight: normal;
130
  }
131
+
132
+ .ead-right-wrap ol {
133
  padding: 0 20px 15px;
134
  margin: 0 0 0 20px;
135
  }
136
+
137
+ .ead-right-wrap ol a {
138
  text-decoration: none;
139
  }
140
+
141
+ .awsm-branding {
142
+ overflow: hidden;
143
+ }
144
+
145
+ .awsm-branding img {
146
+ float: left;
147
+ margin-right: 15px;
148
  }
149
+
150
+ .left-clear {
151
+ overflow: hidden;
152
+ }
153
+
154
+ .awsm-branding h2 {
155
+ font-size: 12px;
156
+ padding: 0;
157
+ margin: 0;
158
+ line-height: 1.6667;
159
+ }
160
+
161
+ .awsm-branding h3 {
162
+ font-size: 18px;
163
+ padding: 0 0 10px;
164
+ margin: 0;
165
+ }
166
+
167
+ .awsm-branding h3 a {
168
+ text-decoration: none;
169
+ color: #333;
170
+ }
171
+
172
  .awsm-social {
 
173
  list-style-type: none;
174
+ margin: 0 -2px;
 
 
175
  }
176
+
177
  .awsm-social li {
178
  display: inline-block;
179
+ padding: 0 2px;
180
  }
181
+
182
  .awsm-icon {
183
+ background: url(../images/icon-sprite.png) no-repeat;
184
  display: block;
185
  width: 21px;
186
+ height: 17px;
187
  text-indent: -999999px;
188
  opacity: 0.46;
189
+ -webkit-transition: opacity 0.3s ease;
190
+ -moz-transition: opacity 0.3s ease;
191
+ -ms-transition: opacity 0.3s ease;
192
+ -o-transition: opacity 0.3s ease;
193
+ transition: opacity 0.3s ease;
194
  }
195
+
196
  .awsm-icon:hover {
197
  opacity: 1;
198
  }
199
+
200
+ .awsm-icon-twitter {
201
  background-position: -26px 0;
202
  }
203
+
204
  .awsm-icon-github {
205
+ background-position: -53px 0;
206
  }
207
+
208
  .awsm-icon-behance {
209
  background-position: -78px 0;
210
  width: 28px;
211
  }
212
+
213
  .awsm-icon-dribbble {
214
  background-position: right 0;
215
  }
216
+
217
  .paypal {
218
  text-align: center;
219
  }
220
+
221
  .paypal input.small {
222
  vertical-align: top;
223
  margin-right: 20px;
224
  }
225
+
226
  .paypal .donate-btn {
227
  vertical-align: top;
228
  padding: 0;
229
  }
230
+
231
  input.small {
232
  max-width: 60px;
233
  }
234
+
235
  .ead-frame-width {
236
  margin-right: 15px;
237
  margin-bottom: 10px;
238
  }
239
+
240
  .ead-frame-height {
241
  margin-bottom: 10px;
242
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
243
 
244
+ span.note,
245
+ .ead-supported {
 
 
 
246
  font-size: 12px;
247
  color: #999;
248
  }
249
+
250
+ div.awsm-error,
251
+ div.awsm-updated {
252
  margin: 5px 0 2px;
253
  border-width: 1px 1px 1px 4px;
254
  border-style: solid;
255
  -webkit-border-radius: 4px;
256
  border-radius: 4px;
257
  }
258
+
259
  div.awsm-updated {
260
  background-color: #fff;
261
  border-color: #eee #eee #eee #7ad03a;
262
  padding: 1px 12px;
263
  }
264
+
265
  div.awsm-error {
266
  background: none repeat scroll 0 0 #fff;
267
  border-color: #eee #eee #eee #dd3d36;
268
  padding: 1px 12px;
269
  }
270
+
271
+ div.awsm-error p,
272
+ div.awsm-updated p {
273
  margin: 0.5em 0;
274
  padding: 2px;
275
  }
276
+
277
+ .ead-doller {
278
  display: inline-block;
279
  vertical-align: top;
280
  margin: 5px 5px 0 0;
281
  font-weight: bold;
282
  }
283
+
284
  #supportform label {
285
  display: block;
286
  margin-bottom: 5px;
287
  font-weight: bold;
288
  }
289
+
290
  .text-input {
291
  width: 100%;
292
  height: 40px;
294
  -webkit-box-sizing: border-box;
295
  box-sizing: border-box;
296
  }
297
+
298
  #supportform textarea {
299
  -moz-box-sizing: border-box;
300
  -webkit-box-sizing: border-box;
301
  box-sizing: border-box;
302
  width: 100%;
303
+ min-height: 150px;
304
  }
305
+
306
+ .ead-supported span {
307
  display: block;
308
  font-weight: bold;
309
  margin-top: 10px;
310
  }
311
+
312
  .supportedlist ul {
313
  margin-top: 5px;
314
  }
315
+
316
  .supportedlist li {
317
  padding-left: 17px;
318
  position: relative;
319
  }
320
+
321
  .supportedlist li span {
322
  position: absolute;
323
  left: 0;
326
  height: 11px;
327
  margin: 0;
328
  }
329
+
330
  .supportedlist li span.ead-check {
331
  background: url(../images/icon-yes.png) no-repeat;
332
  }
333
+
334
  .supportedlist li span.ead-close {
335
  background: url(../images/icon-no.png) no-repeat;
336
  }
337
+
338
  .col-left {
339
  float: left;
340
  width: 47%;
341
  margin-right: 6%;
342
  }
343
+
344
  .col-right {
345
  float: right;
346
  width: 47%;
347
  }
348
+
349
+ .cloudform {
350
+ margin: 0;
351
+ }
352
+
353
+ .cloudform > li {
354
+ border: 1px solid #eee;
355
+ -webkit-border-radius: 4px;
356
+ border-radius: 4px;
357
+ padding: 30px 10px;
358
+ margin-bottom: 20px;
359
+ overflow: hidden;
360
+ }
361
+
362
+ .ead-cloud {
363
+ float: left;
364
+ padding: 0 5px;
365
+ -moz-box-sizing: border-box;
366
+ -webkit-box-sizing: border-box;
367
+ box-sizing: border-box;
368
+ }
369
+
370
+ .ead-cloud.ead-service {
371
+ text-align: center;
372
+ width: 14%;
373
+ }
374
+
375
+ .ead-cloud.ead-setup {
376
+ width: 53%;
377
+ }
378
+
379
+ .ead-cloud.ead-config {
380
+ width: 30%;
381
+ }
382
+
383
+ .ead-cloud span {
384
+ display: block;
385
+ font-weight: bold;
386
+ color: #ccc;
387
+ }
388
+
389
+ .ead-cloud label {
390
+ display: block;
391
+ font-weight: bold;
392
+ margin-bottom: 5px;
393
+ }
394
+
395
+ .ead-inputholder {
396
+ float: left;
397
+ -moz-box-sizing: border-box;
398
+ -webkit-box-sizing: border-box;
399
+ box-sizing: border-box;
400
+ width: 50%;
401
+ padding: 0 5px;
402
+ }
403
+
404
+ .ead-inputholder input {
405
+ -moz-box-sizing: border-box;
406
+ -webkit-box-sizing: border-box;
407
+ box-sizing: border-box;
408
+ width: 100%;
409
+ }
410
+
411
+ .ead-cloud ol {
412
+ list-style: none;
413
+ margin: 0;
414
+ }
415
+
416
+ .ead-right-widget {
417
+ margin-bottom: 15px;
418
+ }
419
+
420
+ .row-2 {
421
+ margin-left: -1px;
422
+ margin-right: -1px;
423
+ }
424
+
425
+ .col-2 {
426
+ float: left;
427
+ padding: 0 1px;
428
+ width: 50%;
429
+ -moz-box-sizing: border-box;
430
+ -webkit-box-sizing: border-box;
431
+ box-sizing: border-box;
432
+ }
433
+
434
+ .col-2 a {
435
+ background: #fff;
436
+ display: block;
437
+ text-align: center;
438
+ padding: 25px 10px;
439
+ text-decoration: none;
440
+ }
441
+
442
+ .col-2 a img {
443
+ display: block;
444
+ margin: 0 auto 10px;
445
+ }
446
+
447
+ .settings_page_ead-plus-settings .nav-tab-wrapper {
448
+ border: none;
449
+ }
450
+
451
+ @media (max-width: 1024px) {
452
  .ead-left-wrap {
 
453
  width: 100%;
454
+ margin-bottom: 25px;
 
 
455
  }
456
  .ead-right-wrap {
 
457
  width: 100%;
458
  }
459
  }
460
+
461
  @media (max-width: 980px) {
462
+ .col-left,
463
+ .col-right {
464
  float: none;
465
  width: 100%;
466
  margin-right: 0%;
467
  }
468
  }
469
+
470
+ @media (max-width: 600px) {
471
+ .ead-cloud {
472
+ width: 100% !important;
473
+ text-align: left !important;
474
+ float: none;
475
+ margin-bottom: 20px;
476
+ }
477
+ .ead-inputholder {
478
+ float: none;
479
+ width: 100%;
480
+ margin-bottom: 8px;
481
+ }
482
+ }
483
+
484
+
485
+ .ead-banner{
486
+ margin-top: 40px;
487
+ }
images/awsm-logo.png ADDED
Binary file
images/icon-sprite.png ADDED
Binary file
images/star.gif CHANGED
Binary file
inc/popup.php CHANGED
@@ -1,90 +1,100 @@
1
- <?php if( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly ?>
 
 
2
  <div id="embed-popup-wrap">
3
  <div id="embed-popup">
4
- <button title="<?php _e('Close',$this->text_domain);?>" type="button" class="mfp-close">×</button>
5
  <div id="popup-header" class="ead-popup-header">
6
- <h1><?php _e('Add Document',$this->text_domain);?></h1>
7
  </div>
8
  <div class="ead-section">
9
  <div id="embed-message" class="awsm-error" style="display:none;"><p></p></div>
10
  <div class="ead-container">
11
- <form action="" onSubmit="return false" method="post" enctype="multipart/form-data" id="docuploader">
12
- <ul class="ead-options">
13
- <li><a href="#" id="upload-doc"><span><img src="<?php echo $this->plugin_url;?>images/icon-upload.png" alt="Upload document" /><?php _e('Upload Document',$this->text_domain);?></span></a></li>
14
- <li><a href="#" id="add-ead-document"><span><img src="<?php echo $this->plugin_url;?>images/icon-link.png" alt="Add From URL" /><?php _e('Add from URL',$this->text_domain);?></span></a></li>
15
- <li><?php echo $this->providerlink('Drive') ;?></li>
16
- <li><?php echo $this->providerlink('Dropbox') ;?></li>
17
- <li><?php echo $this->providerlink('Box') ;?></li>
18
- </ul>
19
- <div class="box addurl-box">
20
- <label for="awsm-url"><?php _e('Enter document URL',$this->text_domain);?></label>
21
- <input name="awsm-url" type="text" class="opt dwl input-group-text" placeholder="Eg: http://www.yoursite.com/file.pdf" id="awsm-url"/>
22
- <input type="button" value="<?php _e('Add URL',$this->text_domain);?>" class="ead-btn button-primary input-group-btn" id="ead-add-url"/>
23
- <div class="clear"></div>
24
- <a href="#" class="go-back">&larr; <?php _e('back',$this->text_domain);?></a>
25
- </div>
26
- </form>
 
 
 
 
27
  </div><!--ead-container-->
28
  <div class="upload-success">
29
  <div class="inner">
30
- <div class="uploaded-doccument">
31
- <p id="ead-filename"></p>
32
- <span id="ead-filesize"></span>
33
- </div>
34
- <div class="clear"></div>
35
  </div>
36
  <div class="advanced-options">
37
- <h3><?php _e('Advanced Options',$this->text_domain);?></span></h3>
38
- <ul class="option-fields">
39
- <li>
40
- <div class="f-left"><label><?php _e('Width',$this->text_domain);?></label> <input type="text" name="width" class="embedval input-small" id="ead-width" value="<?php echo get_option('ead-width', '100%' );?>"></div>
41
- <div class="f-left"><label><?php _e('Height',$this->text_domain);?></label> <input type="text" name="height" class="embedval input-small" id="ead-height" value="<?php echo get_option('ead_height', '100%' );?>"></div>
42
- <div class="f-left" id="ead-downloadc">
43
- <label><?php _e('Show Download Link',$this->text_domain);?></label>
44
- <?php
45
- $downoptions= array('all' => __('For all users',$this->text_domain),'logged' => __('For Logged-in users',$this->text_domain),'none' => __('No Download',$this->text_domain));
46
- $this->selectbuilder('ead-download', $downoptions,esc_attr( get_option('ead_download')),'ead-usc');
47
- ?>
48
- </div>
49
- <div class="f-left" id="ead-download-text">
50
- <label><?php _e('Download Text',$this->text_domain);?></label>
51
- <input type="text" name="text" class="embedval" id="ead-text" value="<?php echo get_option('ead_text', 'Download' );?>">
52
- </div>
53
- <div class="f-left last" id="new-provider">
54
- <label><?php _e('Viewer',$this->text_domain);?></label>
55
- <?php
56
- $providers = array('google' => __('Google Docs Viewer',$this->text_domain),'microsoft' => __('Microsoft Office Online',$this->text_domain));
57
- $this->selectbuilder('ead-provider', $providers,esc_attr( get_option('ead_provider','google')),'ead-usc');
58
- ?>
59
- </div>
60
- <div class="f-left last" id="ead-pseudo" style="display:none">
61
- <label><?php _e('Viewer',$this->text_domain);?></label>
62
- <select name="ead-pseudo" disabled>
63
- <option value="box"><?php _e('Box',$this->text_domain);?></option>
64
- <option value="drive"><?php _e('Drive',$this->text_domain);?></option>
65
- </select>
66
- </div>
67
- <div class="clear"></div>
68
- </li>
69
-
70
- <li>
71
- <label><?php _e('Shortcode Preview',$this->text_domain); ?></label>
72
- <textarea name="shortcode" style="width:100%" id="shortcode" readonly="readonly"></textarea>
73
- </li>
74
- </ul>
 
 
 
 
 
75
  </div>
76
  </div>
77
- </div>
78
  <div class="mceActionPanel ead-action-panel">
79
- <div style="float: right">
80
- <input type="button" id="insert-doc" name="insert" data-txt="<?php _e('Insert', $this->text_domain); ?>" data-loading="<?php _e('Loading...', $this->text_domain); ?>" class="ead-btn button button-primary button-medium" value="<?php _e('Insert', $this->text_domain); ?>" disabled/>
81
- </div>
82
-
83
- <div style="float: left">
84
- <input type="button" name="cancel" class="ead-btn button cancel-embed button-medium" value="<?php _e('Cancel', $this->text_domain); ?>" />
85
- </div>
86
- <div class="clear"></div>
87
  </div>
88
-
89
  </div>
90
  </div>
1
+ <?php if ( ! defined( 'ABSPATH' ) ) {
2
+ exit;
3
+ } // Exit if accessed directly ?>
4
  <div id="embed-popup-wrap">
5
  <div id="embed-popup">
6
+ <button title="<?php esc_html_e( 'Close', 'embed-any-document' ); ?>" type="button" class="ead-close">×</button>
7
  <div id="popup-header" class="ead-popup-header">
8
+ <h1><?php esc_html_e( 'Add Document', 'embed-any-document' ); ?></h1>
9
  </div>
10
  <div class="ead-section">
11
  <div id="embed-message" class="awsm-error" style="display:none;"><p></p></div>
12
  <div class="ead-container">
13
+ <form action="" onSubmit="return false" method="post" enctype="multipart/form-data" id="docuploader">
14
+ <ul class="ead-options">
15
+ <li>
16
+ <a href="#" id="upload-doc"><span><img src="<?php echo esc_url( $this->plugin_url ); ?>images/icon-upload.png" alt="Upload document"/><?php esc_html_e( 'Upload Document', 'embed-any-document' ); ?></span></a>
17
+ </li>
18
+ <li>
19
+ <a href="#" id="add-ead-document"><span><img src="<?php echo esc_url( $this->plugin_url ); ?>images/icon-link.png" alt="Add From URL"/><?php esc_html_e( 'Add from URL', 'embed-any-document' ); ?></span></a>
20
+ </li>
21
+ <li><?php $this->providerlink( 'Drive' ); ?></li>
22
+ <li><?php $this->providerlink( 'Dropbox' ); ?></li>
23
+ <li><?php $this->providerlink( 'Box' ); ?></li>
24
+ </ul>
25
+ <div class="box addurl-box">
26
+ <label for="awsm-url"><?php esc_html_e( 'Enter document URL', 'embed-any-document' ); ?></label>
27
+ <input name="awsm-url" type="text" class="opt dwl input-group-text" placeholder="Eg: http://www.yoursite.com/file.pdf" id="awsm-url"/>
28
+ <input type="button" value="<?php esc_html_e( 'Add URL', 'embed-any-document' ); ?>" class="ead-btn button-primary input-group-btn" id="ead-add-url"/>
29
+ <div class="clear"></div>
30
+ <a href="#" class="go-back">&larr; <?php esc_html_e( 'back', 'embed-any-document' ); ?></a>
31
+ </div>
32
+ </form>
33
  </div><!--ead-container-->
34
  <div class="upload-success">
35
  <div class="inner">
36
+ <div class="uploaded-doccument">
37
+ <p id="ead-filename"></p>
38
+ <span id="ead-filesize"></span>
39
+ </div>
40
+ <div class="clear"></div>
41
  </div>
42
  <div class="advanced-options">
43
+ <h3><?php esc_html_e( 'Advanced Options', 'embed-any-document' ); ?></span></h3>
44
+ <ul class="option-fields">
45
+ <li>
46
+ <div class="f-left"><label><?php esc_html_e( 'Width', 'embed-any-document' ); ?></label>
47
+ <input type="text" name="width" class="embedval input-small" id="ead-width" value="<?php echo get_option( 'ead-width', '100%' ); ?>">
48
+ </div>
49
+ <div class="f-left"><label><?php esc_html_e( 'Height', 'embed-any-document' ); ?></label>
50
+ <input type="text" name="height" class="embedval input-small" id="ead-height" value="<?php echo get_option( 'ead_height', '100%' ); ?>">
51
+ </div>
52
+ <div class="f-left" id="ead-downloadc">
53
+ <label><?php esc_html_e( 'Show Download Link', 'embed-any-document' ); ?></label>
54
+ <?php
55
+ $downoptions = array( 'all' => __( 'For all users', 'embed-any-document' ), 'logged' => __( 'For Logged-in users', 'embed-any-document' ), 'none' => __( 'No Download', 'embed-any-document' ) );
56
+ $this->selectbuilder( 'ead-download', $downoptions, esc_attr( get_option( 'ead_download' ) ), 'ead-usc' );
57
+ ?>
58
+ </div>
59
+ <div class="f-left" id="ead-download-text">
60
+ <label><?php esc_html_e( 'Download Text', 'embed-any-document' ); ?></label>
61
+ <input type="text" name="text" class="embedval" id="ead-text" value="<?php echo get_option( 'ead_text', 'Download' ); ?>">
62
+ </div>
63
+ <div class="f-left last" id="new-provider">
64
+ <label><?php esc_html_e( 'Viewer', 'embed-any-document' ); ?></label>
65
+ <?php
66
+ $providers = array( 'google' => __( 'Google Docs Viewer', 'embed-any-document' ), 'microsoft' => __( 'Microsoft Office Online', 'embed-any-document' ) );
67
+ $this->selectbuilder( 'ead-provider', $providers, esc_attr( get_option( 'ead_provider', 'google' ) ), 'ead-usc' );
68
+ ?>
69
+ </div>
70
+ <div class="f-left last" id="ead-pseudo" style="display:none">
71
+ <label><?php esc_html_e( 'Viewer', 'embed-any-document' ); ?></label>
72
+ <select name="ead-pseudo" disabled>
73
+ <option value="box"><?php esc_html_e( 'Box', 'embed-any-document' ); ?></option>
74
+ <option value="drive"><?php esc_html_e( 'Drive', 'embed-any-document' ); ?></option>
75
+ </select>
76
+ </div>
77
+ <div class="clear"></div>
78
+ </li>
79
+
80
+ <li>
81
+ <label><?php esc_html_e( 'Shortcode Preview', 'embed-any-document' ); ?></label>
82
+ <textarea name="shortcode" style="width:100%" id="shortcode" readonly="readonly"></textarea>
83
+ </li>
84
+ </ul>
85
+ </div>
86
  </div>
87
  </div>
 
88
  <div class="mceActionPanel ead-action-panel">
89
+ <div style="float: right">
90
+ <input type="button" id="insert-doc" name="insert" data-txt="<?php esc_html_e( 'Insert', 'embed-any-document' ); ?>" data-loading="<?php esc_html_e( 'Loading...', 'embed-any-document' ); ?>" class="ead-btn button button-primary button-medium" value="<?php esc_html_e( 'Insert', 'embed-any-document' ); ?>" disabled/>
91
+ </div>
92
+
93
+ <div style="float: left">
94
+ <input type="button" name="cancel" class="ead-btn button cancel-embed button-medium" value="<?php esc_html_e( 'Cancel', 'embed-any-document' ); ?>"/>
95
+ </div>
96
+ <div class="clear"></div>
97
  </div>
98
+
99
  </div>
100
  </div>
inc/settings.php CHANGED
@@ -1,83 +1,114 @@
1
- <?php if( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly ?>
 
 
2
  <div class="wrap">
3
- <h2 class="ead-title">Embed Any Document by AWSM.in</h2>
4
- <div class="ead-left-wrap">
5
-
6
- <div class="tabs visible" id="general">
7
- <h3><?php _e('General Settings', $this->text_domain); ?></h3>
8
- <form method="post" action="options.php">
9
- <?php settings_fields( 'ead-settings-group' ); ?>
10
- <table class="form-table">
11
- <tr valign="top">
12
- <th scope="row"><?php _e('Default Size', $this->text_domain); ?></th>
13
- <td>
14
- <div class="f-left ead-frame-width"><?php _e('Width', $this->text_domain); ?>
15
- <input type="text" class="small" name="ead_width" value="<?php echo esc_attr( get_option('ead_width','100%') ); ?>" />
16
- </div>
17
- <div class="f-left ead-frame-height">
18
- <?php _e('Height', $this->text_domain); ?>
19
- <input type="text" class="small" name="ead_height" value="<?php echo esc_attr( get_option('ead_height','100%') ); ?>" />
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
20
  </div>
21
- <div class="clear"></div>
22
- <span class="note"><?php _e('Enter values in pixels or percentage (Example: 500px or 100%)', $this->text_domain); ?></span>
23
- </td>
24
- </tr>
25
- <tr valign="top">
26
- <th scope="row"><?php _e('Show Download Link',$this->text_domain);?></th>
27
- <td>
28
- <?php
29
- $downoptions= array('alluser' => __('For all users',$this->text_domain),'logged' => __('For Logged-in users',$this->text_domain),'none' => __('No Download',$this->text_domain));
30
- $this->selectbuilder('ead_download', $downoptions,esc_attr( get_option('ead_download','none')));
31
- ?>
32
- </td>
33
- </tr>
34
- <tr valign="top">
35
- <th scope="row"><?php _e('Download Text',$this->text_domain);?></th>
36
- <td>
37
- <input type="text" class="" name="ead_text" value="<?php echo esc_attr( get_option('ead_text','Download') ); ?>" />
38
- </td>
39
- </tr>
40
- </table>
41
- <div class="ead-form-footer">
42
- <?php submit_button(); ?>
43
  </div>
44
- </form>
45
- </div><!-- #general-->
46
- <div class="ead-banner">
47
- <a href="http://goo.gl/wJTQlc" target="_blank"><img src="<?php echo $this->plugin_url;?>images/eadplus-banner.png"></a>
48
- </div>
49
- </div><!-- .ead-left-wrap -->
50
- <div class="ead-right-wrap">
51
- <div class="ead-right-inner">
52
- <a href="http://awsm.in" target="_blank" title="AWSM Innovations"><img src="http://awsm.in/innovations/ead/logo2.jpg" alt="AWSM!"></a>
53
- <ul class="awsm-social">
54
- <li><a href="https://www.facebook.com/awsminnovations" target="_blank" title="AWSM Innovations"><span class="awsm-icon awsm-icon-facebook">Facebook</span></a></li>
55
- <li><a href="https://twitter.com/awsmin" target="_blank" title="AWSM Innovations"><span class="awsm-icon awsm-icon-twitter">Twitter</span></a></li>
56
- <li><a href="https://github.com/awsmin" target="_blank" title="AWSM Innovations"><span class="awsm-icon awsm-icon-github">Github</span></a></li>
57
- <li><a href="https://www.behance.net/awsmin" target="_blank" title="AWSM Innovations"><span class="awsm-icon awsm-icon-behance">Behance</span></a></li>
58
- </ul>
59
- </div>
60
- <div class="clearfix row-col">
61
- <div class="col-2">
62
- <a href="https://wordpress.org/support/view/plugin-reviews/embed-any-document#postform" target="_blank">
63
- <img src="<?php echo $this->plugin_url;?>images/star.gif"><?php _e('Like the plugin?', $this->text_domain);?><br/><?php _e('Rate Now!', $this->text_domain);?>
64
- </a>
65
- </div>
66
- <div class="col-2">
67
- <a href="http://awsm.in/support" target="_blank">
68
- <img src="<?php echo $this->plugin_url;?>images/ticket.gif"><?php _e('Need Help?', $this->text_domain);?><br/><?php _e('Open a Ticket', $this->text_domain);?>
69
- </a>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
70
  </div>
 
71
  </div>
72
- <div class="ead-right-inner">
73
- <h3>More Links</h3>
74
- <ol>
75
- <li><a href="http://awsm.in/ead-plus-documentation/#embedding" target="_blank" title="<?php _e('How to Embed Documents?', $this->text_domain); ?>"><?php _e('How to Embed Documents?', $this->text_domain); ?></a></li>
76
- <li><a href="http://awsm.in/ead-plus-documentation/#viewers" target="_blank" title="<?php _e('About Viewers', $this->text_domain); ?>"><?php _e('About Viewers', $this->text_domain); ?></a></li>
77
- <li><a href="http://awsm.in/ead-plus-documentation/#shortcode" target="_blank" title="<?php _e('Shortcode & Attributes', $this->text_domain); ?>"><?php _e('Shortcode & Attributes', $this->text_domain); ?></a></li>
78
- <li><a href="http://awsm.in/support" target="_blank" title="<?php _e('FAQs', $this->text_domain); ?>"><?php _e('FAQs', $this->text_domain); ?></a></li>
79
- </ol>
80
- </div>
81
- </div><!-- .ead-right-wrap -->
82
- <div class="clear"></div>
83
  </div><!-- .wrap -->
1
+ <?php if ( ! defined( 'ABSPATH' ) ) {
2
+ exit;
3
+ } // Exit if accessed directly ?>
4
  <div class="wrap">
5
+ <h1 class="ead-title">Embed Any Document by AWSM.in</h1>
6
+ <div class="row clearfix">
7
+ <div class="ead-left-wrap">
8
+ <div class="ead-tabs">
9
+ <div class="tabs visible" id="general">
10
+ <h3><?php esc_html_e( 'General Settings', 'embed-any-document' ); ?></h3>
11
+ <form method="post" action="options.php">
12
+ <?php settings_fields( 'ead-settings-group' ); ?>
13
+ <table class="form-table">
14
+ <tr valign="top">
15
+ <th scope="row"><?php esc_html_e( 'Default Size', 'embed-any-document' ); ?></th>
16
+ <td>
17
+ <div class="f-left ead-frame-width"><?php esc_html_e( 'Width', 'embed-any-document' ); ?>
18
+ <input type="text" class="small" name="ead_width" value="<?php echo esc_attr( get_option( 'ead_width', '100%' ) ); ?>"/>
19
+ </div>
20
+ <div class="f-left ead-frame-height">
21
+ <?php esc_html_e( 'Height', 'embed-any-document' ); ?>
22
+ <input type="text" class="small" name="ead_height" value="<?php echo esc_attr( get_option( 'ead_height', '100%' ) ); ?>"/>
23
+ </div>
24
+ <div class="clear"></div>
25
+ <span class="note"><?php esc_html_e( 'Enter values in pixels or percentage (Example: 500px or 100%)', 'embed-any-document' ); ?></span>
26
+ </td>
27
+ </tr>
28
+ <tr valign="top">
29
+ <th scope="row"><?php esc_html_e( 'Show Download Link', 'embed-any-document' ); ?></th>
30
+ <td>
31
+ <?php
32
+ $downoptions = array( 'alluser' => __( 'For all users', 'embed-any-document' ), 'logged' => __( 'For Logged-in users', 'embed-any-document' ), 'none' => __( 'No Download', 'embed-any-document' ) );
33
+ $this->selectbuilder( 'ead_download', $downoptions, esc_attr( get_option( 'ead_download', 'none' ) ) );
34
+ ?>
35
+ </td>
36
+ </tr>
37
+ <tr valign="top">
38
+ <th scope="row"><?php esc_html_e( 'Download Text', 'embed-any-document' ); ?></th>
39
+ <td>
40
+ <input type="text" class="" name="ead_text" value="<?php echo esc_attr( get_option( 'ead_text', 'Download' ) ); ?>"/>
41
+ </td>
42
+ </tr>
43
+ </table>
44
+ <div class="ead-form-footer">
45
+ <?php submit_button(); ?>
46
  </div>
47
+ </form>
48
+ </div><!-- #general-->
49
+ </div><!-- .ead-tabs -->
50
+ <div class="ead-banner">
51
+ <a href="http://goo.gl/wJTQlc" target="_blank"><img src="<?php echo esc_url( $this->plugin_url ); ?>images/eadplus-banner.png"></a>
52
+ </div>
53
+ </div><!-- .ead-left-wrap -->
54
+ <div class="ead-right-wrap">
55
+ <div class="ead-right-widget we-are-awsm">
56
+ <div class="awsm-branding">
57
+ <img src="<?php echo $this->plugin_url;?>/images/awsm-logo.png" width="67" height="67" alt="AWSM Innovations">
58
+ <div class="left-clear">
59
+ <h2><?php esc_html_e('Designed and developed by','embed-any-document-plus');?></h2>
60
+ <h3><a href="http://awsm.in/" target="_blank" title="awsm innovations">awsm innovations</a></h3>
61
+ <ul class="awsm-social">
62
+ <li><a href="https://www.facebook.com/awsminnovations" target="_blank" title="AWSM Innovations"><span class="awsm-icon awsm-icon-facebook"><?php esc_html_e('Facebook','embed-any-document-plus');?></span></a></li>
63
+ <li><a href="https://twitter.com/awsmin" target="_blank" title="AWSM Innovations"><span class="awsm-icon awsm-icon-twitter"><?php esc_html_e('Twitter','embed-any-document-plus');?></span></a></li>
64
+ <li><a href="https://github.com/awsmin" target="_blank" title="AWSM Innovations"><span class="awsm-icon awsm-icon-github"><?php esc_html_e('Github','embed-any-document-plus');?></span></a></li>
65
+ </ul>
66
+ </div>
67
+ </div>
 
68
  </div>
69
+ <!-- .ead-right-inner -->
70
+ <div class="clearfix row-2 ead-right-widget">
71
+ <div class="col-2">
72
+ <a href="https://goo.gl/V2XQOM" target="_blank">
73
+ <img src="<?php echo $this->plugin_url;?>images/star.gif"><?php esc_html_e('Like the plugin?', 'embed-any-document-plus');?><br/><?php esc_html_e('Rate Now!', 'embed-any-document-plus');?>
74
+ </a>
75
+ </div>
76
+ <!-- .col-2 -->
77
+ <div class="col-2">
78
+ <a href="http://awsm.in/support" target="_blank">
79
+ <img src="<?php echo $this->plugin_url;?>images/ticket.gif"><?php esc_html_e('Need Help?', 'embed-any-document-plus');?><br/><?php esc_html_e('Open a Ticket', 'embed-any-document-plus');?>
80
+ </a>
81
+ </div>
82
+ <!-- .col-2 -->
83
+ </div>
84
+ <!-- .row -->
85
+ <div class="ead-right-inner">
86
+ <h3><?php esc_html_e('Quick Help', 'embed-any-document-plus');?></h3>
87
+ <ol>
88
+ <li>
89
+ <a href="http://awsm.in/ead-plus-documentation/#embedding" target="_blank" title="<?php esc_html_e('How to Embed Documents?', 'embed-any-document-plus'); ?>">
90
+ <?php esc_html_e('How to Embed Documents?', 'embed-any-document-plus'); ?>
91
+ </a>
92
+ </li>
93
+ <li>
94
+ <a href="http://awsm.in/ead-plus-documentation/#viewers" target="_blank" title="<?php esc_html_e('About Viewers', 'embed-any-document-plus'); ?>">
95
+ <?php esc_html_e('About Viewers', 'embed-any-document-plus'); ?>
96
+ </a>
97
+ </li>
98
+ <li>
99
+ <a href="http://awsm.in/ead-plus-documentation/#shortcode" target="_blank" title="<?php esc_html_e('Shortcode & Attributes', 'embed-any-document-plus'); ?>">
100
+ <?php esc_html_e('Shortcode & Attributes', 'embed-any-document-plus'); ?>
101
+ </a>
102
+ </li>
103
+ <li>
104
+ <a href="http://awsm.in/support" target="_blank" title="<?php esc_html_e('FAQs', 'embed-any-document-plus'); ?>">
105
+ <?php esc_html_e('FAQs', 'embed-any-document-plus'); ?>
106
+ </a>
107
+ </li>
108
+ </ol>
109
+ </div>
110
+ <!-- .ead-right-inner -->
111
  </div>
112
+ <!-- .ead-right-wrap -->
113
  </div>
 
 
 
 
 
 
 
 
 
 
 
114
  </div><!-- .wrap -->
js/embed.js CHANGED
@@ -49,7 +49,7 @@ jQuery(document).ready(function($) {
49
  $('.ead-options').fadeIn();
50
  });
51
  // Close embed dialog
52
- $('#embed-popup').on('click', '.cancel-embed,.mfp-close', function(e) {
53
  // Prevent default action
54
  e.preventDefault();
55
  ead_remove_pop();
49
  $('.ead-options').fadeIn();
50
  });
51
  // Close embed dialog
52
+ $('#embed-popup').on('click', '.cancel-embed,.ead-close', function(e) {
53
  // Prevent default action
54
  e.preventDefault();
55
  ead_remove_pop();
language/embed-any-document.pot CHANGED
@@ -1,7 +1,8 @@
 
1
  msgid ""
2
  msgstr ""
3
  "Project-Id-Version: Embed Any Document\n"
4
- "POT-Creation-Date: 2016-05-12 11:39+0530\n"
5
  "PO-Revision-Date: 2016-05-12 11:40+0530\n"
6
  "Last-Translator: \n"
7
  "Language-Team: Awsm Innovations <hello@awsm.in>\n"
@@ -9,190 +10,203 @@ msgstr ""
9
  "MIME-Version: 1.0\n"
10
  "Content-Type: text/plain; charset=UTF-8\n"
11
  "Content-Transfer-Encoding: 8bit\n"
12
- "X-Generator: Poedit 1.6.10\n"
13
  "X-Poedit-Basepath: .\n"
14
  "Plural-Forms: nplurals=2; plural=(n != 1);\n"
15
  "X-Poedit-SourceCharset: UTF-8\n"
16
- "X-Poedit-KeywordsList: __;_e\n"
17
  "X-Poedit-SearchPath-0: .\n"
18
  "X-Poedit-SearchPath-1: ..\n"
19
 
20
- #: ../aswm-embed.php:92 ../inc/popup.php:6
21
  msgid "Add Document"
22
  msgstr ""
23
 
24
- #: ../aswm-embed.php:116
25
  msgid "Settings"
26
  msgstr ""
27
 
28
- #: ../aswm-embed.php:137 ../aswm-embed.php:164
29
  msgid "Download"
30
  msgstr ""
31
 
32
- #: ../aswm-embed.php:143
33
  msgid "Nothing to insert"
34
  msgstr ""
35
 
36
- #: ../aswm-embed.php:144
37
  msgid "Invalid URL"
38
  msgstr ""
39
 
40
- #: ../aswm-embed.php:145 ../inc/popup.php:22
41
  msgid "Add URL"
42
  msgstr ""
43
 
44
- #: ../aswm-embed.php:146
45
  msgid "Verifying..."
46
  msgstr ""
47
 
48
- #: ../aswm-embed.php:147
49
  msgid "From URL"
50
  msgstr ""
51
 
52
- #: ../aswm-embed.php:148
53
  msgid "Select"
54
  msgstr ""
55
 
56
- #: ../aswm-embed.php:230
 
 
 
 
57
  msgid "No Url Found"
58
  msgstr ""
59
 
60
- #: ../aswm-embed.php:244
 
 
 
 
61
  msgid "You do not have sufficient permissions to access this page."
62
  msgstr ""
63
 
64
- #: ../aswm-embed.php:289
65
  msgid "Buy Pro Version"
66
  msgstr ""
67
 
68
- #: ../inc/popup.php:4
 
 
 
 
 
69
  msgid "Close"
70
  msgstr ""
71
 
72
- #: ../inc/popup.php:13
73
  msgid "Upload Document"
74
  msgstr ""
75
 
76
- #: ../inc/popup.php:14
77
  msgid "Add from URL"
78
  msgstr ""
79
 
80
- #: ../inc/popup.php:20
81
  msgid "Enter document URL"
82
  msgstr ""
83
 
84
- #: ../inc/popup.php:24
85
  msgid "back"
86
  msgstr ""
87
 
88
- #: ../inc/popup.php:37
89
  msgid "Advanced Options"
90
  msgstr ""
91
 
92
- #: ../inc/popup.php:40 ../inc/settings.php:14
93
  msgid "Width"
94
  msgstr ""
95
 
96
- #: ../inc/popup.php:41 ../inc/settings.php:18
97
  msgid "Height"
98
  msgstr ""
99
 
100
- #: ../inc/popup.php:43 ../inc/settings.php:26
101
  msgid "Show Download Link"
102
  msgstr ""
103
 
104
- #: ../inc/popup.php:45 ../inc/settings.php:29
105
  msgid "For all users"
106
  msgstr ""
107
 
108
- #: ../inc/popup.php:45 ../inc/settings.php:29
109
  msgid "For Logged-in users"
110
  msgstr ""
111
 
112
- #: ../inc/popup.php:45 ../inc/settings.php:29
113
  msgid "No Download"
114
  msgstr ""
115
 
116
- #: ../inc/popup.php:50 ../inc/settings.php:35
117
  msgid "Download Text"
118
  msgstr ""
119
 
120
- #: ../inc/popup.php:54 ../inc/popup.php:61
121
  msgid "Viewer"
122
  msgstr ""
123
 
124
- #: ../inc/popup.php:56
125
  msgid "Google Docs Viewer"
126
  msgstr ""
127
 
128
- #: ../inc/popup.php:56
129
  msgid "Microsoft Office Online"
130
  msgstr ""
131
 
132
- #: ../inc/popup.php:63
133
  msgid "Box"
134
  msgstr ""
135
 
136
- #: ../inc/popup.php:64
137
  msgid "Drive"
138
  msgstr ""
139
 
140
- #: ../inc/popup.php:71
141
  msgid "Shortcode Preview"
142
  msgstr ""
143
 
144
- #: ../inc/popup.php:80
145
  msgid "Insert"
146
  msgstr ""
147
 
148
- #: ../inc/popup.php:80
149
  msgid "Loading..."
150
  msgstr ""
151
 
152
- #: ../inc/popup.php:84
153
  msgid "Cancel"
154
  msgstr ""
155
 
156
- #: ../inc/settings.php:7
157
  msgid "General Settings"
158
  msgstr ""
159
 
160
- #: ../inc/settings.php:12
161
  msgid "Default Size"
162
  msgstr ""
163
 
164
- #: ../inc/settings.php:22
165
  msgid "Enter values in pixels or percentage (Example: 500px or 100%)"
166
  msgstr ""
167
 
168
- #: ../inc/settings.php:63
169
  msgid "Like the plugin?"
170
  msgstr ""
171
 
172
- #: ../inc/settings.php:63
173
  msgid "Rate Now!"
174
  msgstr ""
175
 
176
- #: ../inc/settings.php:68
177
  msgid "Need Help?"
178
  msgstr ""
179
 
180
- #: ../inc/settings.php:68
181
  msgid "Open a Ticket"
182
  msgstr ""
183
 
184
- #: ../inc/settings.php:75
185
  msgid "How to Embed Documents?"
186
  msgstr ""
187
 
188
- #: ../inc/settings.php:76
189
  msgid "About Viewers"
190
  msgstr ""
191
 
192
- #: ../inc/settings.php:77
193
  msgid "Shortcode & Attributes"
194
  msgstr ""
195
 
196
- #: ../inc/settings.php:78
197
  msgid "FAQs"
198
  msgstr ""
1
+ #, fuzzy
2
  msgid ""
3
  msgstr ""
4
  "Project-Id-Version: Embed Any Document\n"
5
+ "POT-Creation-Date: 2017-05-03 15:45+0530\n"
6
  "PO-Revision-Date: 2016-05-12 11:40+0530\n"
7
  "Last-Translator: \n"
8
  "Language-Team: Awsm Innovations <hello@awsm.in>\n"
10
  "MIME-Version: 1.0\n"
11
  "Content-Type: text/plain; charset=UTF-8\n"
12
  "Content-Transfer-Encoding: 8bit\n"
13
+ "X-Generator: Poedit 1.8.8\n"
14
  "X-Poedit-Basepath: .\n"
15
  "Plural-Forms: nplurals=2; plural=(n != 1);\n"
16
  "X-Poedit-SourceCharset: UTF-8\n"
17
+ "X-Poedit-KeywordsList: __;_e;esc_html__;esc_html_e\n"
18
  "X-Poedit-SearchPath-0: .\n"
19
  "X-Poedit-SearchPath-1: ..\n"
20
 
21
+ #: ../awsm-embed.php:98 ../inc/popup.php:8
22
  msgid "Add Document"
23
  msgstr ""
24
 
25
+ #: ../awsm-embed.php:125
26
  msgid "Settings"
27
  msgstr ""
28
 
29
+ #: ../awsm-embed.php:153 ../awsm-embed.php:180
30
  msgid "Download"
31
  msgstr ""
32
 
33
+ #: ../awsm-embed.php:159
34
  msgid "Nothing to insert"
35
  msgstr ""
36
 
37
+ #: ../awsm-embed.php:160
38
  msgid "Invalid URL"
39
  msgstr ""
40
 
41
+ #: ../awsm-embed.php:161 ../inc/popup.php:28
42
  msgid "Add URL"
43
  msgstr ""
44
 
45
+ #: ../awsm-embed.php:162
46
  msgid "Verifying..."
47
  msgstr ""
48
 
49
+ #: ../awsm-embed.php:163
50
  msgid "From URL"
51
  msgstr ""
52
 
53
+ #: ../awsm-embed.php:164
54
  msgid "Select"
55
  msgstr ""
56
 
57
+ #: ../awsm-embed.php:254
58
+ msgid "Embedded Document"
59
+ msgstr ""
60
+
61
+ #: ../awsm-embed.php:258
62
  msgid "No Url Found"
63
  msgstr ""
64
 
65
+ #: ../awsm-embed.php:269
66
+ msgid "Embed Any Document"
67
+ msgstr ""
68
+
69
+ #: ../awsm-embed.php:277
70
  msgid "You do not have sufficient permissions to access this page."
71
  msgstr ""
72
 
73
+ #: ../awsm-embed.php:328
74
  msgid "Buy Pro Version"
75
  msgstr ""
76
 
77
+ #: ../awsm-embed.php:330
78
+ #, php-format
79
+ msgid "Add From %1$s"
80
+ msgstr ""
81
+
82
+ #: ../inc/popup.php:6
83
  msgid "Close"
84
  msgstr ""
85
 
86
+ #: ../inc/popup.php:16
87
  msgid "Upload Document"
88
  msgstr ""
89
 
90
+ #: ../inc/popup.php:19
91
  msgid "Add from URL"
92
  msgstr ""
93
 
94
+ #: ../inc/popup.php:26
95
  msgid "Enter document URL"
96
  msgstr ""
97
 
98
+ #: ../inc/popup.php:30
99
  msgid "back"
100
  msgstr ""
101
 
102
+ #: ../inc/popup.php:43
103
  msgid "Advanced Options"
104
  msgstr ""
105
 
106
+ #: ../inc/popup.php:46 ../inc/settings.php:16
107
  msgid "Width"
108
  msgstr ""
109
 
110
+ #: ../inc/popup.php:49 ../inc/settings.php:20
111
  msgid "Height"
112
  msgstr ""
113
 
114
+ #: ../inc/popup.php:53 ../inc/settings.php:28
115
  msgid "Show Download Link"
116
  msgstr ""
117
 
118
+ #: ../inc/popup.php:55 ../inc/settings.php:31
119
  msgid "For all users"
120
  msgstr ""
121
 
122
+ #: ../inc/popup.php:55 ../inc/settings.php:31
123
  msgid "For Logged-in users"
124
  msgstr ""
125
 
126
+ #: ../inc/popup.php:55 ../inc/settings.php:31
127
  msgid "No Download"
128
  msgstr ""
129
 
130
+ #: ../inc/popup.php:60 ../inc/settings.php:37
131
  msgid "Download Text"
132
  msgstr ""
133
 
134
+ #: ../inc/popup.php:64 ../inc/popup.php:71
135
  msgid "Viewer"
136
  msgstr ""
137
 
138
+ #: ../inc/popup.php:66
139
  msgid "Google Docs Viewer"
140
  msgstr ""
141
 
142
+ #: ../inc/popup.php:66
143
  msgid "Microsoft Office Online"
144
  msgstr ""
145
 
146
+ #: ../inc/popup.php:73
147
  msgid "Box"
148
  msgstr ""
149
 
150
+ #: ../inc/popup.php:74
151
  msgid "Drive"
152
  msgstr ""
153
 
154
+ #: ../inc/popup.php:81
155
  msgid "Shortcode Preview"
156
  msgstr ""
157
 
158
+ #: ../inc/popup.php:90
159
  msgid "Insert"
160
  msgstr ""
161
 
162
+ #: ../inc/popup.php:90
163
  msgid "Loading..."
164
  msgstr ""
165
 
166
+ #: ../inc/popup.php:94
167
  msgid "Cancel"
168
  msgstr ""
169
 
170
+ #: ../inc/settings.php:9
171
  msgid "General Settings"
172
  msgstr ""
173
 
174
+ #: ../inc/settings.php:14
175
  msgid "Default Size"
176
  msgstr ""
177
 
178
+ #: ../inc/settings.php:24
179
  msgid "Enter values in pixels or percentage (Example: 500px or 100%)"
180
  msgstr ""
181
 
182
+ #: ../inc/settings.php:73
183
  msgid "Like the plugin?"
184
  msgstr ""
185
 
186
+ #: ../inc/settings.php:74
187
  msgid "Rate Now!"
188
  msgstr ""
189
 
190
+ #: ../inc/settings.php:79
191
  msgid "Need Help?"
192
  msgstr ""
193
 
194
+ #: ../inc/settings.php:80
195
  msgid "Open a Ticket"
196
  msgstr ""
197
 
198
+ #: ../inc/settings.php:88
199
  msgid "How to Embed Documents?"
200
  msgstr ""
201
 
202
+ #: ../inc/settings.php:91
203
  msgid "About Viewers"
204
  msgstr ""
205
 
206
+ #: ../inc/settings.php:94
207
  msgid "Shortcode & Attributes"
208
  msgstr ""
209
 
210
+ #: ../inc/settings.php:97
211
  msgid "FAQs"
212
  msgstr ""
readme.txt CHANGED
@@ -81,6 +81,14 @@ Great. Send it to ead@awsm.in. We will answer it as soon as we can.
81
 
82
  == Changelog ==
83
 
 
 
 
 
 
 
 
 
84
  = V 2.2.5 - 2016-05-12 =
85
  * Minor bug fixes and enhancements
86
 
@@ -133,6 +141,14 @@ Great. Send it to ead@awsm.in. We will answer it as soon as we can.
133
 
134
  == Upgrade Notice ==
135
 
 
 
 
 
 
 
 
 
136
  = V 2.2.5 - 2016-05-12 =
137
  * Minor bug fixes and enhancements
138
 
81
 
82
  == Changelog ==
83
 
84
+ = V 2.3 - 2017-05-12 =
85
+ * UI improvements
86
+ * Added title for the embed iframe
87
+ * Other minor bug fixes
88
+
89
+ = V 2.2.5 - 2017-05-03 =
90
+ * Minor bug fixes and enhancements
91
+
92
  = V 2.2.5 - 2016-05-12 =
93
  * Minor bug fixes and enhancements
94
 
141
 
142
  == Upgrade Notice ==
143
 
144
+ = V 2.3 - 2017-05-12 =
145
+ * UI improvements
146
+ * Added title for the embed iframe
147
+ * Other minor bug fixes
148
+
149
+ = V 2.2.5 - 2017-05-03 =
150
+ * Minor bug fixes and enhancements
151
+
152
  = V 2.2.5 - 2016-05-12 =
153
  * Minor bug fixes and enhancements
154