| @@ -26,9 +26,8 @@ | ||
| 26 | 26 | * @var string |
| 27 | 27 | */ |
| 28 | 28 | public $asset_path = ( true ) ? 'https://wpbookingcalendar.com/assets/' : 'http://beta/assets/'; |
| 29 | 29 | |
| 30 | - | |
| 31 | 30 | /** |
| 32 | 31 | * Constructor |
| 33 | 32 | */ |
| 34 | 33 | public function __construct() { |
| @@ -46,134 +45,12 @@ | ||
| 46 | 45 | $title = 'Welcome to Booking Calendar'; |
| 47 | 46 | } |
| 48 | 47 | } |
| 49 | 48 | |
| 50 | - private function css() { | |
| 51 | - | |
| 52 | - ?><style type="text/css"> | |
| 53 | - .feature-section.three-col, | |
| 54 | - .feature-section.two-col { | |
| 55 | - display: flex; | |
| 56 | - flex-direction: row; | |
| 57 | - justify-content: space-between; | |
| 58 | - align-items: flex-start; | |
| 59 | - } | |
| 60 | - .feature-section.two-col .col.col-1{ | |
| 61 | - width:100%; | |
| 62 | - } | |
| 63 | - .feature-section.two-col .col.col-2{ | |
| 64 | - width: 70%; | |
| 65 | - padding: 0 0 0 7%; | |
| 66 | - box-sizing: border-box; | |
| 67 | - } | |
| 68 | - @media (max-width: 782px) { | |
| 69 | - /* iPad mini and all iPhones and other Mobile Devices */ | |
| 70 | - .feature-section.three-col, | |
| 71 | - .feature-section.two-col { | |
| 72 | - display: block; | |
| 73 | - } | |
| 74 | - } | |
| 49 | + public function show_separator() { | |
| 50 | + echo '<div class="clear" style="height:1px;border-bottom:1px solid #DFDFDF;"></div>'; | |
| 51 | + } | |
| 75 | 52 | |
| 76 | - /* Welcome Page ***************************************************************/ | |
| 77 | - .wpbc-welcome-page .about-text { | |
| 78 | - margin-right:0px; | |
| 79 | - margin-bottom:0px; | |
| 80 | - min-height: 50px; | |
| 81 | - } | |
| 82 | - .wpbc-welcome-page .wpbc-section-image { | |
| 83 | - border:none; | |
| 84 | - box-shadow: 0 1px 3px #777777; | |
| 85 | - } | |
| 86 | - .wpbc-welcome-page .versions { | |
| 87 | - color: #999999; | |
| 88 | - font-size: 12px; | |
| 89 | - font-style: normal; | |
| 90 | - margin: 0; | |
| 91 | - text-align: right; | |
| 92 | - text-shadow: 0 -1px 0 #EEEEEE; | |
| 93 | - } | |
| 94 | - .wpbc-welcome-page .versions a, | |
| 95 | - .wpbc-welcome-page .versions a:hover{ | |
| 96 | - color: #999; | |
| 97 | - text-decoration:none; | |
| 98 | - } | |
| 99 | - .wpbc-welcome-page .update-nag { | |
| 100 | - border-color: #E3C58E; | |
| 101 | - border-radius: 5px; | |
| 102 | - -moz-border-radius: 5px; | |
| 103 | - -webkit-border-radius: 5px; | |
| 104 | - box-shadow: 0 1px 3px #EEEEEE; | |
| 105 | - color: #998877; | |
| 106 | - font-size: 12px; | |
| 107 | - font-weight: 600; | |
| 108 | - margin: 15px 0 0; | |
| 109 | - width:90%; | |
| 110 | - } | |
| 111 | - .wpbc-welcome-page .feature-section { | |
| 112 | - margin-top:20px; | |
| 113 | - border:none; | |
| 114 | - } | |
| 115 | - .wpbc-welcome-page .feature-section div { | |
| 116 | - line-height: 1.5em; | |
| 117 | - } | |
| 118 | - .about-wrap.wpbc-welcome-page .feature-section .last-feature { | |
| 119 | - margin-right:0; | |
| 120 | - } | |
| 121 | - .about-wrap.wpbc-welcome-page .changelog { | |
| 122 | - margin-bottom: 10px; | |
| 123 | - } | |
| 124 | - .about-wrap.wpbc-welcome-page .feature-section h4 { | |
| 125 | - font-size: 1.2em; | |
| 126 | - margin-bottom: 0.6em; | |
| 127 | - margin-left: 0; | |
| 128 | - margin-right: 0; | |
| 129 | - margin-top: 1.4em; | |
| 130 | - } | |
| 131 | - .about-wrap.wpbc-welcome-page .feature-section { | |
| 132 | - overflow-x: hidden; | |
| 133 | - overflow-y: hidden; | |
| 134 | - padding-bottom: 20px; | |
| 135 | - } | |
| 136 | - .about-wrap.wpbc-welcome-page [class$="-col"]{ | |
| 137 | - align-items: initial; | |
| 138 | - } | |
| 139 | - @media (max-width: 782px) { /* iPad mini and all iPhones and other Mobile Devices */ | |
| 140 | - .wpbc-welcome-page .feature-section.one-col > div, | |
| 141 | - .wpbc-welcome-page .feature-section.three-col > div, | |
| 142 | - .wpbc-welcome-page .feature-section.two-col > div { | |
| 143 | - border-bottom: none; | |
| 144 | - margin:0px !important; | |
| 145 | - } | |
| 146 | - .wpbc-welcome-page .feature-section img{ | |
| 147 | - /*width:98% !important;*/ | |
| 148 | - /*margin:0 1% !important;*/ | |
| 149 | - margin:0!important; | |
| 150 | - width: auto !important; | |
| 151 | - max-height: 285px; | |
| 152 | - overflow: hidden; | |
| 153 | - } | |
| 154 | - .about-wrap.wpbc-welcome-page .feature-section div.col { | |
| 155 | - display:block; | |
| 156 | - float:none; | |
| 157 | - width: 100% !important; | |
| 158 | - padding: 0; | |
| 159 | - } | |
| 160 | - } | |
| 161 | - .wpbc-welcome-page li.big_numbers::marker{ | |
| 162 | - font-size:1.2em; | |
| 163 | - font-weight: 600; | |
| 164 | - line-height: 2.1em; | |
| 165 | - } | |
| 166 | - | |
| 167 | - </style><?php | |
| 168 | - } | |
| 169 | - // SUPPORT ///////////////////////////////////////////////////////////////// | |
| 170 | - | |
| 171 | - public function show_separator() { | |
| 172 | - ?><div class="clear" style="height:1px;border-bottom:1px solid #DFDFDF;"></div><?php | |
| 173 | - } | |
| 174 | - | |
| 175 | - | |
| 176 | 53 | public function show_header( $text = '', $header_type = 'h3', $style = '' ) { |
| 177 | 54 | echo '<', esc_attr( $header_type ); |
| 178 | 55 | if ( ! empty( $style ) ) { |
| 179 | 56 | echo " style='" . esc_attr( $style ) . "'"; |
| @@ -182,9 +59,8 @@ | ||
| 182 | 59 | echo wp_kses_post( wpbc_replace_to_strong_symbols( $text ) ); |
| 183 | 60 | echo '</', esc_attr( $header_type ), '>'; |
| 184 | 61 | } |
| 185 | 62 | |
| 186 | - | |
| 187 | 63 | public function show_col_section( $sections_array = array() ) { |
| 188 | 64 | |
| 189 | 65 | $columns_num = count( $sections_array ); |
| 190 | 66 | |
| @@ -264,9 +140,8 @@ | ||
| 264 | 140 | </div> |
| 265 | 141 | <?php |
| 266 | 142 | } |
| 267 | 143 | |
| 268 | - | |
| 269 | 144 | public function get_img( $img, $img_style = '' ) { |
| 270 | 145 | |
| 271 | 146 | $is_full_link = strpos( $img, 'http' ); |
| 272 | 147 | if ( false === $is_full_link ) { |
| @@ -295,10 +170,8 @@ | ||
| 295 | 170 | |
| 296 | 171 | // Head. |
| 297 | 172 | public function admin_head() { |
| 298 | 173 | remove_submenu_page( 'index.php', 'wpbc-about' ); |
| 299 | - //remove_submenu_page( 'index.php', 'wpbc-getting-started' ); | |
| 300 | - //remove_submenu_page( 'index.php', 'wpbc-about-premium' ); | |
| 301 | 174 | } |
| 302 | 175 | |
| 303 | 176 | // Title |
| 304 | 177 | public function title_section() { |
| @@ -347,9 +220,9 @@ | ||
| 347 | 220 | } |
| 348 | 221 | |
| 349 | 222 | list( $display_version ) = explode( '-', WPDEV_BK_VERSION ); |
| 350 | 223 | ?> |
| 351 | - <div class="changelog point-releases" style="margin-top: 45px;"> | |
| 224 | + <div class="changelog point-releases" style="margin: 40px 0 50px;"> | |
| 352 | 225 | <h3><?php |
| 353 | 226 | echo( "Maintenance Release" ); ?></h3> |
| 354 | 227 | <p><strong><?php |
| 355 | 228 | echo wp_kses_post( sprintf( 'Version %s', $display_version ) ); ?></strong> <?php |
| @@ -395,134 +268,79 @@ | ||
| 395 | 268 | } |
| 396 | 269 | |
| 397 | 270 | |
| 398 | 271 | // CONTENT ///////////////////////////////////////////////////////////////// |
| 399 | - | |
| 400 | - public function content_whats_new() { | |
| 401 | 272 | |
| 402 | - //$this->css(); | |
| 403 | -if(0){ | |
| 404 | - ?> | |
| 405 | - <style type="text/css"> | |
| 406 | - .feature-section.two-col { | |
| 407 | - display: flex; | |
| 408 | - flex-direction: row; | |
| 409 | - justify-content: space-between; | |
| 410 | - align-items: flex-start; | |
| 411 | - } | |
| 412 | - .feature-section.two-col .col.col-1{ | |
| 413 | - width:100%; | |
| 414 | - } | |
| 415 | - .feature-section.two-col .col.col-2{ | |
| 416 | - width: 70%; | |
| 417 | - padding: 0 0 0 7%; | |
| 418 | - box-sizing: border-box; | |
| 419 | - } | |
| 420 | - @media (max-width: 782px) { | |
| 421 | - /* iPad mini and all iPhones and other Mobile Devices */ | |
| 422 | - .feature-section.two-col { | |
| 423 | - display: block; | |
| 273 | + public function show_go_links() { | |
| 274 | + ?> | |
| 275 | + <div style="display: flex;flex-flow: row wrap;justify-content: center;gap: 2em;margin: 3em 0 1em;"> | |
| 276 | + <a class="button button-primary" | |
| 277 | + href="<?php | |
| 278 | + echo esc_url( wpbc_get_bookings_url() . '&tab=vm_booking_listing' ); ?>" | |
| 279 | + style="font-size: 20px;padding: 0 1em;height: 44px;line-height: 40px;"><?php | |
| 280 | + esc_html_e( 'Go to Booking Admin Panel', 'booking' ); ?></a> | |
| 281 | + <?php | |
| 282 | + $wpbc_starter_pages = function_exists( 'wpbc_get_published_activation_booking_pages' ) ? wpbc_get_published_activation_booking_pages() : array(); | |
| 283 | + if ( ! empty( $wpbc_starter_pages ) ) { | |
| 284 | + foreach ( $wpbc_starter_pages as $wpbc_starter_page ) { | |
| 285 | + ?> | |
| 286 | + <a class="button button-secondary" | |
| 287 | + style="font-size: 20px;padding: 0 1em;height: 44px;line-height: 40px;" | |
| 288 | + href="<?php | |
| 289 | + echo esc_url( $wpbc_starter_page['url'] ); ?>" | |
| 290 | + ><?php | |
| 291 | + echo esc_html( $wpbc_starter_page['button_title'] ); ?></a> | |
| 292 | + <?php | |
| 424 | 293 | } |
| 425 | - } | |
| 294 | + } else { | |
| 295 | + $wp_post_booking_absolute = false; | |
| 296 | + if ( ! empty( $wp_post_booking_absolute ) ) { | |
| 297 | + ?> | |
| 298 | + <a class="button button-secondary" | |
| 299 | + style="font-size: 20px;padding: 0 1em;height: 44px;line-height: 40px;" | |
| 300 | + href="<?php | |
| 301 | + echo esc_url( $wp_post_booking_absolute ); ?>" | |
| 302 | + ><?php | |
| 303 | + esc_html_e( 'Go to page with booking form', 'booking' ); ?></a> | |
| 304 | + <?php | |
| 305 | + } | |
| 306 | + } ?> | |
| 307 | + </div> | |
| 308 | + <?php | |
| 309 | + } | |
| 426 | 310 | |
| 427 | - .wpbc-changelog-list ul { | |
| 428 | - list-style: outside; | |
| 429 | - } | |
| 430 | - .wpbc-changelog-list ul li{ | |
| 431 | - margin-bottom: 0.5em; | |
| 432 | - line-height: 1.5em; | |
| 433 | - } | |
| 434 | - .wpbc-changelog-list ul li strong{ | |
| 435 | - padding:0 5px; | |
| 436 | - } | |
| 437 | - .wpbc_expand_section_link, | |
| 438 | - a.wpbc_expand_section_link:hover, | |
| 439 | - a.wpbc_expand_section_link:focus { | |
| 440 | - color:#21759b; | |
| 441 | - cursor: pointer; | |
| 442 | - outline: 0; | |
| 443 | - border:none; | |
| 444 | - border-bottom:1px dashed #21759B; | |
| 445 | - text-decoration: none; | |
| 446 | - } | |
| 447 | - </style><?php | |
| 448 | -} | |
| 449 | - ?> | |
| 450 | - <div class="wrap about-wrap wpbc-welcome-page"> | |
| 311 | + public function content_whats_new() { | |
| 451 | 312 | |
| 452 | - <?php $this->title_section(); ?> | |
| 313 | + echo '<div class="wrap about-wrap wpbc-welcome-page">'; | |
| 453 | 314 | |
| 454 | - <table class="about-text" style="margin-bottom:-40px;height:auto;font-size:1em;width:100%;" > | |
| 455 | - <tr> | |
| 456 | - <td> | |
| 457 | - <?php list( $display_version ) = explode( '-', WPDEV_BK_VERSION ); ?> | |
| 458 | - <!--Thank you for updating to the latest version. <strong><code><?php echo esc_html( $display_version ); ?></code></strong> | |
| 459 | - <br/>Booking Calendar has become more polished, powerful and easy to use than ever before.--> | |
| 460 | - </td> | |
| 461 | - <!--td style="width:10%"> | |
| 462 | - <a href="<?php echo esc_url( admin_url( add_query_arg( array( 'page' => 'wpbc-getting-started' ), 'index.php' ) ) ); ?>" | |
| 463 | - style="float: right; height: 36px; line-height: 34px;" | |
| 464 | - class="button-primary" | |
| 465 | - > <strong>Get Started</strong> <span style="font-size: 20px;line-height: 18px;padding-left: 5px;">›››</span> | |
| 466 | - </a> | |
| 467 | - </td--> | |
| 468 | - </tr> | |
| 469 | - </table> | |
| 470 | - <?php | |
| 315 | + $this->title_section(); | |
| 471 | 316 | |
| 472 | - $this->maintence_section(); | |
| 317 | + $this->show_go_links(); | |
| 473 | 318 | |
| 474 | - $this->section_9_8_css(); | |
| 319 | + $this->maintence_section(); | |
| 475 | 320 | |
| 476 | - wpbc_welcome_section_10_10( $this ); | |
| 321 | + $this->section_9_8_css(); | |
| 477 | 322 | |
| 478 | - wpbc_welcome_section_10_9( $this ); | |
| 323 | + wpbc_welcome_section_11_8_1( $this ); | |
| 324 | + wpbc_welcome_section_11_8( $this ); | |
| 325 | + wpbc_welcome_section_11_7( $this ); | |
| 326 | + wpbc_welcome_section_11_6( $this ); | |
| 327 | + wpbc_welcome_section_11_5( $this ); | |
| 328 | + wpbc_welcome_section_11_4( $this ); | |
| 329 | + wpbc_welcome_section_11_3( $this ); | |
| 330 | + wpbc_welcome_section_11_2( $this ); | |
| 331 | + wpbc_welcome_section_11_1( $this ); | |
| 332 | + wpbc_welcome_section_11_0( $this ); | |
| 333 | + wpbc_welcome_section_10_15( $this ); | |
| 334 | + wpbc_welcome_section_10_14( $this ); | |
| 335 | + wpbc_welcome_section_10_13( $this ); | |
| 479 | 336 | |
| 480 | - wpbc_welcome_section_10_8( $this ); | |
| 337 | + $this->show_go_links(); | |
| 481 | 338 | |
| 482 | - wpbc_welcome_section_10_7( $this ); | |
| 339 | + echo '<div'; | |
| 340 | + } | |
| 483 | 341 | |
| 484 | - wpbc_welcome_section_10_6( $this ); | |
| 485 | 342 | |
| 486 | - wpbc_welcome_section_10_5( $this ); | |
| 487 | - | |
| 488 | - wpbc_welcome_section_10_4( $this ); | |
| 489 | - | |
| 490 | - wpbc_welcome_section_10_3( $this ); | |
| 491 | - | |
| 492 | - wpbc_welcome_section_10_2( $this ); | |
| 493 | - | |
| 494 | - wpbc_welcome_section_10_1( $this ); | |
| 495 | - | |
| 496 | - wpbc_welcome_section_10_0( $this ); | |
| 497 | - | |
| 498 | - wpbc_welcome_section_9_9( $this ); | |
| 499 | - | |
| 500 | - wpbc_welcome_section_9_8( $this ); | |
| 501 | - | |
| 502 | - //////////////////////////////////////////////////////////////////////////////////////////////////////////// | |
| 503 | - // Footer | |
| 504 | - //////////////////////////////////////////////////////////////////////////////////////////////////////////// | |
| 505 | - ?> | |
| 506 | - <table class="about-text" style="margin-bottom:30px;height:auto;font-size:1em;width:100%;" > | |
| 507 | - <tr> | |
| 508 | - <td> | |
| 509 | - | |
| 510 | - </td> | |
| 511 | - <!--td style="width:10%"> | |
| 512 | - <a href="<?php echo esc_url( admin_url( add_query_arg( array( 'page' => 'wpbc-getting-started' ), 'index.php' ) ) ); ?>" | |
| 513 | - style="float: right; height: 36px; line-height: 34px;" | |
| 514 | - class="button-primary" | |
| 515 | - > <strong>Get Started</strong> <span style="font-size: 20px;line-height: 18px;padding-left: 5px;">›››</span> | |
| 516 | - </a> | |
| 517 | - </td--> | |
| 518 | - </tr> | |
| 519 | - </table> | |
| 520 | - | |
| 521 | - </div><?php | |
| 522 | - } | |
| 523 | - | |
| 524 | - | |
| 525 | 343 | function expand_section_start( $section_param_arr ) { |
| 526 | 344 | |
| 527 | 345 | ?> |
| 528 | 346 | <div class="clear" style="margin-top:20px;"></div><?php |
| @@ -563,8 +381,9 @@ | ||
| 563 | 381 | } |
| 564 | 382 | |
| 565 | 383 | |
| 566 | 384 | function section_img_url( $relative_path_to_img ) { |
| 385 | + | |
| 567 | 386 | return esc_url( $this->asset_path . $relative_path_to_img ); |
| 568 | 387 | } |
| 569 | 388 | |
| 570 | 389 | |
| @@ -647,5 +466,5 @@ | ||
| 647 | 466 | <?php |
| 648 | 467 | } |
| 649 | 468 | } |
| 650 | 469 | |
| 651 | -$wpbc_welcome = new WPBC_Welcome(); | |
| 470 | +$wpbc_welcome = new WPBC_Welcome(); | |