*/ class Rex_Feed_Template_Pricepanda extends Rex_Feed_Abstract_Template { protected function init_atts(){ $this->attributes = array( 'Required Information' => array( 'product_id' => 'Product ID', 'product_name' => 'Product Name', 'short_description'=> 'Short Description', 'price' => 'Price', 'image_link' => 'Image Link', 'category_name' => 'Category Name', 'product_url' => 'Product URL', 'brand' => 'Brand', 'model' => 'Model', 'shipment_costs' => 'Shipment Costs', ), 'Recommended Information' => array( 'mpn' => 'MPN', 'sku' => 'SKU', ), 'Additional Information' => array( 'sale_price' => 'Sale Price', 'size' => 'Size', 'age' => 'Age', ), ); } protected function init_default_template_mappings(){ $this->template_mappings = array( array( 'attr' => 'product_id', 'type' => 'meta', 'meta_key' => 'id', 'st_value' => '', 'prefix' => '', 'suffix' => '', 'escape' => 'default', 'limit' => 0, ), array( 'attr' => 'product_name', 'type' => 'meta', 'meta_key' => 'title', 'st_value' => '', 'prefix' => '', 'suffix' => '', 'escape' => 'default', 'limit' => 0, ), array( 'attr' => 'short_description', 'type' => 'meta', 'meta_key' => 'description', 'st_value' => '', 'prefix' => '', 'suffix' => '', 'escape' => 'default', 'limit' => 0, ), array( 'attr' => 'price', 'type' => 'meta', 'meta_key' => 'price', 'st_value' => '', 'prefix' => '', 'suffix' => ' '.get_option('woocommerce_currency'), 'escape' => 'default', 'limit' => 0, ), array( 'attr' => 'image_link', 'type' => 'meta', 'meta_key' => 'featured_image', 'st_value' => '', 'prefix' => '', 'suffix' => '', 'escape' => 'default', 'limit' => 0, ), array( 'attr' => 'category_name', 'type' => 'meta', 'meta_key' => 'product_cats', 'st_value' => '', 'prefix' => '', 'suffix' => '', 'escape' => 'default', 'limit' => 0, ), array( 'attr' => 'product_url', 'type' => 'meta', 'meta_key' => 'link', 'st_value' => '', 'prefix' => '', 'suffix' => '', 'escape' => 'default', 'limit' => 0, ), array( 'attr' => 'brand', 'type' => 'meta', 'meta_key' => 'brand', 'st_value' => '', 'prefix' => '', 'suffix' => '', 'escape' => 'default', 'limit' => 0, ), array( 'attr' => 'model', 'type' => 'meta', 'meta_key' => 'model', 'st_value' => '', 'prefix' => '', 'suffix' => '', 'escape' => 'default', 'limit' => 0, ), array( 'attr' => 'shipment_costs', 'type' => 'meta', 'meta_key' => 'shipment_costs', 'st_value' => '', 'prefix' => '', 'suffix' => '', 'escape' => 'default', 'limit' => 0, ), ); } }