options = get_option( 'sitelinx' ); if(!isset($this->options['accessibility_enable'])) { if(!isset($this->options['hide_toolbar_mobile'])) { if( !wp_is_mobile() ) { add_action('wp_footer', array($this, 'toolbar_btn')); add_action('wp_footer', array($this, 'black_screen')); add_action('wp_footer', array($this, 'the_toolbar')); } } else { add_action('wp_footer', array($this, 'toolbar_btn')); add_action('wp_footer', array($this, 'black_screen')); add_action('wp_footer', array($this, 'the_toolbar')); } } } public function toolbar_btn() { $icon_size = (isset($this->options['icon_size'])) ? $this->options['icon_size'] : 'normal'; $toolbar_side = isset($this->options['toolbar_side']) ? $this->options['toolbar_side'] : 'right'; $image_icon = (isset($this->options['replacetoggle_icon'])) ? true : false; //check if it not buttom. if( $toolbar_side == "lower-left" || $toolbar_side == "lower-right" ){ $toolbar_position = !empty($this->options['toolbar_position']) ? $this->options['toolbar_position'] : 1; }else{ $toolbar_position = !empty($this->options['toolbar_position']) ? $this->options['toolbar_position'] : 200; } $toolbar_position_side = !empty($this->options['toolbar_position_side']) ? $this->options['toolbar_position_side'] : 1; if( isset( $this->options['toolbar_icon_height'] ) && $this->options['toolbar_icon_height'] != "" ){ $icon_height = $this->options['toolbar_icon_height']; }else{ $icon_height = "34"; } if( isset( $this->options['toolbar_icon_width'] ) && $this->options['toolbar_icon_width'] != "" ){ $icon_width = $this->options['toolbar_icon_width']; }else{ $icon_width = "34"; } //$icon_shape = (!empty($this->options['icon_shape'] == 'circle')) ? '50%' : '2px'; if( isset( $this->options['icon_shape'] ) ){ $icon_shape_check = $this->options['icon_shape']; } else{ $icon_shape_check = array(); } $icon_shape = ( !empty( $icon_shape_check == 'circle' ) ) ? '50%' : '2px'; $style_side = $toolbar_side . ': ' . $toolbar_position_side . 'px;'; // $img_size = isset( $this->options['img_size'] ) ? $this->options['img_size'] : ''; // switch( $img_size ){ // case "1": // $default_icon = ACL_SITELINX_URL . 'assets/img/wheelchair24.png'; // break; // case "2": // $default_icon = ACL_SITELINX_URL . 'assets/img/wheelchair.png'; // break; // case "3": // $default_icon = ACL_SITELINX_URL . 'assets/img/wheelchair64.png'; // break; // default: // $default_icon = ACL_SITELINX_URL . 'assets/img/wheelchair.png'; // } $default_icon = ACL_SITELINX_URL . 'assets/img/wheelchair.png'; $external_link = (!empty($this->options['toolbar_icon'])) ? $this->options['toolbar_icon'] : $default_icon; if (@getimagesize($external_link)) { $toolbar_icon = $external_link; } else { //$img_t_size = isset( $this->options['img_size'] ) ? $this->options['img_size'] : ''; // switch( $img_t_size ){ // case "1": // $toolbar_icon = ACL_SITELINX_URL . 'assets/img/wheelchair24.png'; // break; // case "2": // $toolbar_icon = ACL_SITELINX_URL . 'assets/img/wheelchair.png'; // break; // case "3": // $toolbar_icon = ACL_SITELINX_URL . 'assets/img/wheelchair64.png'; // break; // default: // $toolbar_icon = ACL_SITELINX_URL . 'assets/img/wheelchair.png'; // } $toolbar_icon = ACL_SITELINX_URL . 'assets/img/wheelchair.png'; } $color_icon = (isset($this->options['color_icon'])) ? $this->options['color_icon'] : '#0a76be'; if( $toolbar_side == "lower-left" || $toolbar_side == "lower-right" ){ if( $toolbar_side == "lower-left" ){ $toolbar_side = "left"; $style_side = $toolbar_side . ': ' . $toolbar_position_side . 'px;'; } if( $toolbar_side == "lower-right" ){ $toolbar_side = "right"; $style_side = $toolbar_side . ': ' . $toolbar_position_side . 'px;'; } $output = ''; echo $output; } public function black_screen() { if( !isset($this->options['disable_blackscreen']) ) echo '
'; } public function the_toolbar() { $toolbar_position = (isset($this->options['toolbar_position'])) ? $this->options['toolbar_position'] : 25; $skin = (isset($this->options['toolbar_skin'])) ? $this->options['toolbar_skin'] : 1; ?> options['toolbar_side']; // if( $toolbar_side == ){ // } $toolbar_side = (isset($this->options['toolbar_side'])) ? $this->options['toolbar_side'] : ""; if( $toolbar_side == "lower-left" || $toolbar_side == "lower-right" ){ if( $toolbar_side == "lower-left" ){ $side = "left"; } if( $toolbar_side == "lower-right" ){ $side = "right"; } ?> options['focus'] ) ? $this->options['focus'] : ''; $focus = ( $get_focus === 'toolbar') ? true : false; $disable_flashes = isset($this->options['hide_flashes']); $disable_hemarks = isset($this->options['hide_headingmarks']); $disable_background = isset($this->options['hide_background']); $output = ''; if( !$disable_flashes || $focus || !$disable_hemarks ) { $output .= '
  • '; // $output .= '

    ' . __('General', 'accessibility-light') . '

    '; $output .= ''; $output .= '
  • '; } return $output; } public function section_resolution() { $output = '
  • '; // $output .= '

    ' . __('Resolution', 'accessibility-light') . '

    '; $output .= ''; $output .= '
  • '; return $output; } public function section_font() { $output = '
  • '; // $output .= '

    ' . __('Fonts', 'accessibility-light') . '

    '; if(!isset($this->options['disable_fontzoom'])) { $output .= ''; } if(!isset($this->options['hide_readable'])) { $output .= ''; } $output .= '
  • '; return $output; } public function section_contrast() { $output = '
  • '; // $output .= '

    ' . __('Color Contrast', 'accessibility-light') . '

    '; $output .= ''; $output .= '
  • '; return $output; } public function section_links() { $get_ul = isset( $this->options['link_underline'] ) ? $this->options['link_underline'] : ''; $ul_classes = ( $get_ul != 'all') ? 'ul-2-items' : ''; $output = '
  • '; // $output .= ''; $output .= ''; $output .= '
  • '; return $output; } public function section_additional() { $statement = (isset($this->options['sitelinx_statement'])) ? $this->options['sitelinx_statement'] : ''; $feedback = (isset($this->options['sitelinx_feedback'])) ? $this->options['sitelinx_feedback'] : ''; $this->section_general(); $output = '
  • '; // $output .= '

    ' . __('Additional Options', 'accessibility-light') . '

    '; $output .= ''; $output .= '
  • '; return $output; } } ?>