RicoNeitzel_VertNav - Version 0.4.2

Version Notes

New Portuguese Locale
New Feature: css-class for categories that have children

Download this release

Release Info

Developer Magento Core Team
Extension RicoNeitzel_VertNav
Version 0.4.2
Comparing to
See all releases


Code changes from version 0.4.1 to 0.4.2

app/code/community/RicoNeitzel/VertNav/Block/Navigation.php CHANGED
@@ -29,182 +29,190 @@
29
*/
30
class RicoNeitzel_VertNav_Block_Navigation extends Mage_Catalog_Block_Navigation
31
{
32
- protected $_storeCategories;
33
-
34
- /**
35
- * Add the customer group to the cache key so this module is compatible with more extensions.
36
- * Netzarbeiter_GroupsCatalog
37
- * Netzarbeiter_LoginCatalog
38
- *
39
- * Also add the current product and current cms page id if they exist if
40
- * this block has been added to a cms or product detail page.
41
- *
42
- * @return string
43
- */
44
public function getCacheKey()
45
{
46
- $key = parent::getCacheKey();
47
$customerGroupId = $this->_getCustomerGroupId();
48
- $productId = Mage::registry('current_product') ? Mage::registry('current_product')->getId() : 0;
49
- $cmsPageId = Mage::app()->getRequest()->getParam('page_id', Mage::getStoreConfig(Mage_Cms_Helper_Page::XML_PATH_HOME_PAGE));
50
51
return 'VERTNAV_' . $key . '_' . $customerGroupId . '_' . $productId . '_' . $cmsPageId;
52
}
53
54
/**
55
* check if we should hide the categories because of Netzarbeiter_LoginCatalog
56
- *
57
* @return boolean
58
*/
59
protected function _checkLoginCatalog()
60
{
61
- return $this->_isLoginCatalogInstalledAndActive() && $this->_loginCatalogHideCategories();
62
}
63
64
/**
65
* Check if the Netzarbeiter_LoginCatalog extension is installed and active
66
- *
67
* @return boolean
68
*/
69
protected function _isLoginCatalogInstalledAndActive()
70
{
71
- if ($node = Mage::getConfig()->getNode('modules/Netzarbeiter_LoginCatalog'))
72
- {
73
- return strval($node->active) == 'true';
74
- }
75
- return false;
76
}
77
78
/**
79
* Check if the Netzarbeiter_LoginCatalog extension is configured to hide categories from logged out customers
80
- *
81
* @return boolean
82
*/
83
protected function _loginCatalogHideCategories()
84
{
85
- if (! Mage::getSingleton('customer/session')->isLoggedIn()
86
- && Mage::helper('logincatalog')->moduleActive()
87
- && Mage::helper('logincatalog')->getConfig('hide_categories')) {
88
- return true;
89
- }
90
- return false;
91
}
92
93
/**
94
* This method is only here to provide compatibility with the Netzarbeiter_LoginCatalog extension
95
*
96
* @param Varien_Data_Tree_Node $category
97
- * @param int $level
98
- * @param bool $last
99
* @return string
100
*/
101
- public function drawItem($category, $level=0, $last=false)
102
{
103
- if ($this->_checkLoginCatalog()) return '';
104
- return parent::drawItem($category, $level, $last);
105
}
106
107
/**
108
* Add project specific formatting
109
*
110
* @param Mage_Model_Catalog_Category $category
111
- * @param integer $level
112
- * @param array $levelClass
113
* @return string
114
*/
115
- public function drawOpenCategoryItem($category, $level=0, array $levelClass=null)
116
{
117
- $html = array();
118
119
- if ($this->_checkLoginCatalog()) return '';
120
- if (! $category->getIsActive()) return '';
121
- if (! $category->getIncludeInMenu()) return '';
122
123
- if (! isset($levelClass)) $levelClass = array();
124
- $combineClasses = array();
125
126
- $combineClasses[] = 'level' . $level;
127
- if ($this->_isCurrentCategory($category))
128
- {
129
- $combineClasses[] = 'active';
130
}
131
- else
132
- {
133
- $combineClasses[] = $this->isCategoryActive($category) ? 'parent' : 'inactive';
134
}
135
- $levelClass[] = implode('-', $combineClasses);
136
137
- $levelClass = array_merge($levelClass, $combineClasses);
138
139
- $levelClass[] = $this->_getClassNameFromCategoryName($category);
140
141
- $productCount = '';
142
- if ($this->displayProductCount())
143
- {
144
- $n = Mage::getModel('catalog/layer')->setCurrentCategory($category->getID())->getProductCollection()->getSize();
145
- $productCount = '<span class="product-count"> (' . $n . ')</span>';
146
- }
147
148
// indent HTML!
149
- $html[1] = str_pad ( "", (($level * 2 ) + 4), " " ).'<span class="vertnav-cat"><a href="'.$this->getCategoryUrl($category).'"><span>'.$this->htmlEscape($category->getName()).'</span></a>'.$productCount."</span>\n";
150
151
- $autoMaxDepth = Mage::getStoreConfig('catalog/vertnav/expand_all_max_depth');
152
- $autoExpand = Mage::getStoreConfig('catalog/vertnav/expand_all');
153
154
- if (in_array($category->getId(), $this->getCurrentCategoryPath())
155
- || ($autoExpand && $autoMaxDepth == 0)
156
- || ($autoExpand && $autoMaxDepth > $level+1)
157
- ) {
158
- $children = $this->_getCategoryCollection()
159
- ->addIdFilter($category->getChildren());
160
161
- $children = $this->toLinearArray($children);
162
163
- //usort($children, array($this, '_sortCategoryArrayByName'));
164
165
- $hasChildren = $children && ($childrenCount = count($children));
166
- if ($hasChildren)
167
- {
168
- $children = $this->toLinearArray($children);
169
$htmlChildren = '';
170
171
- foreach ($children as $i => $child)
172
- {
173
- $class = array();
174
- if ($childrenCount == 1)
175
- {
176
- $class[] = 'only';
177
- }
178
- else
179
- {
180
- if (! $i) $class[] = 'first';
181
- if ($i == $childrenCount-1) $class[] = 'last';
182
- }
183
- if (isset($children[$i+1]) && $this->isCategoryActive($children[$i+1])) $class[] = 'prev';
184
- if (isset($children[$i-1]) && $this->isCategoryActive($children[$i-1])) $class[] = 'next';
185
- $htmlChildren.= $this->drawOpenCategoryItem($child, $level+1, $class);
186
}
187
188
- if (!empty($htmlChildren))
189
- {
190
- $levelClass[] = 'open';
191
192
- // indent HTML!
193
- $html[2] = str_pad ( "", ($level * 2 ) + 2, " " ).'<ul>'."\n"
194
- .$htmlChildren."\n".
195
- str_pad ( "", ($level * 2 ) + 2, " " ).'</ul>';
196
}
197
}
198
}
199
200
- // indent HTML!
201
- $html[0] = str_pad ( "", ($level * 2 ) + 2, " " ).sprintf('<li class="%s">', implode(" ", $levelClass))."\n";
202
203
// indent HTML!
204
- $html[3] = "\n".str_pad ( "", ($level * 2 ) + 2, " " ).'</li>'."\n";
205
206
- ksort($html);
207
- return implode('', $html);
208
}
209
210
/**
@@ -212,266 +220,254 @@ class RicoNeitzel_VertNav_Block_Navigation extends Mage_Catalog_Block_Navigation
212
* it's possible to check for the previous/next category
213
*
214
* @param mixed $collection
215
* @return array
216
*/
217
- public function toLinearArray($collection)
218
{
219
- $array = array();
220
- foreach ($collection as $item) $array[] = $item;
221
- return $array;
222
}
223
224
- /**
225
- * Sorting Method
226
- *
227
- * @param Mage_Catalog_Model_Category $a
228
- * @param Mage_Catalog_Model_Category $b
229
- * @return int
230
- * @deprecated
231
- */
232
- protected function _sortCategoryArrayByName($a, $b)
233
- {
234
- return strcoll($a->getName(), $b->getName());
235
- }
236
-
237
- /**
238
- * Convert the category name into a string that can be used as a css class
239
- *
240
- * @param Mage_Catalog_Model_Category $category
241
- * @return string
242
- */
243
- protected function _getClassNameFromCategoryName($category)
244
{
245
- $name = $category->getName();
246
- $name = preg_replace('/-{2,}/', '-', preg_replace('/[^a-z-]/', '-', strtolower($name)));
247
- while ($name && $name{0} == '-') $name = substr($name, 1);
248
- while ($name && substr($name, -1) == '-') $name = substr($name, 0, -1);
249
- return $name;
250
}
251
252
- /**
253
- * Return the current customer group id. Logged out customers get the group id 0,
254
- * not the default set in system > config > customers
255
- *
256
- * @return integer
257
- */
258
- protected function _getCustomerGroupId()
259
- {
260
- $session = Mage::getSingleton('customer/session');
261
- if (! $session->isLoggedIn()) $customerGroupId = Mage_Customer_Model_Group::NOT_LOGGED_IN_ID;
262
- else $customerGroupId = $session->getCustomerGroupId();
263
- return $customerGroupId;
264
- }
265
-
266
- /**
267
- * Check if the current category matches the passed in category
268
- *
269
- * @param Mage_Catalog_Model_Category $category
270
- * @return bool
271
- */
272
- protected function _isCurrentCategory($category)
273
- {
274
- return ($cat = $this->getCurrentCategory()) && $cat->getId() == $category->getId();
275
- }
276
-
277
- /**
278
- * Return the number of products assigned to the category
279
- *
280
- * @param Mage_Catalog_Model_Category|Varien_Data_Tree_Node $category
281
- * @return int
282
- */
283
- protected function _getProductCount($category)
284
- {
285
- if (null === ($count = $category->getData('product_count')))
286
- {
287
- $count = 0;
288
- if ($category instanceof Mage_Catalog_Model_Category)
289
- {
290
- $count = $category->getProductCount();
291
- }
292
- elseif ($category instanceof Varien_Data_Tree_Node)
293
- {
294
- $count = $this->_getProductCountFromTreeNode($category);
295
- }
296
- }
297
- return $count;
298
- }
299
-
300
- /**
301
- * Get the number of products from a category tree node
302
- *
303
- * @param Varien_Data_Tree_Node $category
304
- * @return int
305
- */
306
- protected function _getProductCountFromTreeNode(Varien_Data_Tree_Node $category)
307
- {
308
- return Mage::getSingleton('catalog/category')->setId($category->getId())->getProductCount();
309
- }
310
-
311
- /**
312
- * Get catagories of current store, using the max depth setting for the vertical navigation
313
- *
314
- * @return Mage_Catalog_Model_Resource_Eav_Mysql4_Category_Collection
315
- */
316
- public function getStoreCategories()
317
- {
318
- if (isset($this->_storeCategories))
319
- {
320
- return $this->_storeCategories;
321
- }
322
323
/* @var $category Mage_Catalog_Model_Category */
324
- $category = Mage::getModel('catalog/category');
325
-
326
- /* Set Category Object if Product is requested without category path in URI (top level request). Takes first Category of a Product as Category Object*/
327
-
328
- if( true == (bool) Mage::getStoreConfig( 'catalog/vertnav/show_cat_on_toplevel' ) &&
329
- false == Mage::registry('current_category') &&
330
- false != Mage::registry('current_product') ) {
331
- $product_categories = Mage::registry( 'current_product' )->getCategoryIds();
332
- if(count($product_categories) > 0) {
333
- $new_active_category = Mage::getModel('catalog/category')->load($product_categories[0]);
334
- Mage::register('current_category', $new_active_category);
335
- }
336
- }
337
-
338
-
339
- $parent = false;
340
- switch (Mage::getStoreConfig('catalog/vertnav/vertnav_root'))
341
- {
342
- case 'current':
343
- if (Mage::registry('current_category'))
344
- {
345
- $parent = Mage::registry('current_category')->getId();
346
- }
347
- break;
348
- case 'siblings':
349
- if (Mage::registry('current_category'))
350
- {
351
- $parent = Mage::registry('current_category')->getParentId();
352
- }
353
- break;
354
- case 'root':
355
- $parent = Mage::app()->getStore()->getRootCategoryId();
356
- break;
357
- default:
358
- /*
359
- * Display from level N
360
- */
361
- $fromLevel = Mage::getStoreConfig('catalog/vertnav/vertnav_root');
362
- if (Mage::registry('current_category') && Mage::registry('current_category')->getLevel() >= $fromLevel)
363
- {
364
- $cat = Mage::registry('current_category');
365
- while ($cat->getLevel() > $fromLevel)
366
- {
367
- $cat = $cat->getParentCategory();
368
- }
369
- $parent = $cat->getId();
370
- }
371
- }
372
-
373
- /**
374
- * Thanks to thebod for this patch!
375
- * It enables the setting of the category ID to use via Layout XML:
376
- *
377
- * <reference name="catalog.vertnav">
378
- * <action method="setCategoryId"><category_id>8</category_id></action>
379
- * </reference>
380
- */
381
- if ($customId = $this->getCategoryId()) {
382
- $parent = $customId;
383
- }
384
-
385
- if (! $parent && Mage::getStoreConfig('catalog/vertnav/fallback_to_root'))
386
- {
387
- $parent = Mage::app()->getStore()->getRootCategoryId();
388
- }
389
-
390
- /**
391
- * Check if parent node of the store still exists
392
- */
393
- if (! $parent || ! $category->checkId($parent))
394
- {
395
- return array();
396
- }
397
- $storeCategories = $this->_getCategoryCollection()
398
- ->addFieldToFilter('parent_id', $parent);
399
-
400
- $this->_storeCategories = $storeCategories;
401
- return $storeCategories;
402
- }
403
-
404
- /**
405
- * $childrenIdString is a comma seperated list of category IDs
406
- *
407
- * @return Mage_Catalog_Model_Resource_Eav_Mysql4_Category_Collection
408
- */
409
- protected function _getCategoryCollection()
410
- {
411
- $collection = Mage::getResourceModel('catalog/category_collection');
412
- /* @var $collection Mage_Catalog_Model_Resource_Eav_Mysql4_Category_Collection */
413
- $collection->addAttributeToSelect('url_key')
414
- ->addAttributeToSelect('name')
415
- ->addAttributeToSelect('all_children')
416
- ->addAttributeToFilter('is_active', 1)
417
- ->addAttributeToFilter('include_in_menu', 1)
418
- ->setOrder('position', 'ASC')
419
- ->joinUrlRewrite();
420
-
421
- if ($this->displayProductCount())
422
- {
423
- $collection->setLoadProductCount(true);
424
- }
425
-
426
- return $collection;
427
- }
428
-
429
- /**
430
- *
431
- * @param Mage_Catalog_Model_Resource_Eav_Mysql4_Category_Collection $collection
432
- * @return RicoNeitzel_VertNav_Block_Navigation
433
- * @deprecated Now the count is added directly in _getCategoryChildren()
434
- * @see _getCategoryChildren()
435
- */
436
- protected function _addProductCount($collection)
437
- {
438
- if ($collection instanceof Mage_Catalog_Model_Resource_Eav_Mysql4_Category_Collection)
439
- {
440
- if ($collection->isLoaded())
441
- {
442
- $collection->loadProductCount($collection->getItems());
443
- }
444
- else
445
- {
446
- $collection->setLoadProductCount(true);
447
- }
448
- }
449
- else
450
- {
451
- $this->_getProductCollectionResource()->addCountToCategories($collection);
452
- }
453
- return $this;
454
- }
455
-
456
- /**
457
- *
458
- * @return Mage_Catalog_Model_Resource_Eav_Mysql4_Product_Collection
459
- */
460
- protected function _getProductCollectionResource()
461
- {
462
- if (null === $this->_productCollection)
463
- {
464
- $this->_productCollection = Mage::getResourceModel('catalog/product_collection');
465
- }
466
- return $this->_productCollection;
467
- }
468
-
469
- /**
470
- *
471
- * @return bool
472
- */
473
- public function displayProductCount()
474
- {
475
- return Mage::getStoreConfigFlag('catalog/vertnav/display_product_count');
476
- }
477
}
29
*/
30
class RicoNeitzel_VertNav_Block_Navigation extends Mage_Catalog_Block_Navigation
31
{
32
+
33
+ protected $_storeCategories;
34
+
35
+ /**
36
+ * Add the customer group to the cache key so this module is compatible with more extensions.
37
+ * Netzarbeiter_GroupsCatalog
38
+ * Netzarbeiter_LoginCatalog
39
+ * Also add the current product and current cms page id if they exist if
40
+ * this block has been added to a cms or product detail page.
41
+ * @return string
42
+ */
43
public function getCacheKey()
44
{
45
+
46
+ $key = parent::getCacheKey();
47
$customerGroupId = $this->_getCustomerGroupId();
48
+ $productId = Mage::registry( 'current_product' ) ? Mage::registry( 'current_product' )->getId() : 0;
49
+ $cmsPageId = Mage::app()->getRequest()->getParam( 'page_id', Mage::getStoreConfig( Mage_Cms_Helper_Page::XML_PATH_HOME_PAGE ) );
50
51
return 'VERTNAV_' . $key . '_' . $customerGroupId . '_' . $productId . '_' . $cmsPageId;
52
}
53
54
/**
55
* check if we should hide the categories because of Netzarbeiter_LoginCatalog
56
* @return boolean
57
*/
58
protected function _checkLoginCatalog()
59
{
60
+
61
+ return $this->_isLoginCatalogInstalledAndActive() && $this->_loginCatalogHideCategories();
62
}
63
64
/**
65
* Check if the Netzarbeiter_LoginCatalog extension is installed and active
66
* @return boolean
67
*/
68
protected function _isLoginCatalogInstalledAndActive()
69
{
70
+
71
+ if( $node = Mage::getConfig()->getNode( 'modules/Netzarbeiter_LoginCatalog' ) ) {
72
+ return strval( $node->active ) == 'true';
73
+ }
74
+ return FALSE;
75
}
76
77
/**
78
* Check if the Netzarbeiter_LoginCatalog extension is configured to hide categories from logged out customers
79
* @return boolean
80
*/
81
protected function _loginCatalogHideCategories()
82
{
83
+
84
+ if( !Mage::getSingleton( 'customer/session' )->isLoggedIn() && Mage::helper( 'logincatalog' )->moduleActive() && Mage::helper( 'logincatalog' )->getConfig( 'hide_categories' ) ) {
85
+ return TRUE;
86
+ }
87
+ return FALSE;
88
}
89
90
/**
91
* This method is only here to provide compatibility with the Netzarbeiter_LoginCatalog extension
92
*
93
* @param Varien_Data_Tree_Node $category
94
+ * @param int $level
95
+ * @param bool $last
96
+ *
97
* @return string
98
*/
99
+ public function drawItem( $category, $level = 0, $last = FALSE )
100
{
101
+
102
+ if( $this->_checkLoginCatalog() ) {
103
+ return '';
104
+ }
105
+ return parent::drawItem( $category, $level, $last );
106
}
107
108
/**
109
* Add project specific formatting
110
*
111
* @param Mage_Model_Catalog_Category $category
112
+ * @param integer $level
113
+ * @param array $levelClass
114
+ *
115
* @return string
116
*/
117
+ public function drawOpenCategoryItem( $category, $level = 0, array $levelClass = NULL )
118
{
119
120
+ $html = array ();
121
+
122
+ if( $this->_checkLoginCatalog() ) {
123
+ return '';
124
+ }
125
+ if( !$category->getIsActive() ) {
126
+ return '';
127
+ }
128
+ if( !$category->getIncludeInMenu() ) {
129
+ return '';
130
+ }
131
132
+ if( !isset( $levelClass ) ) {
133
+ $levelClass = array ();
134
+ }
135
+ $combineClasses = array ();
136
137
+ $combineClasses[ ] = 'level' . $level;
138
+ if( $this->_isCurrentCategory( $category ) ) {
139
+ $combineClasses[ ] = 'active';
140
+ } else {
141
+ $combineClasses[ ] = $this->isCategoryActive( $category ) ? 'parent' : 'inactive';
142
}
143
+ $levelClass[ ] = implode( '-', $combineClasses );
144
+
145
+ if($category->hasChildren()) {
146
+ $levelClass[ ] = 'has-children';
147
}
148
149
+ $levelClass = array_merge( $levelClass, $combineClasses );
150
151
+ $levelClass[ ] = $this->_getClassNameFromCategoryName( $category );
152
153
+ $productCount = '';
154
+ if( $this->displayProductCount() ) {
155
+ $n = Mage::getModel( 'catalog/layer' )->setCurrentCategory( $category->getID() )->getProductCollection()->getSize();
156
+ $productCount = '<span class="product-count"> (' . $n . ')</span>';
157
+ }
158
159
// indent HTML!
160
+ $html[ 1 ] = str_pad( "", ( ( $level * 2 ) + 4 ), " " ) . '<span class="vertnav-cat"><a href="' . $this->getCategoryUrl( $category ) . '"><span>' . $this->htmlEscape( $category->getName() ) . '</span></a>' . $productCount . "</span>\n";
161
162
+ $autoMaxDepth = Mage::getStoreConfig( 'catalog/vertnav/expand_all_max_depth' );
163
+ $autoExpand = Mage::getStoreConfig( 'catalog/vertnav/expand_all' );
164
165
+ if( in_array( $category->getId(), $this->getCurrentCategoryPath() ) || ( $autoExpand && $autoMaxDepth == 0 ) || ( $autoExpand && $autoMaxDepth > $level + 1 )
166
+ ) {
167
+ $children = $this->_getCategoryCollection()->addIdFilter( $category->getChildren() );
168
169
+ $children = $this->toLinearArray( $children );
170
171
+ //usort($children, array($this, '_sortCategoryArrayByName'));
172
173
+ $hasChildren = $children && ( $childrenCount = count( $children ) );
174
+ if( $hasChildren ) {
175
+ $children = $this->toLinearArray( $children );
176
$htmlChildren = '';
177
178
+ foreach( $children as $i => $child ) {
179
+ $class = array ();
180
+ if( $childrenCount == 1 ) {
181
+ $class[ ] = 'only';
182
+ } else {
183
+ if( !$i ) {
184
+ $class[ ] = 'first';
185
+ }
186
+ if( $i == $childrenCount - 1 ) {
187
+ $class[ ] = 'last';
188
+ }
189
+ }
190
+ if( isset( $children[ $i + 1 ] ) && $this->isCategoryActive( $children[ $i + 1 ] ) ) {
191
+ $class[ ] = 'prev';
192
+ }
193
+ if( isset( $children[ $i - 1 ] ) && $this->isCategoryActive( $children[ $i - 1 ] ) ) {
194
+ $class[ ] = 'next';
195
+ }
196
+ $htmlChildren .= $this->drawOpenCategoryItem( $child, $level + 1, $class );
197
}
198
199
+ if( !empty( $htmlChildren ) ) {
200
+ $levelClass[ ] = 'open';
201
202
+ // indent HTML!
203
+ $html[ 2 ] = str_pad( "", ( $level * 2 ) + 2, " " ) . '<ul>' . "\n" . $htmlChildren . "\n" . str_pad( "", ( $level * 2 ) + 2, " " ) . '</ul>';
204
}
205
}
206
}
207
208
+ // indent HTML!
209
+ $html[ 0 ] = str_pad( "", ( $level * 2 ) + 2, " " ) . sprintf( '<li class="%s">', implode( " ", $levelClass ) ) . "\n";
210
211
// indent HTML!
212
+ $html[ 3 ] = "\n" . str_pad( "", ( $level * 2 ) + 2, " " ) . '</li>' . "\n";
213
214
+ ksort( $html );
215
+ return implode( '', $html );
216
}
217
218
/**
220
* it's possible to check for the previous/next category
221
*
222
* @param mixed $collection
223
+ *
224
* @return array
225
*/
226
+ public function toLinearArray( $collection )
227
{
228
+
229
+ $array = array ();
230
+ foreach( $collection as $item )
231
+ $array[ ] = $item;
232
+ return $array;
233
}
234
235
+ /**
236
+ * Sorting Method
237
+ *
238
+ * @param Mage_Catalog_Model_Category $a
239
+ * @param Mage_Catalog_Model_Category $b
240
+ *
241
+ * @return int
242
+ * @deprecated
243
+ */
244
+ protected function _sortCategoryArrayByName( $a, $b )
245
{
246
+
247
+ return strcoll( $a->getName(), $b->getName() );
248
}
249
250
+ /**
251
+ * Convert the category name into a string that can be used as a css class
252
+ *
253
+ * @param Mage_Catalog_Model_Category $category
254
+ *
255
+ * @return string
256
+ */
257
+ protected function _getClassNameFromCategoryName( $category )
258
+ {
259
+
260
+ $name = $category->getName();
261
+ $name = preg_replace( '/-{2,}/', '-', preg_replace( '/[^a-z-]/', '-', strtolower( $name ) ) );
262
+ while( $name && $name{0} == '-' )
263
+ $name = substr( $name, 1 );
264
+ while( $name && substr( $name, -1 ) == '-' )
265
+ $name = substr( $name, 0, -1 );
266
+ return $name;
267
+ }
268
+
269
+ /**
270
+ * Return the current customer group id. Logged out customers get the group id 0,
271
+ * not the default set in system > config > customers
272
+ * @return integer
273
+ */
274
+ protected function _getCustomerGroupId()
275
+ {
276
+
277
+ $session = Mage::getSingleton( 'customer/session' );
278
+ if( !$session->isLoggedIn() ) {
279
+ $customerGroupId = Mage_Customer_Model_Group::NOT_LOGGED_IN_ID;
280
+ } else {
281
+ $customerGroupId = $session->getCustomerGroupId();
282
+ }
283
+ return $customerGroupId;
284
+ }
285
+
286
+ /**
287
+ * Check if the current category matches the passed in category
288
+ *
289
+ * @param Mage_Catalog_Model_Category $category
290
+ *
291
+ * @return bool
292
+ */
293
+ protected function _isCurrentCategory( $category )
294
+ {
295
+
296
+ return ( $cat = $this->getCurrentCategory() ) && $cat->getId() == $category->getId();
297
+ }
298
+
299
+ /**
300
+ * Return the number of products assigned to the category
301
+ *
302
+ * @param Mage_Catalog_Model_Category|Varien_Data_Tree_Node $category
303
+ *
304
+ * @return int
305
+ */
306
+ protected function _getProductCount( $category )
307
+ {
308
+
309
+ if( NULL === ( $count = $category->getData( 'product_count' ) ) ) {
310
+ $count = 0;
311
+ if( $category instanceof Mage_Catalog_Model_Category ) {
312
+ $count = $category->getProductCount();
313
+ } elseif( $category instanceof Varien_Data_Tree_Node ) {
314
+ $count = $this->_getProductCountFromTreeNode( $category );
315
+ }
316
+ }
317
+ return $count;
318
+ }
319
+
320
+ /**
321
+ * Get the number of products from a category tree node
322
+ *
323
+ * @param Varien_Data_Tree_Node $category
324
+ *
325
+ * @return int
326
+ */
327
+ protected function _getProductCountFromTreeNode( Varien_Data_Tree_Node $category )
328
+ {
329
+
330
+ return Mage::getSingleton( 'catalog/category' )->setId( $category->getId() )->getProductCount();
331
+ }
332
+
333
+ /**
334
+ * Get catagories of current store, using the max depth setting for the vertical navigation
335
+ * @return Mage_Catalog_Model_Resource_Eav_Mysql4_Category_Collection
336
+ */
337
+ public function getStoreCategories()
338
+ {
339
+
340
+ if( isset( $this->_storeCategories ) ) {
341
+ return $this->_storeCategories;
342
+ }
343
344
/* @var $category Mage_Catalog_Model_Category */
345
+ $category = Mage::getModel( 'catalog/category' );
346
+
347
+ /* Set Category Object if Product is requested without category path in URI (top level request). Takes first Category of a Product as Category Object*/
348
+
349
+ if( TRUE == (bool)Mage::getStoreConfig( 'catalog/vertnav/show_cat_on_toplevel' ) && FALSE == Mage::registry( 'current_category' ) && FALSE != Mage::registry( 'current_product' ) ) {
350
+ $product_categories = Mage::registry( 'current_product' )->getCategoryIds();
351
+ if( count( $product_categories ) > 0 ) {
352
+ $new_active_category = Mage::getModel( 'catalog/category' )->load( $product_categories[ 0 ] );
353
+ Mage::register( 'current_category', $new_active_category );
354
+ }
355
+ }
356
+
357
+ $parent = FALSE;
358
+ switch( Mage::getStoreConfig( 'catalog/vertnav/vertnav_root' ) ) {
359
+ case 'current':
360
+ if( Mage::registry( 'current_category' ) ) {
361
+ $parent = Mage::registry( 'current_category' )->getId();
362
+ }
363
+ break;
364
+ case 'siblings':
365
+ if( Mage::registry( 'current_category' ) ) {
366
+ $parent = Mage::registry( 'current_category' )->getParentId();
367
+ }
368
+ break;
369
+ case 'root':
370
+ $parent = Mage::app()->getStore()->getRootCategoryId();
371
+ break;
372
+ default:
373
+ /*
374
+ * Display from level N
375
+ */
376
+ $fromLevel = Mage::getStoreConfig( 'catalog/vertnav/vertnav_root' );
377
+ if( Mage::registry( 'current_category' ) && Mage::registry( 'current_category' )->getLevel() >= $fromLevel ) {
378
+ $cat = Mage::registry( 'current_category' );
379
+ while( $cat->getLevel() > $fromLevel ) {
380
+ $cat = $cat->getParentCategory();
381
+ }
382
+ $parent = $cat->getId();
383
+ }
384
+ }
385
+
386
+ /**
387
+ * Thanks to thebod for this patch!
388
+ * It enables the setting of the category ID to use via Layout XML:
389
+ * <reference name="catalog.vertnav">
390
+ * <action method="setCategoryId"><category_id>8</category_id></action>
391
+ * </reference>
392
+ */
393
+ if( $customId = $this->getCategoryId() ) {
394
+ $parent = $customId;
395
+ }
396
+
397
+ if( !$parent && Mage::getStoreConfig( 'catalog/vertnav/fallback_to_root' ) ) {
398
+ $parent = Mage::app()->getStore()->getRootCategoryId();
399
+ }
400
+
401
+ /**
402
+ * Check if parent node of the store still exists
403
+ */
404
+ if( !$parent || !$category->checkId( $parent ) ) {
405
+ return array ();
406
+ }
407
+ $storeCategories = $this->_getCategoryCollection()->addFieldToFilter( 'parent_id', $parent );
408
+
409
+ $this->_storeCategories = $storeCategories;
410
+ return $storeCategories;
411
+ }
412
+
413
+ /**
414
+ * $childrenIdString is a comma seperated list of category IDs
415
+ * @return Mage_Catalog_Model_Resource_Eav_Mysql4_Category_Collection
416
+ */
417
+ protected function _getCategoryCollection()
418
+ {
419
+
420
+ $collection = Mage::getResourceModel( 'catalog/category_collection' );
421
+ /* @var $collection Mage_Catalog_Model_Resource_Eav_Mysql4_Category_Collection */
422
+ $collection->addAttributeToSelect( 'url_key' )->addAttributeToSelect( 'name' )->addAttributeToSelect( 'all_children' )->addAttributeToFilter( 'is_active', 1 )->addAttributeToFilter( 'include_in_menu', 1 )->setOrder( 'position', 'ASC' )->joinUrlRewrite();
423
+
424
+ if( $this->displayProductCount() ) {
425
+ $collection->setLoadProductCount( TRUE );
426
+ }
427
+
428
+ return $collection;
429
+ }
430
+
431
+ /**
432
+ * @param Mage_Catalog_Model_Resource_Eav_Mysql4_Category_Collection $collection
433
+ *
434
+ * @return RicoNeitzel_VertNav_Block_Navigation
435
+ * @deprecated Now the count is added directly in _getCategoryChildren()
436
+ * @see _getCategoryChildren()
437
+ */
438
+ protected function _addProductCount( $collection )
439
+ {
440
+
441
+ if( $collection instanceof Mage_Catalog_Model_Resource_Eav_Mysql4_Category_Collection ) {
442
+ if( $collection->isLoaded() ) {
443
+ $collection->loadProductCount( $collection->getItems() );
444
+ } else {
445
+ $collection->setLoadProductCount( TRUE );
446
+ }
447
+ } else {
448
+ $this->_getProductCollectionResource()->addCountToCategories( $collection );
449
+ }
450
+ return $this;
451
+ }
452
+
453
+ /**
454
+ * @return Mage_Catalog_Model_Resource_Eav_Mysql4_Product_Collection
455
+ */
456
+ protected function _getProductCollectionResource()
457
+ {
458
+
459
+ if( NULL === $this->_productCollection ) {
460
+ $this->_productCollection = Mage::getResourceModel( 'catalog/product_collection' );
461
+ }
462
+ return $this->_productCollection;
463
+ }
464
+
465
+ /**
466
+ * @return bool
467
+ */
468
+ public function displayProductCount()
469
+ {
470
+
471
+ return Mage::getStoreConfigFlag( 'catalog/vertnav/display_product_count' );
472
+ }
473
}
app/code/community/RicoNeitzel/VertNav/etc/config.xml CHANGED
@@ -23,26 +23,26 @@
23
<config>
24
<modules>
25
<RicoNeitzel_VertNav>
26
- <version>0.4.0</version>
27
</RicoNeitzel_VertNav>
28
</modules>
29
30
<global>
31
- <blocks>
32
- <vertnav>
33
- <class>RicoNeitzel_VertNav_Block</class>
34
- </vertnav>
35
- </blocks>
36
- <models>
37
- <vertnav>
38
- <class>RicoNeitzel_VertNav_Model</class>
39
- </vertnav>
40
- </models>
41
- <helpers>
42
- <vertnav>
43
- <class>RicoNeitzel_VertNav_Helper</class>
44
- </vertnav>
45
- </helpers>
46
</global>
47
<frontend>
48
<layout>
@@ -54,28 +54,28 @@
54
</layout>
55
</frontend>
56
<adminhtml>
57
- <translate>
58
- <modules>
59
- <RicoNeitzel_VertNav>
60
- <files>
61
- <default>RicoNeitzel_VertNav.csv</default>
62
- </files>
63
- </RicoNeitzel_VertNav>
64
- </modules>
65
- </translate>
66
</adminhtml>
67
<default>
68
- <catalog>
69
- <vertnav>
70
- <display_product_count>0</display_product_count>
71
- <expand_all>0</expand_all>
72
- <expand_all_max_depth>0</expand_all_max_depth>
73
<hide_top>1</hide_top>
74
<hide_vertnav>0</hide_vertnav>
75
- <vertnav_root>root</vertnav_root>
76
- <fallback_to_root>1</fallback_to_root>
77
- </vertnav>
78
- </catalog>
79
</default>
80
</config>
81
23
<config>
24
<modules>
25
<RicoNeitzel_VertNav>
26
+ <version>0.4.2</version>
27
</RicoNeitzel_VertNav>
28
</modules>
29
30
<global>
31
+ <blocks>
32
+ <vertnav>
33
+ <class>RicoNeitzel_VertNav_Block</class>
34
+ </vertnav>
35
+ </blocks>
36
+ <models>
37
+ <vertnav>
38
+ <class>RicoNeitzel_VertNav_Model</class>
39
+ </vertnav>
40
+ </models>
41
+ <helpers>
42
+ <vertnav>
43
+ <class>RicoNeitzel_VertNav_Helper</class>
44
+ </vertnav>
45
+ </helpers>
46
</global>
47
<frontend>
48
<layout>
54
</layout>
55
</frontend>
56
<adminhtml>
57
+ <translate>
58
+ <modules>
59
+ <RicoNeitzel_VertNav>
60
+ <files>
61
+ <default>RicoNeitzel_VertNav.csv</default>
62
+ </files>
63
+ </RicoNeitzel_VertNav>
64
+ </modules>
65
+ </translate>
66
</adminhtml>
67
<default>
68
+ <catalog>
69
+ <vertnav>
70
+ <display_product_count>0</display_product_count>
71
+ <expand_all>0</expand_all>
72
+ <expand_all_max_depth>0</expand_all_max_depth>
73
<hide_top>1</hide_top>
74
<hide_vertnav>0</hide_vertnav>
75
+ <vertnav_root>root</vertnav_root>
76
+ <fallback_to_root>1</fallback_to_root>
77
+ </vertnav>
78
+ </catalog>
79
</default>
80
</config>
81
app/design/frontend/base/default/layout/vertnav.xml CHANGED
@@ -29,36 +29,47 @@
29
<layout version="0.1.0">
30
<default>
31
<reference name="head">
32
- <action method="addItem"><type>skin_css</type><name>css/vertnav.css</name></action>
33
</reference>
34
<reference name="top.menu">
35
- <action method="unsetChild" ifconfig="catalog/vertnav/hide_top"><name>catalog.topnav</name></action>
36
</reference>
37
<reference name="left">
38
- <action method="unsetChild" ifconfig="catalog/vertnav/hide_vertnav"><name>catalog.vertnav</name></action>
39
</reference>
40
<reference name="left">
41
- <block type="vertnav/navigation" name="catalog.vertnav" template="vertnav/left.phtml" before="-" />
42
</reference>
43
- <reference name="left">
44
- <action method="unsetChild" ifconfig="catalog/vertnav/hide_vertnav"><name>catalog.vertnav</name></action>
45
- </reference> </default>
46
47
- <customer_account>
48
- <reference name="left">
49
- <action method="unsetChild"><name>catalog.vertnav</name></action>
50
- </reference>
51
- </customer_account>
52
53
- <catalog_category_default>
54
- <reference name="left">
55
- <action method="unsetChild"><name>catalog.leftnav</name></action>
56
- </reference>
57
- </catalog_category_default>
58
59
- <catalog_category_layered>
60
- <reference name="catalog.leftnav">
61
- <action method="unsetChild"><name>category_filter</name></action>
62
- </reference>
63
- </catalog_category_layered>
64
</layout>
29
<layout version="0.1.0">
30
<default>
31
<reference name="head">
32
+ <action method="addItem">
33
+ <type>skin_css</type>
34
+ <name>css/vertnav.css</name>
35
+ </action>
36
</reference>
37
<reference name="top.menu">
38
+ <action method="unsetChild" ifconfig="catalog/vertnav/hide_top">
39
+ <name>catalog.topnav</name>
40
+ </action>
41
</reference>
42
<reference name="left">
43
+ <block type="vertnav/navigation" name="catalog.vertnav" template="vertnav/left.phtml" before="-"/>
44
</reference>
45
<reference name="left">
46
+ <action method="unsetChild" ifconfig="catalog/vertnav/hide_vertnav">
47
+ <name>catalog.vertnav</name>
48
+ </action>
49
</reference>
50
+ </default>
51
52
+ <customer_account>
53
+ <reference name="left">
54
+ <action method="unsetChild">
55
+ <name>catalog.vertnav</name>
56
+ </action>
57
+ </reference>
58
+ </customer_account>
59
60
+ <catalog_category_default>
61
+ <reference name="left">
62
+ <action method="unsetChild">
63
+ <name>catalog.leftnav</name>
64
+ </action>
65
+ </reference>
66
+ </catalog_category_default>
67
68
+ <catalog_category_layered>
69
+ <reference name="catalog.leftnav">
70
+ <action method="unsetChild">
71
+ <name>category_filter</name>
72
+ </action>
73
+ </reference>
74
+ </catalog_category_layered>
75
</layout>
app/design/frontend/default/default/layout/vertnav.xml CHANGED
@@ -29,36 +29,47 @@
29
<layout version="0.1.0">
30
<default>
31
<reference name="head">
32
- <action method="addItem"><type>skin_css</type><name>css/vertnav.css</name></action>
33
</reference>
34
<reference name="top.menu">
35
- <action method="unsetChild" ifconfig="catalog/vertnav/hide_top"><name>catalog.topnav</name></action>
36
</reference>
37
<reference name="left">
38
- <action method="unsetChild" ifconfig="catalog/vertnav/hide_vertnav"><name>catalog.vertnav</name></action>
39
</reference>
40
<reference name="left">
41
- <block type="vertnav/navigation" name="catalog.vertnav" template="vertnav/left.phtml" before="-" />
42
</reference>
43
- <reference name="left">
44
- <action method="unsetChild" ifconfig="catalog/vertnav/hide_vertnav"><name>catalog.vertnav</name></action>
45
- </reference> </default>
46
47
- <customer_account>
48
- <reference name="left">
49
- <action method="unsetChild"><name>catalog.vertnav</name></action>
50
- </reference>
51
- </customer_account>
52
53
- <catalog_category_default>
54
- <reference name="left">
55
- <action method="unsetChild"><name>catalog.leftnav</name></action>
56
- </reference>
57
- </catalog_category_default>
58
59
- <catalog_category_layered>
60
- <reference name="catalog.leftnav">
61
- <action method="unsetChild"><name>category_filter</name></action>
62
- </reference>
63
- </catalog_category_layered>
64
</layout>
29
<layout version="0.1.0">
30
<default>
31
<reference name="head">
32
+ <action method="addItem">
33
+ <type>skin_css</type>
34
+ <name>css/vertnav.css</name>
35
+ </action>
36
</reference>
37
<reference name="top.menu">
38
+ <action method="unsetChild" ifconfig="catalog/vertnav/hide_top">
39
+ <name>catalog.topnav</name>
40
+ </action>
41
</reference>
42
<reference name="left">
43
+ <block type="vertnav/navigation" name="catalog.vertnav" template="vertnav/left.phtml" before="-"/>
44
</reference>
45
<reference name="left">
46
+ <action method="unsetChild" ifconfig="catalog/vertnav/hide_vertnav">
47
+ <name>catalog.vertnav</name>
48
+ </action>
49
</reference>
50
+ </default>
51
52
+ <customer_account>
53
+ <reference name="left">
54
+ <action method="unsetChild">
55
+ <name>catalog.vertnav</name>
56
+ </action>
57
+ </reference>
58
+ </customer_account>
59
60
+ <catalog_category_default>
61
+ <reference name="left">
62
+ <action method="unsetChild">
63
+ <name>catalog.leftnav</name>
64
+ </action>
65
+ </reference>
66
+ </catalog_category_default>
67
68
+ <catalog_category_layered>
69
+ <reference name="catalog.leftnav">
70
+ <action method="unsetChild">
71
+ <name>category_filter</name>
72
+ </action>
73
+ </reference>
74
+ </catalog_category_layered>
75
</layout>
app/locale/pr_BR/RicoNeitzel_VertNav.csv ADDED
@@ -0,0 +1,16 @@
1
+ "Display Product Count","Mostrar Contúdo do Produto"
2
+ "Expand all categories","Expandir todas as categorias"
3
+ "Expand all max depth","Expandir toda a profundidade máxima"
4
+ "Leave empty or set to 0 for no limit","Deixar vazio ou por em 0 para ilimitado"
5
+ "Hide Top Navigation","Ocultar Menu Horizontal"
6
+ "Root Categories","Categorias Raizes"
7
+ "Store base","Loja base"
8
+ "Current category children","Categoria filha atual"
9
+ "Same level as current category","Mesmo nivel como na categoria atual"
10
+ "Expand on Top Level","Expandir em Nível Superior"
11
+ "Fallback to store base","Recorrer à loja base"
12
+ "If no current category is selected","Se nenhuma categoria atual estiver selecionada"
13
+ "Category Level %d","Nivel de Categoria %d"
14
+ "Category Vertical Navigation","Navegação Vertical de Categorias"
15
+ "If your product is top level requested without a category path should VertNav expand the category listing to the first associated product category.","Se o seu produto é de alto nível requerido, sem um caminho categoria deve VertNav expandir a lista de categoria para a categoria de primeiro produto associado."
16
+
package.xml CHANGED
@@ -1,18 +1,19 @@
1
<?xml version="1.0"?>
2
<package>
3
<name>RicoNeitzel_VertNav</name>
4
- <version>0.4.1</version>
5
<stability>stable</stability>
6
<license uri="http://opensource.org/licenses/osl-3.0.php">OSL v3.0</license>
7
<channel>community</channel>
8
<extends/>
9
<summary>Vertical Navigation - drop in replacement for the horizontal top navigation.</summary>
10
<description>Lots of css selectors available.</description>
11
- <notes>Add a vertical menu to your site. Features many css classes and several configuration options.</notes>
12
- <authors><author><name>Rico Neitzel</name><user>auto-converted</user><email>rico@buro71a.de</email></author></authors>
13
- <date>2012-10-11</date>
14
- <time>08:22:11</time>
15
- <contents><target name="magecommunity"><dir name="RicoNeitzel"><dir name="VertNav"><dir name="Block"><file name="Navigation.php" hash="2a1dbd73a8d665a34ad2e31abea39749"/></dir><dir name="Helper"><file name="Data.php" hash="a3995193a1ce5560edbd95e11720ce8b"/></dir><dir name="Model"><dir name="System"><dir name="Config"><dir name="Source"><file name="Root.php" hash="20696bf2dfef3e1092d7c08caf1dbc8e"/></dir></dir></dir></dir><dir name="etc"><file name="config.xml" hash="58244bde78a9877704957a5a3dcc4748"/><file name="system.xml" hash="4ae9f6be51baf3be807fab03f52625db"/></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="RicoNeitzel_VertNav.xml" hash="227d7980c24ebd629e1c1d4f10b8c62c"/></dir></target><target name="magelocale"><dir name="de_DE"><file name="RicoNeitzel_VertNav.csv" hash="d32b98f21146e2799b1dad8af8b57673"/></dir><dir name="es_MX"><file name="RicoNeitzel_VertNav.csv" hash="54b83643165bc5b72ca8ce2122fd5422"/></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="vertnav.xml" hash="82d9da5e6588999daaef4dcee8505f80"/></dir><dir name="template"><dir name="vertnav"><file name="left.phtml" hash="e2f0d7e286ad1d3caadd4892fbb0671f"/></dir></dir></dir></dir><dir name="default"><dir name="default"><dir name="layout"><file name="vertnav.xml" hash="82d9da5e6588999daaef4dcee8505f80"/></dir><dir name="template"><dir name="vertnav"><file name="left.phtml" hash="e2f0d7e286ad1d3caadd4892fbb0671f"/></dir></dir></dir></dir></dir></target><target name="mageskin"><dir name="frontend"><dir name="base"><dir name="default"><dir name="css"><file name="vertnav.css" hash="48ed54348eefcc8e1e0286feb84cbe4e"/></dir></dir></dir><dir name="default"><dir name="default"><dir name="css"><file name="vertnav.css" hash="48ed54348eefcc8e1e0286feb84cbe4e"/></dir></dir></dir></dir></target></contents>
16
<compatible/>
17
<dependencies/>
18
</package>
1
<?xml version="1.0"?>
2
<package>
3
<name>RicoNeitzel_VertNav</name>
4
+ <version>0.4.2</version>
5
<stability>stable</stability>
6
<license uri="http://opensource.org/licenses/osl-3.0.php">OSL v3.0</license>
7
<channel>community</channel>
8
<extends/>
9
<summary>Vertical Navigation - drop in replacement for the horizontal top navigation.</summary>
10
<description>Lots of css selectors available.</description>
11
+ <notes>New Portuguese Locale&#xD;
12
+ New Feature: css-class for categories that have children</notes>
13
+ <authors><author><name>Vinai Kopp</name><user>auto-converted</user><email>vinai@netzarbeiter.com</email></author><author><name>Rico Neitzel</name><user>auto-converted</user><email>rico@buro71a.de</email></author></authors>
14
+ <date>2012-10-29</date>
15
+ <time>11:17:33</time>
16
+ <contents><target name="magecommunity"><dir name="RicoNeitzel"><dir name="VertNav"><dir name="Block"><file name="Navigation.php" hash="db893358e07f9a92174710c11800ab0d"/></dir><dir name="Helper"><file name="Data.php" hash="a3995193a1ce5560edbd95e11720ce8b"/></dir><dir name="Model"><dir name="System"><dir name="Config"><dir name="Source"><file name="Root.php" hash="20696bf2dfef3e1092d7c08caf1dbc8e"/></dir></dir></dir></dir><dir name="etc"><file name="config.xml" hash="45a103c503a11e0c3685da28d34eb627"/><file name="system.xml" hash="4ae9f6be51baf3be807fab03f52625db"/></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="RicoNeitzel_VertNav.xml" hash="227d7980c24ebd629e1c1d4f10b8c62c"/></dir></target><target name="magelocale"><dir name="de_DE"><file name="RicoNeitzel_VertNav.csv" hash="d32b98f21146e2799b1dad8af8b57673"/></dir><dir name="es_MX"><file name="RicoNeitzel_VertNav.csv" hash="54b83643165bc5b72ca8ce2122fd5422"/></dir><dir name="pr_BR"><file name="RicoNeitzel_VertNav.csv" hash="73caa100514b6da6e311b1aaed889943"/></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="vertnav.xml" hash="57d3edf9bcf781eb7156d85173e4f3e8"/></dir><dir name="template"><dir name="vertnav"><file name="left.phtml" hash="e2f0d7e286ad1d3caadd4892fbb0671f"/></dir></dir></dir></dir><dir name="default"><dir name="default"><dir name="layout"><file name="vertnav.xml" hash="57d3edf9bcf781eb7156d85173e4f3e8"/></dir><dir name="template"><dir name="vertnav"><file name="left.phtml" hash="e2f0d7e286ad1d3caadd4892fbb0671f"/></dir></dir></dir></dir></dir></target><target name="mageskin"><dir name="frontend"><dir name="base"><dir name="default"><dir name="css"><file name="vertnav.css" hash="48ed54348eefcc8e1e0286feb84cbe4e"/></dir></dir></dir><dir name="default"><dir name="default"><dir name="css"><file name="vertnav.css" hash="48ed54348eefcc8e1e0286feb84cbe4e"/></dir></dir></dir></dir></target></contents>
17
<compatible/>
18
<dependencies/>
19
</package>