Magento : Gestion des pages CMS sous forme d’arborescence

Une demande récurrente sur les projets Magento est de pouvoir gérer les pages de contenu de façon arborescente. En effet, avoir quelques pages « à plat » n’est pas très gênant mais dès qu’on atteint quelques dizaines de pages, il peut être utile d’organiser ses pages de façon hiérarchique pour s’y retrouver plus facilement. C’est là que l’extension Clever CMS (développée par mes soins) nous vient en aide et nous allons découvrir comment l’utiliser à travers ce billet.

Installation

Clever CMS est maintenant hébergé sur GitHub :

  1. Magento 1.6+ : https://github.com/jreinke/magento-clever-cms (branche master)
  2. Magento 1.4.x, 1.5.x : https://github.com/jreinke/magento-clever-cms/tree/1.2 (branche 1.2)

Principe de fonctionnement

L’extension Clever CMS ne supprime pas vos pages CMS existantes. Elle se contente de créer une table cms_page_tree pour le contenu et une table cms_page_permission pour les droits. La table de contenu sera initialisée avec la page d’accueil comme page de 1er niveau et l’ensemble des autres pages sous celle-ci,  en tant que pages de 2ème niveau donc. Une image valant mieux qu’un long discours, voici à quoi doit ressembler votre arborescence si vous avez installé l’extension sans avoir touché aux pages CMS présentes par défaut dans Magento :

Important : Clever CMS gère une arborescence par vue magasin. Ceci est un choix délibéré car dans la grande majorité des cas, nous utilisons une vue magasin par langue.

Gestion de contenu

Si on connait un peu Magento, on s’aperçoit qu’il y a déjà par défaut une gestion arborescente des catégories du catalogue. L’interface est plutôt intuitive et efficace grâce au glisser-déposer alors je me suis basé sur celle-ci pour la gestion des pages. Vous ne serez donc pas dérouté par l’expérience utilisateur puisque cela fonctionne exactement de la même façon.

Grâce au glisser-déposer vous pourrez :

  • déplacer une page ou une arborescence de pages (dans le scope de votre vue magasin),
  • trier vos pages.

Pour créer une page, il suffit de cliquer sur la page parente dans l’arborescence et de cliquer sur le bouton « Add Page ». Ensuite vous remplissez les informations de votre page comme vous le faisiez auparavant. Un seul champ a été ajouté, il s’agit de « Clé d’url » qui donne la possibilité de gérer manuellement l’url d’accès à votre page. La procédure est décrite dans la partie suivante.

Gestion des urls

Par défaut, si vous ne spécifiez pas de clé d’url explicitement, elle sera générée automatiquement depuis le champ « Nom ». L’url finale vers votre page CMS sera donc construite en concaténant chaque clé d’url depuis la page racine jusqu’à la page cible. Ce qui donne par exemple : http://www.maboutique.fr/faq/clever-cms/comment-ca-marche/ pour une page se trouvant dans « Home > FAQ > Clever CMS > Comment ça marche ? ».

Important : par défaut si vous changez une clé d’url, une redirection 301 sera créée pour que votre ancienne url pointe vers la nouvelle. Cette fonctionnalité peut être désactivée dans « Système > Configuration > Gestion de contenu > Clever CMS > Créer des redirections d’URL permanentes si celles-ci changent ».

Gestion des droits

Si vous le souhaitez, vous pouvez limiter l’accès de certaines pages à certains groupes utilisateurs. Par défaut l’option est désactivée mais pour l’activer il vous suffit de modifier la valeur dans « Système > Configuration > Gestion de contenu > Clever CMS > Activer la gestion des droits ». L’interface de gestion des droits est accessible depuis le menu « CMS > Pages > Gérer les droits » et se présente ainsi :

Important : Lors de la création d’une page, celle-ci est accessible par le groupe utilisateur NOT_LOGGED_IN mais par aucun des autres groupes, il faut donc modifier les droits en conséquence.

Compatibilité

