diff -r cf61fcea0001 -r c7c34916027a wp/wp-content/themes/themeforest-2964855-scrn-responsive-single-page-portfolio/SCRN/includes/shortcodes.php --- a/wp/wp-content/themes/themeforest-2964855-scrn-responsive-single-page-portfolio/SCRN/includes/shortcodes.php Mon Oct 14 17:39:30 2019 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,1993 +0,0 @@ -


    1. ")); - -} - -add_shortcode('feedburner','vp_feedburner'); - -function vp_feedburner($atts, $content = null){ - - extract(shortcode_atts(array( - - "name" => '' - - ), $atts)); - - if($name !== '') - - { - - $output = '

      '; - - $output .= " - - - - "; - - $output .= '
      '; - - } - - else $output = ''; - - return $output; - -} - -add_shortcode('twitter','vp_twitter'); - -function vp_twitter($atts, $content = null){ - - extract(shortcode_atts(array( - - "variation" => 1, - - "username" => '' - - ), $atts)); - - if($username !== '') - - { - - $output = '
      '; - - switch($variation) { - - case 1: - - $output .= 'twitter'; - - break; - - case 2: - - $output .= 'twitter'; - - break; - - case 3: - - $output .= 'twitter'; - - break; - - } - - $output .= '
      '; - - } - - else $output = ''; - - return $output; - -} - -add_shortcode('digg','vp_digg'); - -function vp_digg($atts, $content = null){ - - extract(shortcode_atts(array( - - "variation" => 1 - - ), $atts)); - - $output = ''; - - $output .= '
      '; - - switch($variation) { - - case 1: - - $output .= ''; - - break; - - case 2: - - $output .= ''; - - break; - - case 3: - - $output .= ''; - - break; - - case 4: - - $output .= ''; - - break; - - } - - $output .= '
      '; - - return $output; - -} - - - -add_shortcode('facebook','vp_facebook'); - -function vp_facebook($atts, $content = null) { - - $output = '
      '; - - $output .= ' - - '; - - $output .= '
      '; - - return $output; - -} - - - -add_shortcode('stumble','vp_stumble'); - -function vp_stumble($atts, $content = null) { - - extract(shortcode_atts(array( - - "variation" => 5 - - ), $atts)); - - $output = '
      '; - - $output .= ' - - - -'; - - $output .= '
      '; - - return $output; - -} - - - -add_shortcode('retweet','vp_retweet'); - -function vp_retweet($atts, $content = null) { - - $output = '
      '; - - $output .= ""; - - $output .= '
      '; - - return $output; - -} - - - -add_shortcode('pinterest','vp_pinterest'); - -function vp_pinterest($atts, $content = null){ - - extract(shortcode_atts(array( - - "variation" => 1, - - "username" => '' - - ), $atts)); - - if($username !== '') - - { - - $output = '
      '; - - switch($variation) { - - case 1: - - $output .= 'Follow Me on Pinterest'; - - break; - - case 2: - - $output .= 'Follow Me on Pinterest'; - - break; - - case 3: - - $output .= 'Follow Me on Pinterest'; - - break; - - case 4: - - $output .= 'Follow Me on Pinterest'; - - break; - - } - - $output .= '
      '; - - } - - else $output = ''; - - return $output; - -} - - - -add_shortcode('addthis','vp_addthis'); - -function vp_addthis($atts, $content = null){ - - extract(shortcode_atts(array( - - "variation" => 1, - - ), $atts)); - - - - $output = '
      '; - - switch($variation) { - - case 1: - - $output .= '
      - - - - - - - - - -
      '; - - break; - - case 2: - - $output .= '
      - - - - - - - - - - - - - -
      '; - - break; - - case 3: - - $output .= '
      - - - - - - - - - - - - - -
      '; - - break; - - case 4: - - $output .= '
      - - - - - - - - - -
      '; - - break; - - } - - $output .= ''; - - $output .= '
      '; - - return $output; - -} - -add_shortcode('one_third','vp_one_third'); - -function vp_one_third($atts, $content = null){ - - extract(shortcode_atts(array( - - 'noleft' => '', - - 'noright' => '' - - ), $atts)); - - $content = filter_shortcode($content); - - $class = ''; - - if($noleft !== '') - - $class .= 'alpha '; - - if($noright !== '') - - $class .= 'omega'; - - $output = ''; - - return $output; - -} - -add_shortcode('one_half','vp_one_half'); - -function vp_one_half($atts, $content = null){ - - extract(shortcode_atts(array( - - 'noleft' => '', - - 'noright' => '' - - ), $atts)); - - $content = filter_shortcode($content); - - $class = ''; - - if($noleft !== '') - - $class .= 'alpha '; - - if($noright !== '') - - $class .= 'omega'; - - $output = '
      ' . $content . '
      '; - - return $output; - -} - - - -add_shortcode('two_thirds','vp_two_thirds'); - -function vp_two_thirds($atts, $content = null){ - - extract(shortcode_atts(array( - - 'noleft' => '', - - 'noright' => '' - - ), $atts)); - - $content = filter_shortcode($content); - - $class = ''; - - if($noleft !== '') - - $class .= 'alpha '; - - if($noright !== '') - - $class .= 'omega'; - - $output = '
      ' . $content . '
      '; - - return $output; - -} - - - -add_shortcode('one_fourth','vp_one_fourth'); - -function vp_one_fourth($atts, $content = null){ - - extract(shortcode_atts(array( - - 'icon' => '', - - 'noleft' => '', - - 'noright' => '' - - ), $atts)); - - $content = filter_shortcode($content); - - $class = ''; - - if($noleft !== '') - - $class .= 'alpha '; - - if($noright !== '') - - $class .= 'omega'; - - $output = '
      '; - - if($icon !== '') - - $output .= ''; - - $output .= $content; - - $output .= '
      '; - - return $output; - -} - -add_shortcode('one_column','vp_one_column'); - -function vp_one_column($atts, $content = null){ - - extract(shortcode_atts(array( - - 'noleft' => '', - - 'noright' => '' - - ), $atts)); - - $content = filter_shortcode($content); - - $class = ''; - - if($noleft !== '') - - $class .= 'alpha '; - - if($noright !== '') - - $class .= 'omega'; - - $output = '
      ' . $content . '
      '; - - return $output; - -} - -add_shortcode('two_columns','vp_two_columns'); - -function vp_two_columns($atts, $content = null){ - - extract(shortcode_atts(array( - - 'noleft' => '', - - 'noright' => '' - - ), $atts)); - - $content = filter_shortcode($content); - - $class = ''; - - if($noleft !== '') - - $class .= 'alpha '; - - if($noright !== '') - - $class .= 'omega'; - - $output = '
      ' . $content . '
      '; - - return $output; - -} - -add_shortcode('three_columns','vp_three_columns'); - -function vp_three_columns($atts, $content = null){ - - extract(shortcode_atts(array( - - 'noleft' => '', - - 'noright' => '' - - ), $atts)); - - $content = filter_shortcode($content); - - $class = ''; - - if($noleft !== '') - - $class .= 'alpha '; - - if($noright !== '') - - $class .= 'omega'; - - $output = '
      ' . $content . '
      '; - - return $output; - -} - -add_shortcode('five_columns','vp_five_columns'); - -function vp_five_columns($atts, $content = null){ - - extract(shortcode_atts(array( - - 'noleft' => '', - - 'noright' => '' - - ), $atts)); - - $content = filter_shortcode($content); - - $class = ''; - - if($noleft !== '') - - $class .= 'alpha '; - - if($noright !== '') - - $class .= 'omega'; - - $output = '
      ' . $content . '
      '; - - return $output; - -} - -add_shortcode('six_columns','vp_six_columns'); - -function vp_six_columns($atts, $content = null){ - - extract(shortcode_atts(array( - - 'noleft' => '', - - 'noright' => '' - - ), $atts)); - - $content = filter_shortcode($content); - - $class = ''; - - if($noleft !== '') - - $class .= 'alpha '; - - if($noright !== '') - - $class .= 'omega'; - - $output = '
      ' . $content . '
      '; - - return $output; - -} - -add_shortcode('seven_columns','vp_seven_columns'); - -function vp_seven_columns($atts, $content = null){ - - extract(shortcode_atts(array( - - 'noleft' => '', - - 'noright' => '' - - ), $atts)); - - $content = filter_shortcode($content); - - $class = ''; - - if($noleft !== '') - - $class .= 'alpha '; - - if($noright !== '') - - $class .= 'omega'; - - $output = '
      ' . $content . '
      '; - - return $output; - -} - -add_shortcode('nine_columns','vp_nine_columns'); - -function vp_nine_columns($atts, $content = null){ - - extract(shortcode_atts(array( - - 'noleft' => '', - - 'noright' => '' - - ), $atts)); - - $content = filter_shortcode($content); - - $class = ''; - - if($noleft !== '') - - $class .= 'alpha '; - - if($noright !== '') - - $class .= 'omega'; - - $output = '
      ' . $content . '
      '; - - return $output; - -} - -add_shortcode('ten_columns','vp_ten_columns'); - -function vp_ten_columns($atts, $content = null){ - - extract(shortcode_atts(array( - - 'noleft' => '', - - 'noright' => '' - - ), $atts)); - - $content = filter_shortcode($content); - - $output = '
      ' . $content . '
      '; - - return $output; - -} - -add_shortcode('eleven_columns','vp_eleven_columns'); - -function vp_eleven_columns($atts, $content = null){ - - extract(shortcode_atts(array( - - 'noleft' => '', - - 'noright' => '' - - ), $atts)); - - $content = filter_shortcode($content); - - $class = ''; - - if($noleft !== '') - - $class .= 'alpha '; - - if($noright !== '') - - $class .= 'omega'; - - $output = '
      ' . $content . '
      '; - - return $output; - -} - -add_shortcode('twelve_columns','vp_twelve_columns'); - -function vp_twelve_columns($atts, $content = null){ - - extract(shortcode_atts(array( - - 'noleft' => '', - - 'noright' => '' - - ), $atts)); - - $content = filter_shortcode($content); - - $class = ''; - - if($noleft !== '') - - $class .= 'alpha '; - - if($noright !== '') - - $class .= 'omega'; - - $output = '
      ' . $content . '
      '; - - return $output; - -} - -add_shortcode('thirteen_columns','vp_thirteen_columns'); - -function vp_thirteen_columns($atts, $content = null){ - - extract(shortcode_atts(array( - - 'noleft' => '', - - 'noright' => '' - - ), $atts)); - - $content = filter_shortcode($content); - - $class = ''; - - if($noleft !== '') - - $class .= 'alpha '; - - if($noright !== '') - - $class .= 'omega'; - - $output = '
      ' . $content . '
      '; - - return $output; - -} - -add_shortcode('fourteen_columns','vp_fourteen_columns'); - -function vp_fourteen_columns($atts, $content = null){ - - extract(shortcode_atts(array( - - 'noleft' => '', - - 'noright' => '' - - ), $atts)); - - $content = filter_shortcode($content); - - $class = ''; - - if($noleft !== '') - - $class .= 'alpha '; - - if($noright !== '') - - $class .= 'omega'; - - $output = '
      ' . $content . '
      '; - - return $output; - -} - -add_shortcode('fifteen_columns','vp_fifteen_columns'); - -function vp_fifteen_columns($atts, $content = null){ - - extract(shortcode_atts(array( - - 'noleft' => '', - - 'noright' => '' - - ), $atts)); - - $content = filter_shortcode($content); - - $class = ''; - - if($noleft !== '') - - $class .= 'alpha '; - - if($noright !== '') - - $class .= 'omega'; - - $output = '
      ' . $content . '
      '; - - return $output; - -} - -add_shortcode('full','vp_full'); - -function vp_full($atts, $content = null){ - - $content = filter_shortcode($content); - - $output = '
      ' . $content . '
      '; - - return $output; - -} - -add_shortcode('subtext','vp_subtext'); - -function vp_subtext($atts, $content = null){ - - $content = filter_shortcode($content); - - $output = '

      ' . $content . '

      '; - - return $output; - -} - -add_shortcode('skills','vp_skills'); - -function vp_skills($atts, $content = null){ - - $content = filter_shortcode($content); - - return '
      ' . $content . '
      '; - -} - -add_shortcode('skill','vp_skill'); - -function vp_skill($atts, $content = null){ - - extract(shortcode_atts(array( - - 'value' => '50', - - 'bg' => '' - - ), $atts)); - - $content = filter_shortcode($content); - - $value = (int)$value; - - $rand = rand(1,5); //uses some random backgrounds, just to make them different in case the use doesn't set any - - $output = '

      ' . $content . '

      '; - - $output .= '
      '; - - return $output; - -} - -add_shortcode('lightbox', 'vp_lightbox'); - -function vp_lightbox($atts, $content = null) { - - extract(shortcode_atts(array( - - 'alt' => 0, - - 'title' => 0, - - 'thumbnail' => 0, - - 'width' => 250, - - 'height' => 125, - - 'float' => 'none' - - ), $atts)); - - - - $content = filter_shortcode($content); - - - - $output = '
      '; - - $output .= '
      ' . PHP_EOL; - - if($content != '') - - { - - if($title !== 0) - - $title = ' title="' . $title . '"'; - - else - - $title = ''; - - if($alt !== 0) - - $alt = ' alt="' . $alt . '"'; - - else - - $alt = ''; - - //the shortcode should return something only if the user sends an image - - $output .= '' . PHP_EOL; - - if($thumbnail === 0) - - { - - $thumbnail = $content; - - } - - //if the user sends out a thumbnail img, we use that one. If not, we use the full width img to create a thumb. - - $output .= '' . PHP_EOL; - - $output .= 'hover background' . PHP_EOL; - - $output .= '
      - -
      ' . PHP_EOL; - - } - - else - - $output = ''; - - return $output; - -} - - - -add_shortcode('quote_slider', 'vp_quote_slider'); - -function vp_quote_slider($atts, $content=null) { - - $content = filter_shortcode($content); - - $id = rand(1, 25000); - - $output = '
      - -
      - - « left - -
      - -
      - - right » - -
      - -
      ' . PHP_EOL; - - $output .= $content; - - $output .= '
      - -
      ' . PHP_EOL; - - $output .= "" . PHP_EOL; - - return $output; - -} - -add_shortcode('quote', 'vp_quote'); - -function vp_quote($atts, $content=null) { - - extract(shortcode_atts(array( - - 'author' => '' - - ), $atts)); - - - - $content = filter_shortcode($content); - - $output = '
      - -

      “' . $content . '”

      - -

      ' . $author . '

      - -
      ' . PHP_EOL; - - return $output; - -} - - - -add_shortcode('slider', 'vp_slider'); - -function vp_slider($atts, $content=null) { - - $id = rand(0, 25000); - - $content = filter_shortcode($content); - - $output = '
      '; - - $output .= '
        '; - - $output .= $content; - - $output .= '
      '; - - $output .= ' - - '; - - return $output; - -} - - - -add_shortcode('slider_img', 'vp_slider_img'); - -function vp_slider_img($atts, $content=null) { - - extract(shortcode_atts(array( - - 'alt' => '' - - ), $atts)); - - $content = filter_shortcode($content); - - if($content != '') - - { - - $output = '
    2. ' . $alt . '
    3. ' . PHP_EOL; - - return $output; - - } - - else return ''; - -} - - - -add_shortcode('portfolio', 'vp_portfolio'); - -function vp_portfolio($atts, $content=null) { - - $content = filter_shortcode($content); - - $output = '
      ' . PHP_EOL; - - $output .= $content; - - $output .= '
      '; - - return $output; - -} - - - -add_shortcode('portfolio_item', 'vp_portfolio_item'); - -function vp_portfolio_item($atts, $content=null) { - - extract(shortcode_atts(array( - - 'thumbnail' => '', - - 'image' => '', - - 'title' => '', - - 'text' => '', - - 'columns' => 3, - - 'centered' => 'no', - - 'alt' => '', - - ), $atts)); - - switch($columns) - - { - - case 1: - - $class = 'class="sixteen columns"'; - - break; - - case 2: - - $class = 'class="eight columns"'; - - break; - - case 3: - - $class = 'class="one-third column"'; - - break; - - case 4: - - $class = 'class="four columns"'; - - break; - - } - - if($thumbnail === '') - - $thumbnail = $image; - - if($image !== '') - - { - - if($centered == 'yes') - - $var = ' style="text-align: center" '; - - else - - $var = ''; - - $output = '
      '; - - $output .= '' . esc_attr($alt) . ''; - - $output .= '

      ' . esc_attr($title) . '

      '; - - $output .= '

      ' . esc_attr($text) . '

      '; - - $output .= '
      '; - - return $output; - - } - - else return ''; - -} - - - -add_shortcode('button', 'vp_button'); - -function vp_button($atts, $content=null) { - - extract(shortcode_atts(array( - - 'url' => '', - - 'newwindow' => 'no', - - 'color' => 'FADBA1' - - ), $atts)); - - $content = filter_shortcode($content); - - $color = esc_attr($color); - - if($newwindow == 'yes') - - $target = ' target="_blank" '; - - else - - $target = ''; - - if($content !== '') - - { - - if($color === 'FADBA1') - - { - - if($url === '') - - $output = '
      ' . $content . '
      '; - - else - - $output = '
      ' . $content . '
      '; - - } - - else - - { - - if($url === '') - - $output = '
      ' . $content . '
      '; - - else - - $output = '
      ' . $content . '
      '; - - } - - return $output; - - } - - else return ''; - -} - - - -add_shortcode('testimonial', 'vp_testimonial'); - -function vp_testimonial($atts, $content=null) { - - $content = filter_shortcode($content); - - return '
      - -

      “' . $content . '”

      - -
      '; - -} - - - - - -add_shortcode('clear', 'vp_clear'); - -function vp_clear($atts, $content=null) { - - return '
      '; - -} - -add_shortcode('center', 'vp_centered'); - -function vp_centered($atts, $content=null) { - - $content = filter_shortcode($content); - - return '
      ' . $content . '
      '; - -} - -add_shortcode('list', 'vp_list'); - -function vp_list($atts, $content=null) { - - extract(shortcode_atts(array( - - 'type' => 'bullet' - - ), $atts)); - - $content = filter_shortcode($content); - - if($type == 'bullet') - - $output = '
        '; - - elseif($type == 'check') - - $output = '
          '; - - elseif($type == 'float') - - $output = '
            '; - - else return ''; - - $output .= $content; - - $output .= '
          '; - - return $output; - -} - -add_shortcode('twitter_updates', 'vp_twitter_updates'); - -function vp_twitter_updates($atts, $content=null) { - - $output = '
          - -
          - -
          '; - - return $output; - -} - - - -add_shortcode('pricing_table','til_pricing_table'); - -function til_pricing_table($atts, $content = null){ - - extract(shortcode_atts(array( - - 'name' => '', - - 'price' => '', - - 'price_text' => '', - - 'moretext' => 'Sign up', - - 'morelink' => '', - - 'columns' => '4' - - ), $atts)); - - switch($columns) - - { - - case 1: - - $class = 'class="sixteen columns pricing"'; - - break; - - case 2: - - $class = 'class="eight columns pricing"'; - - break; - - case 3: - - $class = 'class="one-third column pricing"'; - - break; - - case 4: - - $class = 'class="four columns pricing"'; - - break; - - default: - - $class = 'class="one-third column pricing"'; - - break; - - } - - $content = filter_shortcode($content); - - $name = esc_attr($name); - - $price = esc_attr($price); - - $price_text = esc_attr($price_text); - - $moretext = esc_attr($moretext); - - $morelink = esc_url($morelink); - - $output = ''; - - $output .= '
          '; - - if($name !== '') - - $output .= '

          ' . $name . '

          '; - - if($price !== '') - - { - - $output .= '

          ' . $price; - - if ($price_text !== '') { - - $output .= '' . $price_text . ''; - - } - - $output .= '

          '; - - } - - $output .= '
            ' . $content . '
          '; - - $output .= ' - -
          '; - - return $output; - -} - -add_shortcode('feature','vp_feature'); - -function vp_feature($atts, $content = null){ - - $content = filter_shortcode($content); - - if($content != '') - - return '
        • ' . $content . '
        • '; - -} - - - -add_shortcode('facebook_small','vp_facebook_small'); - -function vp_facebook_small($atts, $content = null) { - - extract(shortcode_atts(array( - - "username" => '', - - ), $atts)); - - if($username !== '') - - $output = ''; - - else - - $output = ''; - - return $output; - -} - - - -add_shortcode('twitter_small','vp_twitter_small'); - -function vp_twitter_small($atts, $content = null) { - - extract(shortcode_atts(array( - - "username" => '', - - ), $atts)); - - if($username !== '') - - $output = ''; - - else - - $output = ''; - - return $output; - -} - - - -add_shortcode('twitter_big','vp_twitter_big'); - -function vp_twitter_big($atts, $content = null) { - - extract(shortcode_atts(array( - - "username" => '', - - ), $atts)); - - if($username !== '') - - $output = ''; - - else - - $output = ''; - - return $output; - -} - - - -add_shortcode('dribble_small','vp_dribble_small'); - -function vp_dribble_small($atts, $content = null) { - - extract(shortcode_atts(array( - - "username" => '', - - ), $atts)); - - if($username !== '') - - $output = ''; - - else - - $output = ''; - - return $output; - -} - - - -add_shortcode('vimeo_small','vp_vimeo_small'); - -function vp_vimeo_small($atts, $content = null) { - - extract(shortcode_atts(array( - - "username" => '', - - ), $atts)); - - if($username !== '') - - $output = ''; - - else - - $output = ''; - - return $output; - -} - - - -add_shortcode('flickr_small','vp_flickr_small'); - -function vp_flickr_small($atts, $content = null) { - - extract(shortcode_atts(array( - - "username" => '', - - ), $atts)); - - if($username !== '') - - $output = ''; - - else - - $output = ''; - - return $output; - -} - -add_shortcode('header','vp_header'); - -function vp_header($atts, $content = null) { - - $content = filter_shortcode($content); - - $output = '

          ' . $content . '

          '; - - return $output; - -} - -add_shortcode('subheader','vp_subheader'); - -function vp_subheader($atts, $content = null) { - - $content = filter_shortcode($content); - - $output = '

          ' . $content . '

          '; - - return $output; - -} - -add_shortcode('team','vp_team'); - -function vp_team($atts, $content = null) { - - extract(shortcode_atts(array( - - "image" => '', - - "name" => '', - - "position" => '', - - "description" => '', - - "twitter" => '', - - "facebook" => '', - - "dribble" => '', - - "skype" => '', - - "gplus" => '', - - "linkedin" => '', - - "pinterest" => '', - - "columns" => 3 - - ), $atts)); - - switch($columns) - - { - - case 1: - - $class = 'class="sixteen columns team"'; - - break; - - case 2: - - $class = 'class="eight columns team"'; - - break; - - case 3: - - $class = 'class="one-third column team"'; - - break; - - case 4: - - $class = 'class="four columns team"'; - - break; - - default: - - $class = 'class="one-third column team'; - - break; - - } - - $output = '
          '; - - if($image !== '') - - $output .= '' . esc_attr($name) . ''; - - if($name !== '') - - $output .= '

          ' . esc_attr($name) . '

          '; - - if($position !== '') - - $output .= '

          ' . esc_attr($position) . '

          '; - - if($description !== '') - - $output .= '

          ' . esc_attr($description) . '

          '; - - $output .= '
            '; - - if($twitter !== '') - - $output .= '
          • '; - - if($facebook !== '') - - $output .= '
          • '; - - if($dribble !== '') - - $output .= '
          • '; - - if($skype !== '') - - $output .= '
          • '; - - if($gplus !== '') - - $output .= '
          • '; - - if($linkedin !== '') - - $output .= '
          • '; - - if($pinterest !== '') - - $output .= '
          • '; - - $output .= '
          - -
          '; - - return $output; - -} - -add_shortcode('service','vp_service'); - -function vp_service($atts, $content = null) { - - extract(shortcode_atts(array( - - "title" => '', - - "image" => '', - - "text" => '', - - "columns" => '3' - - ), $atts)); - - switch($columns) - - { - - case 1: - - $class = 'class="sixteen columns serv-list"'; - - break; - - case 2: - - $class = 'class="eight columns serv-list"'; - - break; - - case 3: - - $class = 'class="one-third column serv-list"'; - - break; - - case 4: - - $class = 'class="four columns serv-list"'; - - break; - - default: - - $class = 'class="one-third column serv-list"'; - - break; - - } - - $text = esc_attr($text); - - $image = esc_attr($image); - - $title = esc_attr($title); - - $output = '
          '; - - if($title != '') - - $output .= '

          ' . $title . '

          '; - - if($image != '') - - $output .= ''; - - if($text != '') - - $output .= '

          ' . $text . '

          '; - - $output .= '
          '; - - return $output; - -} - -?> \ No newline at end of file