webriti

Enable feature section on front page

Apr 9th, 2016
57
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.51 KB | None | 0 0
  1. <?php
  2. /**
  3. * @Theme Name : wallstreet-Pro
  4. * @file : front-page.php
  5. * @package : wallstreet-Pro
  6. @author : webriti
  7. * @filesource : wp-content/themes/wallstreet/front-page.php
  8. */
  9. if('page' == get_option('show_on_front')){ get_template_part('index');}
  10. else
  11. {
  12. $wallstreet_pro_options=theme_data_setup();
  13. $current_options = wp_parse_args( get_option( 'wallstreet_pro_options', array() ), $wallstreet_pro_options );
  14. get_header();
  15. get_template_part('index','slider');
  16. $data = is_array($current_options['front_page_data']) ? $current_options['front_page_data'] : explode(",",$current_options['front_page_data']);
  17. if($data)
  18. {
  19. foreach($data as $key=>$value)
  20. {
  21. switch($value)
  22. {
  23. case 'service':
  24. //****** get index service ********
  25. get_template_part('index', 'service');
  26. break;
  27.  
  28. case 'portfolio':
  29. //****** get index project ********
  30. get_template_part('index', 'portfolio');
  31. break;
  32.  
  33. case 'testimonials':
  34. //****** get index testimonials ********
  35. get_template_part('index', 'testimonials');
  36. break;
  37.  
  38. case 'blog':
  39. //****** get index recent blog ********
  40. get_template_part('index', 'blog');
  41. break;
  42.  
  43.  
  44. }
  45. }
  46.  
  47.  
  48. //****** get index Features Section ********
  49. get_template_part('index', 'features');
  50.  
  51. //****** get index client ********
  52. get_template_part('index', 'client');
  53.  
  54. get_footer();
  55. } }
  56. ?>
Add Comment
Please, Sign In to add comment