L’extension Clever CMS a été testée et est compatible avec les versions de Magento suivantes : 1.4.x, 1.5.x et 1.6.x. Même si vos pages existantes ne sont ni supprimées ni modifiées, il est toujours plus prudent de faire une copie de sauvegarde de votre base de données avant l’installation.

Désinstallation

Si l’extension ne vous donnait pas entière satisfaction pour quelconque raison, il vous suffit de la désinstaller ou de la supprimer et vous retrouverez les pages que vous aviez dans Magento avant installation.

Conclusion

Clever CMS vous permet donc de gérer facilement votre arborescence de contenu et possède les principaux avantages suivants :

  • installation rapide et triviale,
  • interface intuitive grâce au glisser-déposer,
  • souplesse dans la gestion des urls,
  • gestion de droits sur les pages,
  • extension totalement gratuite.

Tout commentaire, retour d’expérience ou don est le bienvenu ;)

92 réponses à “Magento : Gestion des pages CMS sous forme d’arborescence”

  1. Dax Davis dit :

    Does this offer a way to have a menu on the frontend in the left navigation?

    • Johann Reinke dit :

      Currently, you can retrieve the tree in top navigation only. You’ll have to do it manually for the left column taking inspiration from _renderCmsMenuItemHtml() method of Clever_Catalog_Block_Navigation block class. BTW, it could be a good enhancement for the extension, I’ll think about it.

    • demijoh dit :

      It is possible. Copy top.phtml from app\design\frontend\default\clever\template\catalog\navigation to your theme (my is app\design\frontend\YOUR_COMPANY\YOUR_THEME\template\catalog\navigation) and rename it to cms-menu.phtml (we need original top.phtml for top menu links).
      Then you need add this code to some XML layout file:

      it depends on when you want show this menu. Put it on correct layout file and handler. I am displaying CMS menu only when user is viewing CMS page, so I put that XML block to cms.xml and inside the cms_page_view handler.

      I also comment out this line from cms-menu.phtml:
      $_menu = $this->renderCategoriesMenuHtmlClever(0, $_categoriesIsLast, true, ‘level-top’);
      because I want show only links to CMS pages not to shop categories (they are on original top.phtml)…

      And off course you must style this new menu.

      Sry for my English.

    • kiat dit :

      I also needed to have a menu but shows on the CMS parent page. I created a simple block for it. See http://pastebin.com/sm1S55Hk

      Example:

      faqs

      The identifier is the field *URL key* in *Page Information*. You also need to select *Yes* for *Include in Navigation Menu*. The example code is to be placed in *Layout Update XML* in the *Design* tab. Select *2 columns with left bar* in the *Layout* field to place the menu block in the left panel of your CMS page.

      To install:
      Create a file call Menu.php and copy paste the contents from pastebin. Place the file in app\code\community\JR\CleverCms\Block\Cms\Page\Menu.php

      Enjoy!

      • kiat dit :

        Example code:

        [reference name="left"]
        [block type="jr_clevercms/cms_page_menu" name="menu_left"]
        [action method="setIdentifier"][identifier]faqs[/identifier][/action]
        [/block]
        [/reference]

        replace [ ] to

  2. dakini dit :

    Absolutely great extension. Love it. thanks very much for that.

  3. Andreas dit :

    Very nice work! I have one question though. What are the reasons you providing your own adminhtml override ?
    \app\design\adminhtml\default\clever\
    \skin\adminhtml\default\clever

    We’are already overriding the admin files ourselves because we wanted to change the layout, images, css etc. We unfortunately have to copy all those changes over to the ‘clever’ catalog as well. Do you have any ideas of how we could avoid that?

    Best regards!

  4. rami dit :

    Thanks for the extension!
    When cache is ON, the active class in the menu doesnt move to the active page link.

  5. Eric dit :

    Is there a way to list subpages on a parent page?
    Thanks for a great extension!

    • Johann Reinke dit :

      You can easily retrieve children pages of a page with $page->getChildren()

      • Jakob dit :

        hi johann! thx allot for this…but i still have problems to retrieve the deeper levels in the navigation with your template…how has to look the whole code in the template if i want to show level0 –> level1 –> level2 ?

        thx
        jakob

  6. Mangouste dit :

    Hello,
    I would like to retrieve the pages already on my site and put these into tabs clever I would follow the march thank you

  7. Franco dit :

    Hi there,

    After installing clever cms looks like I’ve lost redirection to 404 custom pages. The pages are still in admin and still reachable frontend if I type http://www.mystore.com/en/no-route but when I type an incorrect url I get the message « There was no 404 CMS page configured or found. »

    Default web values are:

    Default Web URL cms
    CMS Home Page Home
    Default No-route URL cms/index/noRoute
    CMS No Route Page Page not found

    Any ideas why?
    Thanks

    • Miriam dit :

      Hi, I got the same problem. Did you find a solution for the missing 404 Page?

      Thanks

      • Chrish dit :

        I’m also wondering about the 404 issue – I’ve re/checked my config settings for the 404 page and all seems correct…

        This is also resulting in the following error:

        Warning: in_array() expects parameter 2 to be array, null given in /app/code/community/JR/CleverCms/Helper/Cms/Page.php on line 19

  8. Super boulot !
    Nous applaudissons en interne !

  9. We recently installed your plug in on a client’s site. The plug in works on the back end, however for some reason the custom index page we designed is now gone.

    The content doesn’t show at all.

    Has anyone else had this problem? What could be causing this????

  10. sietze dit :

    Great plugin!
    Thanks for sharing.. this saved me a lot of time..

  11. GLOKAL dit :

    How can I manage cms pages in more languages?

  12. geed dit :

    Wonderful extension, really great work, thank you!
    Only thing that dos not work is: the link to the home page does not appear in top navigation. All other links to the activated cms pages are displayed except home link :( The setting option in the backend « Include in Navigation Menu » is showing « yes » and the select field is grey/deactivated. Where is my mistake? Thank you very much for your help.

  13. Igor dit :

    How can I generate automatically url for russian language ?

    • Johann Reinke dit :

      I don’t know sorry. Url key is generated like Magento does for categories:
      $str = Mage::helper(‘core’)->removeAccents($identifier); // $identifier is cms page identifier
      $urlKey = preg_replace(‘#[^0-9a-z]+#i’, ‘-‘, $str);
      $urlKey = strtolower($urlKey);
      $urlKey = trim($urlKey, ‘-‘);

      Any suggestion is welcomed.

  14. Liam Potter dit :

    Hi Johann, first of thanks for this extension, works really well.

    Now onto my problem, I’ve put the navigation in the left sidebar on my design, but what I’m trying to do is have it only display sub pages of the currently active page. For example, if I goto the About Us page on the left I want the navigation to show only the subpage of About Us.

    I managed to modify Navigation.php to show only child pages but that was showing all the child pages, not just for the current page, so I undid that.

    I would appreciate any help or advice you can give.
    Thanks.

  15. Calvin Muller dit :

    I am unable to get the menu navigation to display in Magento 1.7.0.0

    is there any special technique to this?

    I even overrode the default top.phtml with the one given but still no menu item’s visible.

    Thanks.

  16. Guo dit :

    I have the below error when I install it anyone got any idea how to solve this?

    Invalid method Netzarbeiter_GroupsCatalog_Block_Navigation::renderCategoriesMenuHtmlClever(Array
    (
    [0] => 0
    [1] => 1
    [2] => 1
    [3] => level-top
    )
    )

    • Johann Reinke dit :

      Sorry I don’t know the module Netzarbeiter_GroupsCatalog but it seems to override the same block class as mine and take the priority. You have to solve this conflict manually.

  17. Nils dit :

    Hi!,

    Recently installed your module on 1.6 and everything was fine. Now, in Backend, the left panel is not loading anymore. In fact, i think no files from /clever/ are loaded at all in adminhtml.

    Do you know what could be wrong?

  18. Geert dit :

    First of all, nice work!!! But, it would be cool if we could disable the editor.

  19. Diana dit :

    Excelent extension and nice work! You saved me lots of time, so I thank you.

  20. Taunais dit :

    En y regardant de plus près, c’est trois tables qui sont crées si je ne me trompe pas.
    cms_page_tree_store
    cms_page_tree
    cms_page_permission

    Bon job en tout cas

  21. Baoutch dit :

    This is excellent,
    C’est excellent.

    Mais malheureusement nous rencontrons quelques problèmes sur la version 1.7 de Magento. La page 404 semble devenir inexistante lorsque le module est activé et toutes les urls fausses sont re-routées sur la homepage.

    Nous avons alors voulu désactiver le module et là manque de bol toutes les pages créés lorsque le module est activé ont disparu et on retrouve les pages d’origine magento.

    Voili voilou et merci tout de même parce qu’une fois au point ce module sera sans aucun doute indispensable.

  22. Baoutch dit :

    LA BOULETTE
    En fait c’est DEJA une extension indispensable. Il fallait reconfigurer la 404 dans la partie Système -> Configuration -> Web -> Default pages

    Je ne peux effacer mon com précédent mais le coeur y est.

    MERCI pour l’extension!

    • Ccile dit :

      @baoutch en espérant que tu repasses par là, sinon les autres…:

      j’ai le même pb que toi sur les erreurs 404 mais je n’arrive pas à la reconfigurer. Peux-tu m’indiquer l’URL Key de ta page CMS « 404 not found » et ce que tu as mis dans les champs de Système > configuration > web > Default page ?

      Par avance merci.

      Ccile

  23. Ccile dit :

    Bonjour,

    j’ai installé l’extension; elle est très bien pour ce que je souhaite faire.

    Cependant je me heurte à un petit problème (bug ou incompréhension de ma part ?):

    Tant que je n’active pas la gestion des droits, tout marche à merveille. Si j’active la gestion des droits, Magento n’arrive pas à trouver ma page cms 404 Not found (bien que celle-ci existe). Je désactive la gestion des droit: elle réapparaît.

    Une idée ?

    Merci

    Ccile

  24. Yuriy dit :

    You save me saveral days of my live !!
    Especial respect for github repo – magento connect must die :-)

  25. Detlev dit :

    Your extension ist really great! Thank you so much. I’m using Magento 1.7 with clever 1.2.1, but I won’t get the CMS-navigation included in the top-navigation (I bet you are aware of this issue).

    There is a new version on github but I did not get it to work. Even though I installed modgit (with obstacles due to openSSL-Server certificate problems). Your new version has a different folder structure and Magento does not understand, that it ist installed. The installation with modgit had problems with Magento-folder structure in general.

    So please put the latest version on magentocommerce. And you people out there donate some bucks for this guy (I did). He earns it.

    • Johann Reinke dit :

      Hi!
      I can tell you that CleverCms v2 is compatible with Magento 1.7, I am currently using it (installed with modgit).
      I won’t use Magento Connect anymore because of heavy update procedures and approvals.

      Thanks for the donation ;)

      • Detlev dit :

        Hi Johann,
        Yes, I suppose, that CleverCms is compatible, since you mentioned it on github. So what am I doing wrong:
        1. Uninstall Version 1.2 using MagentoConnectManager.
        2. Now I get an Error: Invalid method Mage_Catalog_Block_Navigation::renderCmsMenuHtml (that’s OK, I’m using the clever Theme, that uses the Clever Methods. And those are not available, after uninstall)
        3. Go to the console in the Magento directory and enter the stuff I got here: https://github.com/jreinke/magento-clever-cms#magento-ce-16
        4. modgit init throws: Could not create .modgit directory – thats OK, because I tried this before and the .modgit directory already exists.
        5. modgit clone … throws: A module with this name has already been cloned. – That’s OK too, because modgit is right. I tried this before.
        6. Change the clever-Theme to default-Theme (to remove the error)
        7. There is no cleverCms neither in the frontend nore in the backend.
        But I need it – it is so good – what am I supposed to do?
        Thanks for any help
        Detlev

        • Johann Reinke dit :

          You should try a modgit remove before cloning again.

          • Detlev dit :

            Hi Johann,
            now it works – thank you!
            I removed the whole Magento, deleted the database and reinstalled Magento and the german language pack. Then I modgit-installed clever-cms and I saw nothing. Then I changed the theme to « clever » and everything was fine :-)
            I bet it was not necessary to delete the whole Magento, changing the theme solved the problem.
            Great work!

  26. Max dit :

    i can confirm it works on my Magento CE 1.7 install (no SSL).
    all i did was download the zip (v 2.1.5 ?) from github, unpacked, put files in proper places (i even localised the fr_FR csv file), and it worked.
    just bare in mind to select if you want your pages to show or not in the navigation menu.
    great work!
    p.s. any chance for hints on how to extend it to specify customers IDs in addition to groups?

  27. Adam dit :

    Loving the extension, first time magento user, was surprised I couldn’t create sub-pages as standard, so very happy to find your work.

    I have notice though that pages created in the cms since installing the extension aren’t adding the pagetitle to the page as an h1 by default anymore, there a setting I’ve missed?

  28. Carlos dit :

    Congratulations for the extension Johann! I’m using it on Magento CE 1.7 and it’s working properly.

    Is there a way to show an option in the menu for the home page?

  29. Stephan dit :

    Hi there.

    I had the same problem like Eric, that my frontpage is gone. Now I can change in System > Configuration > Web > Default Pages what ever I want nothing happens.

    Whats wrong? Thanks a lot.

  30. Stephan dit :

    forgot something: I can change the content of « Home » but my frontpage is still empty.mysite.com/home shwos my old homepage. The first-link « Home Page » of cms-menu block goes to mysite.com/home. Version is 1.6.2.0. Thank you for a hint.

  31. Aurelien dit :

    hello
    there are things I do not understand
    I create a page in « all store views » scope, linking it with all store views in the form
    It creates in DB 1 row for page (with store_id = 0) and the right « page-store » links
    but when I switch to a specific store view scope, all my pages disappear in the tree…

  32. Fergus dit :

    Hi there,

    Looks like a very interesting extension, providing some must-have functionality that for some reason is not present in the standard build.

    The features list of v2 on github mentions frontend navigation, but I can’t find any info anywhere on how that works/looks. Is there something somewhere that has that information?

    Thanks.

  33. Bren dit :

    Hi Johann! Greeeeeeat extension. I’m using it in a Magento store we’re about to launch. I’ve just struck one issue though. The client needs an extra content area on each page – which I’ve managed to add using the instructions at http://www.atwix.com/magento/adding-custom-attribute-to-a-cms-page/. The only issue I have now is that because your extension uses a different table, the data is not being saved to the right place! If I add data to my new custom_content field in the database it shows up both in the admin AND in the front end just fine – but I cannot change/edit it as the code they’ve provided writes to the standard table. Can you see any way I can adjust their code to work with your new tables?

    I have contacted them via comments and a direct contact on their contact form but haven’t had any joy thus far – and we’re getting pretty close to launch!

    any thoughts?

  34. Eric dit :

    Johann,

    Thanks for this great extension! It does exactly what I want except for SEO reasons I’d like the URLs of children pages to not change.
    So rather than shop-url/page1/page2 I want it to stay shop-url/page2

    Can you help me with that?

    Thanks,
    Eric

  35. Eric dit :

    Please ignore my previous question. I had to uninstall the extension because it messed up a premium theme on one of my multi stores.

  36. Rudi dit :

    Great extension – thanks for making this available!

    Question: we have some 350 CMS pages, neatly organized in a tree with CleverCMS.
    Now we want to copy the entire tree with pages to a new store view.
    Is there a way to do this (now it seems like we need to copy the ‘flat’ CMS pages and re-establish the tree structure in the new store view – which is a lot of manual work).

    Your assistance would be appreciated.

    • Johann Reinke dit :

      Hi

      Hmm not an easy task.
      I think you have to write a shell script that take the root page of your source store, then make a recursion on getChildren(), change the store_id, update the parent_id, clear the path, and save.
      Should be something like that :)

  37. Nevil dit :

    How do I uninstall? I have some problems with an other plugin (Mageparts CMS). The extra tabs that have been added to editting a content page are now gone because of installing your plugin. Can you help me please?

    • Johann Reinke dit :

      You have different ways to uninstall it:
      – « modgit remove » if you used modgit during installation
      – or disable the extension in app/etc/modules/JR_CleverCms.xml
      – or remove all files that belongs to CleverCms (you have the list here: https://github.com/jreinke/magento-clever-cms)

      • i_am dit :

        Hi.
        After, I remove all files that belongs to CleverCms:
        a:5:{i:0;s:115: »Invalid method Mage_Page_Block_Html_Topmenu::renderCategoriesMenuHtml(Array
        (
        [0] => 0
        [1] => level-top
        )
        ) »;i:1;s:4344: »#0 /public_html/work/app/design/frontend/base/default/template/catalog/navigation/top.phtml(42): Varien_Object->__call(‘renderCategorie…’, Array)
        #1 /public_html/work/app/design/frontend/base/default/template/catalog/navigation/top.phtml(42): Mage_Page_Block_Html_Topmenu->renderCategoriesMenuHtml(0, ‘level-top’)
        #2 /public_html/work/app/code/core/Mage/Core/Block/Template.php(241): include(‘/pu…’)
        #3 /public_html/work/app/code/core/Mage/Core/Block/Template.php(272): Mage_Core_Block_Template->fetchView(‘frontend/base/d…’)
        #4 /public_html/work/app/code/core/Mage/Core/Block/Template.php(286): Mage_Core_Block_Template->renderView()
        #5 /public_html/work/app/code/core/Mage/Core/Block/Abstract.php(863): Mage_Core_Block_Template->_toHtml()
        #6 /public_html/work/app/code/core/Mage/Core/Block/Text/List.php(43): Mage_Core_Block_Abstract->toHtml()
        #7 /public_html/work/app/code/core/Mage/Core/Block/Abstract.php(863): Mage_Core_Block_Text_List->_toHtml()
        #8 /public_html/work/app/code/core/Mage/Core/Block/Abstract.php(582): Mage_Core_Block_Abstract->toHtml()
        #9 /public_html/work/app/code/core/Mage/Core/Block/Abstract.php(526): Mage_Core_Block_Abstract->_getChildHtml(‘topMenu’, true)
        #10 /public_html/work/app/design/frontend/default/entermd/template/page/html/header.phtml(11): Mage_Core_Block_Abstract->getChildHtml(‘topMenu’)
        #11 /public_html/work/app/code/core/Mage/Core/Block/Template.php(241): include(‘/pu…’)
        #12 /public_html/work/app/code/core/Mage/Core/Block/Template.php(272): Mage_Core_Block_Template->fetchView(‘frontend/defaul…’)
        #13 /public_html/work/app/code/core/Mage/Core/Block/Template.php(286): Mage_Core_Block_Template->renderView()
        #14 /public_html/work/app/code/core/Mage/Core/Block/Abstract.php(863): Mage_Core_Block_Template->_toHtml()
        #15 /public_html/work/app/code/core/Mage/Core/Block/Abstract.php(582): Mage_Core_Block_Abstract->toHtml()
        #16 /public_html/work/app/code/core/Mage/Core/Block/Abstract.php(526): Mage_Core_Block_Abstract->_getChildHtml(‘header’, true)
        #17 /public_html/work/app/design/frontend/default/entermd/template/page/2columns-right.phtml(16): Mage_Core_Block_Abstract->getChildHtml(‘header’)
        #18 /public_html/work/app/code/core/Mage/Core/Block/Template.php(241): include(‘/pu…’)
        #19 /public_html/work/app/code/core/Mage/Core/Block/Template.php(272): Mage_Core_Block_Template->fetchView(‘frontend/defaul…’)
        #20 /public_html/work/app/code/core/Mage/Core/Block/Template.php(286): Mage_Core_Block_Template->renderView()
        #21 /public_html/work/app/code/core/Mage/Core/Block/Abstract.php(863): Mage_Core_Block_Template->_toHtml()
        #22 /public_html/work/app/code/core/Mage/Core/Model/Layout.php(555): Mage_Core_Block_Abstract->toHtml()
        #23 /public_html/work/app/code/core/Mage/Core/Controller/Varien/Action.php(390): Mage_Core_Model_Layout->getOutput()
        #24 /public_html/work/app/code/core/Mage/Cms/Helper/Page.php(137): Mage_Core_Controller_Varien_Action->renderLayout()
        #25 /public_html/work/app/code/core/Mage/Cms/Helper/Page.php(52): Mage_Cms_Helper_Page->_renderPage(Object(Mage_Cms_IndexController), ‘1’)
        #26 /public_html/work/app/code/core/Mage/Cms/controllers/IndexController.php(45): Mage_Cms_Helper_Page->renderPage(Object(Mage_Cms_IndexController), ‘1’)
        #27 /public_html/work/app/code/core/Mage/Core/Controller/Varien/Action.php(419): Mage_Cms_IndexController->indexAction()
        #28 /public_html/work/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(250): Mage_Core_Controller_Varien_Action->dispatch(‘index’)
        #29 /public_html/work/app/code/core/Mage/Core/Controller/Varien/Front.php(176): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
        #30 /public_html/work/app/code/core/Mage/Core/Model/App.php(354): Mage_Core_Controller_Varien_Front->dispatch()
        #31 /public_html/work/app/Mage.php(683): Mage_Core_Model_App->run(Array)
        #32 /public_html/work/index.php(87): Mage::run( », ‘store’)
        #33 {main} »;s:3: »url »;s:1: »/ »;s:11: »script_name »;s:10: »/index.php »;s:4: »skin »;s:2: »en »;}

  38. Andrew dit :

    I’m new to Magento and installed your extension. I have the page menu displayed in the left sidebar, however it shows all pages under Home as well as at the top level.

    How can i remove the pages from being subs of the home?

    • Johann Reinke dit :

      You can define a different homepage in Magento configuration. This will allow you to specify any cms page as home page, you will be able to organize the tree as you wish.

  39. Bo Dudek dit :

    Hi

    After installing and using the extension for a period in a multistore setup together with the Aitoc Advanced Permissions v2.3.9, I’ve not got some issues.

    When I log into the Magento as administrator, I can see all pages no matter what store I am editing – works like a charm.

    But if I log in as a store owner (still in Magento) I can in general see my store content, but under the CMS > Pages the page either changes to my Dashboard or shows me the Dashboard including the menu in the content-area – so I have to top + navigation + content.

    I’ve tried to uninstall the Clever CMS extension completely to go back, and this works.. but then I loose all of my created pages.

    Suggestions?

    Bo Dudek
    Webdeveloper
    Denmark

  40. Judder dit :

    Quick question – I’m trying to build my own navigation block for my CMS pages however as block type core/template, all CMS functions are returning NULL

    For example: $this->getCurrentCmsPage();

    Should I be using cms/page or cms/block as the block type instead to try and get this information?

    Many thanks!

    • Judder dit :

      FYI core/template is correct, you have to use Mage::getSingleton(‘cms/page’) to get the page to work with it.

      For example: $pageChildren = Mage::getSingleton(‘cms/page’)->getChildren();

  41. Jagesh dit :

    How to show specific child tree as a menu?

    for eg: i want to show specific cms child tree
    Home (29)
    -Privacy Policy (0)
    -404 Not Found 1 (0)
    -Hardwood Artisans (0)
    –hardwood1
    –hardwood2
    —hardwood21
    —hardwood22
    –hardwood3
    i want to show only Hardwood Artisans (0) childs tree without parent.
    Please advice

  42. Mai Tran dit :

    Is there any similar method to organize static block in tree structure. Thanks

  43. Luke dit :

    I have to say i’ve stumbled on a gold mine with this blog, so many great posts! I’ve just installed the extension and was wondering if you have any plans to release an update with the same permissions structure for static blocks as this would be really handy for a variety of reasons for those operating both wholesale and retail from the same shop as i’m sure it would be for a wide variety of applications.

  44. Tom dit :

    dear Johann,
    thank you very much for the beautiful extension. I have installed it in magento 1.7.0.2. it works like a charm in the admin interface. but going to the website, it just takes away even my existing navigation. your help would be highly appreciated.
    thank you

  45. Jagesh dit :

    Hi
    Is it possible toshow specific tree structure
    for eg:

    cmspage1
    –cmssubpage1_1
    –cmssubpage1_2
    –cmssubpage1_3
    cmspage2
    –cmssubpage2_1
    –cmssubpage2_2
    –cmssubpage2_3

    i want to show cmapage1 for one theme and i want to show cmspage2 for another theme.
    i dont want to show both at a time or in a same theme.
    Please advice

  46. Adam dit :

    Hello Johann,

    thx for your great work, i like the clever cms a lot and I’m using it already in one shop. For another project i’m using Magento Version 1.7.0.2. Is your extension working for this version? On github there is no download for 1.7*

    I’ve already tried another version and it works in the backend, however i did not managed to show up cms-page in the header-navigation and i excactly did the same like in the other shop. Please answer

    Cheers and best regards from Germany

  47. Ollie dit :

    Hey Johann

    Can you currently suggest whether there is a method of calling up only a particular subtree (I have the pages structured in the left menu but the secondary level are currently sit below ALL top level pages)?

    Say only showing Menu 2 when the tree structure is as:

    – Menu 1
    — Submenu 1
    – Menu 2
    — Submenu 2
    — Submenu 2.1
    – Menu 3

    Cheers in advance

    OJ

  48. Nad dit :

    Hello,
    Ce module est super, cette possibilité de hirarchiser son contenu devrait faire partie des fonctionnalités de bases de magento.
    Cependant je rencontre un petit soucis avec mon second magasin, qui avait ses pages propres et également des pages communes avec le premier. Plus aucune page de ce magasin n’est visible ni dans l’admin, ni en front-end? Est-ce prévu? Il y a-t-il une solution? Que puis-je faire? Merci.

  49. Leon dit :

    We have Clever 2.1.2 and it is not compatible with latest 1.9.2.2 version. We cant change content in the backend. How can we solve this? Do we need to upgrade?

  50. Federico dit :

    To get separates cms tree change the file: app/code/local/Bubble/CmsTree/Block/Widget/Page/Children.php

    protected function _toHtml() {
    if (!$this->getPage()->getId()) {
    return  »;
    }

    $activePages = $this->getPage()->getChildren()->addActiveFilter();
    $activePagesCount = $activePages->count();

    Replace:
    protected function _toHtml() {
    if (!$this->getPage()->getId()) {
    return  »;
    }

    $currentUrl = Mage::helper(‘core/url’)->getCurrentUrl();
    $url = Mage::getSingleton(‘core/url’)->parseUrl($currentUrl);
    $aux = explode(‘/’, $url->getPath());
    if (reset(explode(‘/’, $this->_page->getIdentifier())) != $aux[2]) {
    return  »;
    }

    $activePages = $this->getPage()->getChildren()->addActiveFilter();
    $activePagesCount = $activePages->count();

Laisser un commentaire

* Champs requis

Categories