Advertisement
Guest User

shortcode

a guest
Feb 24th, 2018
288
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 4.54 KB | None | 0 0
  1. //about me shortcode
  2. add_shortcode('about-me', 'about_me');
  3. function about_me($attr, $content = null){
  4.     $attributes = extract(  shortcode_atts(array(
  5.         'image'             => '<?php echo get_template_directory_uri(); ?>/img/logos/kazi-ramjan.jpg',
  6.         'name'              => 'Kazi Ramjan',
  7.         'tagline'           => 'Web Developer',
  8.         'nationality'       => 'Bangladeshi',
  9.         'date_of_birth'     => '21-01-1995',
  10.         'e_mail'            => 'kaziramjana@gmail.com',
  11.         'website'           => 'http://www.kazi-ramjan.com',
  12.         'phone'             => '+8801686809581',
  13.         'skype'             => '1686809581',
  14.         'about_me_content'  => 'Hello, <br> I am Kazi Ramjan, Front-End Developer with 3 years of experience rapidiously productize wireless results.',
  15.  
  16.         'why_me_content'    => 'Assertively target cooperative experiences whereas tactical total linkage. Intrinsicly transition end-to-end synergy via low-risk high-yield internal or "organic" sources. Assertively synergize dynamic scenarios through user friendly services. Seamlessly communicate.',
  17.  
  18.         'vision_content'    => 'Seamlessly administrate team building opportunities after sustainable portals. Phosfluorescently incentivize cost effective action items without innovative meta-services. Globally monetize backward-compatible portals and performance based bandwidth. Distinctively underwhelm cost effective.'
  19.         ),$attr));
  20.  
  21. ob_start(); ?>
  22.  
  23.     <!-- Start About Me Section -->
  24.     <section id="about" class="section">
  25.         <div class="container">
  26.             <div class="row">
  27.                 <div class="col-xs-12">
  28.                     <div class="profile-intro text-center">
  29.                         <div class="profile-img-wrapper wow fadeInUp" data-wow-duration="1s" data-wow-offset="200">
  30.                         <img class="img-responsive img-circle" src="<?php echo $image; ?>" alt="profile">
  31.                     </div>
  32.                     <h2><?php echo $name; ?></h2>
  33.                     <div class="separator centered"></div>
  34.                     <p class="title"><?php echo $tagline; ?></p>
  35.                     </div>
  36.                 </div>
  37.             </div>
  38.             <div class="row">
  39.                 <!-- My Personal Info -->
  40.                 <div class="profile text-center col-sm-5 col-sm-push-7">
  41.                     <div class="wow fadeInRight" data-wow-duration="1s" data-wow-offset="200">
  42.                         <h4>Personal Info</h4>
  43.                         <div class="separator centered"></div>
  44.                         <p class="para"><span class="highlight">My Name:</span> <?php echo $name; ?></p>
  45.                         <p class="para"><span class="highlight">Nationality:</span> <?php echo $nationality; ?></p>
  46.                         <p class="para"><span class="highlight">Date Of Birth:</span> <?php echo $date_of_birth; ?></p>
  47.                         <p class="para"><span class="highlight">E-mail:</span> <a href="mailto:admin@prema.com"><?php echo $e_mail; ?></a></p>
  48.                         <p class="para"><span class="highlight">Website:</span> <a href="<?php echo $website; ?>"><?php echo $website; ?></a></p>
  49.                         <p class="para"><span class="highlight">My Phone:</span> <a href="tel:<?php echo $phone; ?>"><?php echo $phone; ?></a></p>
  50.                         <p class="para"><span class="highlight">Skype:</span> <a href="tel:<?php echo $skype; ?>"><?php echo $skype; ?></a></p>
  51.                     </div>
  52.                 </div>
  53.                 <div class="info-tabs col-sm-7 col-sm-pull-5 wow fadeInLeft" data-wow-duration="1s" data-wow-offset="200">
  54.                     <!-- Tabs Nav -->
  55.                     <ul class="nav nav-tabs" role="tablist">
  56.                         <li role="presentation" class="active">
  57.                             <a href="#about-me-panel" aria-controls="about-me-panel" role="tab" data-toggle="tab">About Me</a>
  58.                         </li>
  59.                         <li role="presentation">
  60.                             <a href="#why-me-panel" aria-controls="why-me-panel" role="tab" data-toggle="tab">Why Me</a>
  61.                         </li>
  62.                         <li role="presentation">
  63.                             <a href="#my-vision-panel" aria-controls="my-vision-panel" role="tab" data-toggle="tab">My Vision</a>
  64.                         </li>
  65.                     </ul>
  66.                     <!-- Tabs Panel -->
  67.                     <div class="tab-content">
  68.                         <!-- About Me Panel -->
  69.                         <div role="tabpanel" class="tab-pane fade in active" id="about-me-panel">
  70.                             <h4>About Me</h4>
  71.                             <div class="separator"></div>
  72.                             <p class="para"><span></span></p>
  73.                             <p class="para"><?php echo $about_me_content; ?></p>
  74.                         </div>
  75.                         <!-- Why Me Panel -->
  76.                         <div role="tabpanel" class="tab-pane fade" id="why-me-panel">
  77.                             <h4>Why to choose me</h4>
  78.                             <div class="separator"></div>
  79.                             <p class="para"><?php echo $why_me_content; ?></p>
  80.                             </p>
  81.                         </div>
  82.                         <!-- My Vision Panel -->
  83.                         <div role="tabpanel" class="tab-pane fade" id="my-vision-panel">
  84.                             <h4>Here is My Vision</h4>
  85.                             <div class="separator"></div>
  86.                             <p class="para"><?php echo $vision_content; ?></p>
  87.                         </div>
  88.                     </div>
  89.                 </div>
  90.             </div>
  91.         </div>
  92.     </section>
  93.     <!-- End About Me Section -->
  94.  
  95.  
  96.  
  97.     <?php return ob_get_clean();
  98. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement