Advertisement
Guest User

Untitled

a guest
Feb 19th, 2019
131
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.46 KB | None | 0 0
  1. <?php include "header.php"; ?>
  2. <div class="singlepage">
  3. <div class="wrapper">
  4. <?php global $post;
  5. while (have_posts()) : the_post();
  6. $product = foxypress_GetProduct($post->ID); ?>
  7. <h1>Shop <img src="<?php bloginfo('template_directory'); ?>/images/arrow-right.png" class="arrow-right" /> <?php echo($product['categories'][0]['name']);?> <img src="<?php bloginfo('template_directory'); ?>/images/arrow-right.png" class="arrow-right" /> <?=$product['name'];?></h1>
  8. <div class="pagecontent">
  9. <div class="productleftcontent">
  10. <h2 class="findproduct">Find Products</h2>
  11. <form name="foxypress_search_form" autosave="google" results="5" id="foxypress_search_form" method="POST" action="<?php echo site_url(); ?>">
  12. <input type="text" id="foxy_search_term" name="foxy_search_term" class="searchbox" value="" />
  13. <input type="submit" id="foxy_search_submit" name="foxy_search_submit" class="searchbutton" />
  14. </form>
  15. <h2 class="categories">Categories</h2>
  16. <ul class="product-category">
  17. <?php
  18. $product_pages = explode( ',', $fp_modern_options['product_pages'] );
  19. foreach( $product_pages as $product_page_number ) { ?>
  20. <li><a href='<?php echo home_url( '/' ); ?><?php echo $fp_modern_options['product_page_slug_' . $product_page_number]; ?>'><?php echo $fp_modern_options['product_page_title_' . $product_page_number]; ?></a></li>
  21. <?php } ?>
  22. </ul>
  23. <h2 class="orderinfo">Order Info</h2>
  24. <a href="<?php echo home_url( '/' ); ?>track-your-order/">Track Your Order</a><br />
  25. <?php foxypress_GetMiniCartWidget($dropdowndisplay, true); ?>
  26. </div>
  27.  
  28. <div class="productrightcontent">
  29. <div class="productimage">
  30. <?php
  31. $ItemImage = foxypress_GetMainInventoryImage($post->ID);
  32. if($ItemImage == "")
  33. {
  34. echo("<img src=\"" . INVENTORY_IMAGE_DIR . "/" . INVENTORY_DEFAULT_IMAGE . "\" class=\"foxypress_main_item_image\" id=\"foxypress_main_item_image\" />");
  35. }
  36. else
  37. {
  38. echo("<img src=\"" . $ItemImage . "\" id=\"foxypress_main_item_image\" class=\"foxypress_main_item_image\"/>");
  39. }
  40. ?>
  41. </div>
  42. <div class="productdescription">
  43. <h4><?=$product['name'];?></h4>
  44. <p><?=$product['description'];?></p>
  45. <h2>Price: <?=(($product['sale_price']!="0.00" && $product['sale_price']!="")? "<span class=\"price-strike\">" . foxypress_FormatCurrency($product['price']) . "</span> <span class=\"price-sale\">" . foxypress_FormatCurrency($product['sale_price']) ."</span>"
  46. : foxypress_FormatCurrency($product['price']) );?></h2>
  47. <?php
  48. $productOutput = foxypress_GetProductFormStart($post->ID, "foxypress_" . $post->ID, false). foxypress_BuildOptionList($post->ID, "foxypress_" . $post->ID, $product['quantity_max']).((foxypress_CanAddToCart($post->ID,$product['quantity']))? "<input class=\"addtocart\" type=\"submit\" value=\"Add to Cart\" />": "<div class=\"foxypress_item_submit_detail outofstock\">Sorry, we are sold out of this product.</div>"). foxypress_GetProductFormEnd();
  49. if(foxypress_HasCartValidation())
  50. {
  51. $productOutput = FoxyCart_Helper::fc_hash_html($productOutput);
  52. }
  53. echo($productOutput);
  54. ?>
  55.  
  56. </div>
  57. <div class="clear"></div>
  58. <h3 class="border">View Gallery</h3>
  59. <?php
  60. $Foxypress_Image_Mode = get_option('foxypress_image_mode');
  61. $ItemImages = $product['images'];
  62. if(!empty($ItemImages) && count($ItemImages) > 1)
  63. {
  64. $ItemThumbs = "<ul class=\"foxypress_item_image_thumbs_detail" . $CssSuffix . "\">";
  65. //check to see if we have a featured image, if we do, use that as the first thumb
  66. $FeaturedImage = foxypress_GetFeaturedInventoryImage($product['id']);
  67.  
  68. if($FeaturedImage != "")
  69. {
  70. if($Foxypress_Image_Mode == FOXYPRESS_USE_COLORBOX)
  71. {
  72. $ItemThumbs .= "<li><a href=\"" . $FeaturedImage . "\" rel=\"colorbox\"><img src=\"" . $FeaturedImage . "\" /></a></li>";
  73. }
  74. else
  75. {
  76. $ItemThumbs .= "<li><a href=\"javascript:ToggleItemImage('" . $FeaturedImage . "');\" ><img src=\"" . $FeaturedImage . "\" /></a></li>";
  77. }
  78. }
  79. //loop through all the images
  80. foreach($product['images'] as $li)
  81. {
  82. //make sure were not repeating the featured image
  83. if($FeaturedImage != $li['name'])
  84. {
  85. if($Foxypress_Image_Mode == FOXYPRESS_USE_COLORBOX)
  86. {
  87. $ItemThumbs .= "<li><a href=\"" . $li['name'] . "\" rel=\"colorbox\"><img src=\"" . $li['name'] . "\" /></a></li>";
  88. }
  89. else
  90. {
  91. $ItemThumbs .= "<li><a href=\"javascript:ToggleItemImage('" . $li['name'] . "');\" ><img src=\"" . $li['name'] . "\" /></a></li>";
  92. }
  93. }
  94. }
  95. $ItemThumbs .= "</ul>";
  96. }
  97. echo($ItemThumbs);
  98. ?>
  99. <h3 class="border">Customer Reviews</h3>
  100. <div class="fb-comments" data-href="<?php the_permalink();?>" data-num-posts="5" data-width="685"></div>
  101.  
  102. </div>
  103. <div class="clear"></div>
  104. </div>
  105. <?php endwhile; ?>
  106. <?php get_footer(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement