<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Creating a routing-based menu in symfony 1.2, part 4: the full package</title>
	<atom:link href="http://blog.vworld.at/2009/04/06/creating-a-routing-based-menu-in-symfony-12-part-4-the-full-package/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.vworld.at/2009/04/06/creating-a-routing-based-menu-in-symfony-12-part-4-the-full-package/</link>
	<description>Software development and software quality</description>
	<lastBuildDate>Tue, 20 Sep 2011 20:50:32 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
	<item>
		<title>By: Gayatri</title>
		<link>http://blog.vworld.at/2009/04/06/creating-a-routing-based-menu-in-symfony-12-part-4-the-full-package/comment-page-1/#comment-9211</link>
		<dc:creator>Gayatri</dc:creator>
		<pubDate>Wed, 20 Apr 2011 11:51:30 +0000</pubDate>
		<guid isPermaLink="false">http://blog.vworld.at/?p=131#comment-9211</guid>
		<description>Will this work for cross application links in the menu? I suppose (from the code you&#039;ve posted), two instances of sfMenuBuilder will have to be created ...?</description>
		<content:encoded><![CDATA[<p>Will this work for cross application links in the menu? I suppose (from the code you&#8217;ve posted), two instances of sfMenuBuilder will have to be created &#8230;?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Gayatri</title>
		<link>http://blog.vworld.at/2009/04/06/creating-a-routing-based-menu-in-symfony-12-part-4-the-full-package/comment-page-1/#comment-9210</link>
		<dc:creator>Gayatri</dc:creator>
		<pubDate>Wed, 20 Apr 2011 11:30:24 +0000</pubDate>
		<guid isPermaLink="false">http://blog.vworld.at/?p=131#comment-9210</guid>
		<description>What&#039;s the name you&#039;re planning for the plugin?
Have you made it public yet? Can you give the github link?</description>
		<content:encoded><![CDATA[<p>What&#8217;s the name you&#8217;re planning for the plugin?<br />
Have you made it public yet? Can you give the github link?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Christian Ducrot</title>
		<link>http://blog.vworld.at/2009/04/06/creating-a-routing-based-menu-in-symfony-12-part-4-the-full-package/comment-page-1/#comment-9206</link>
		<dc:creator>Christian Ducrot</dc:creator>
		<pubDate>Tue, 05 Apr 2011 08:51:00 +0000</pubDate>
		<guid isPermaLink="false">http://blog.vworld.at/?p=131#comment-9206</guid>
		<description>I&#039;m looking forward to the github version of the menu system ;-)</description>
		<content:encoded><![CDATA[<p>I&#8217;m looking forward to the github version of the menu system <img src='http://blog.vworld.at/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>By: David</title>
		<link>http://blog.vworld.at/2009/04/06/creating-a-routing-based-menu-in-symfony-12-part-4-the-full-package/comment-page-1/#comment-9205</link>
		<dc:creator>David</dc:creator>
		<pubDate>Mon, 07 Mar 2011 11:19:48 +0000</pubDate>
		<guid isPermaLink="false">http://blog.vworld.at/?p=131#comment-9205</guid>
		<description>I&#039;ve been heavily modifying the menu system since it has been released here. It is now an sf1.4 compatible standalone plugin and even supports multiple menus in separate definition files (menu.yml), breadcrumb rendering, custom item classes and much more. I can&#039;t afford the time to re-publish it as a package, but I think I will upload the code to my github. Just give me something like 2 weeks and it will be public.</description>
		<content:encoded><![CDATA[<p>I&#8217;ve been heavily modifying the menu system since it has been released here. It is now an sf1.4 compatible standalone plugin and even supports multiple menus in separate definition files (menu.yml), breadcrumb rendering, custom item classes and much more. I can&#8217;t afford the time to re-publish it as a package, but I think I will upload the code to my github. Just give me something like 2 weeks and it will be public.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Christian Ducrot</title>
		<link>http://blog.vworld.at/2009/04/06/creating-a-routing-based-menu-in-symfony-12-part-4-the-full-package/comment-page-1/#comment-9204</link>
		<dc:creator>Christian Ducrot</dc:creator>
		<pubDate>Mon, 07 Mar 2011 09:59:32 +0000</pubDate>
		<guid isPermaLink="false">http://blog.vworld.at/?p=131#comment-9204</guid>
		<description>Great article. It&#039;s the only solution which supports &#039;alias_routes&#039;.
Any plans for making it symfony 1.4 ready?

For example there is an exception when you click on &quot;new&quot; in an admin generated form: 

Unable to find the sfGuardUserPeer object with the following parameters &quot;array ( &#039;sf_format&#039; =&gt; &#039;html&#039;,)&quot;).

stack trace:
1. at ()
in SF_ROOT_DIR/lib/vendor/symfony/lib/routing/sfObjectRoute.class.php line 111
2. t sfObjectRoute-&gt;getObject()
in SF_ROOT_DIR/apps/backend/modules/helper/lib/menu_builder/sfMenuBuilder.class.php line 77

I think the problem is that there is no object in the route at the time this form is generated.</description>
		<content:encoded><![CDATA[<p>Great article. It&#8217;s the only solution which supports &#8216;alias_routes&#8217;.<br />
Any plans for making it symfony 1.4 ready?</p>
<p>For example there is an exception when you click on &#8220;new&#8221; in an admin generated form: </p>
<p>Unable to find the sfGuardUserPeer object with the following parameters &#8220;array ( &#8216;sf_format&#8217; =&gt; &#8216;html&#8217;,)&#8221;).</p>
<p>stack trace:<br />
1. at ()<br />
in SF_ROOT_DIR/lib/vendor/symfony/lib/routing/sfObjectRoute.class.php line 111<br />
2. t sfObjectRoute-&gt;getObject()<br />
in SF_ROOT_DIR/apps/backend/modules/helper/lib/menu_builder/sfMenuBuilder.class.php line 77</p>
<p>I think the problem is that there is no object in the route at the time this form is generated.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tin Nguyen</title>
		<link>http://blog.vworld.at/2009/04/06/creating-a-routing-based-menu-in-symfony-12-part-4-the-full-package/comment-page-1/#comment-9186</link>
		<dc:creator>Tin Nguyen</dc:creator>
		<pubDate>Wed, 12 May 2010 03:23:52 +0000</pubDate>
		<guid isPermaLink="false">http://blog.vworld.at/?p=131#comment-9186</guid>
		<description>I have just look through your post about routing-based menu in symfony. May I ask you if your way support internationization. I mean menu&#039;s language could be changed with user. thanks by advanced.</description>
		<content:encoded><![CDATA[<p>I have just look through your post about routing-based menu in symfony. May I ask you if your way support internationization. I mean menu&#8217;s language could be changed with user. thanks by advanced.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sean</title>
		<link>http://blog.vworld.at/2009/04/06/creating-a-routing-based-menu-in-symfony-12-part-4-the-full-package/comment-page-1/#comment-4947</link>
		<dc:creator>Sean</dc:creator>
		<pubDate>Thu, 30 Jul 2009 16:13:38 +0000</pubDate>
		<guid isPermaLink="false">http://blog.vworld.at/?p=131#comment-4947</guid>
		<description>Hey, the sfMenuBuilder is still referred to as sfBuilder.

Fatal error: Class &#039;sfBuilder&#039; not found in .../apps/frontend/modules/main/actions/menuComponent.class.php on line 12</description>
		<content:encoded><![CDATA[<p>Hey, the sfMenuBuilder is still referred to as sfBuilder.</p>
<p>Fatal error: Class &#8216;sfBuilder&#8217; not found in &#8230;/apps/frontend/modules/main/actions/menuComponent.class.php on line 12</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: kevin</title>
		<link>http://blog.vworld.at/2009/04/06/creating-a-routing-based-menu-in-symfony-12-part-4-the-full-package/comment-page-1/#comment-4820</link>
		<dc:creator>kevin</dc:creator>
		<pubDate>Fri, 24 Jul 2009 11:28:46 +0000</pubDate>
		<guid isPermaLink="false">http://blog.vworld.at/?p=131#comment-4820</guid>
		<description>Sorry for the spam,
simple solution : forget about the myUser bit, and sick the content of the getMenu() function directly into the partial:

getRequest()-&gt;getAttribute(&#039;sf_route&#039;);

$routeName = sfContext::getInstance()-&gt;getRouting()-&gt;getCurrentRouteName();
$builder = sfMenuBuilder::initInstance(sfConfig::get(&#039;app_menu_items&#039;), $route, $routeName, &#039;default&#039;);
echo $builder-&gt;renderTree(); // echo $sf_user-&gt;getMenu();

what&#039;s with the myUser escape the html tags?</description>
		<content:encoded><![CDATA[<p>Sorry for the spam,<br />
simple solution : forget about the myUser bit, and sick the content of the getMenu() function directly into the partial:</p>
<p>getRequest()-&gt;getAttribute(&#8216;sf_route&#8217;);</p>
<p>$routeName = sfContext::getInstance()-&gt;getRouting()-&gt;getCurrentRouteName();<br />
$builder = sfMenuBuilder::initInstance(sfConfig::get(&#8216;app_menu_items&#8217;), $route, $routeName, &#8216;default&#8217;);<br />
echo $builder-&gt;renderTree(); // echo $sf_user-&gt;getMenu();</p>
<p>what&#8217;s with the myUser escape the html tags?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: kevin</title>
		<link>http://blog.vworld.at/2009/04/06/creating-a-routing-based-menu-in-symfony-12-part-4-the-full-package/comment-page-1/#comment-4819</link>
		<dc:creator>kevin</dc:creator>
		<pubDate>Fri, 24 Jul 2009 11:22:43 +0000</pubDate>
		<guid isPermaLink="false">http://blog.vworld.at/?p=131#comment-4819</guid>
		<description>Got it to work... more or less!
So for the REAL newbies like me :

mkdir -p apps/backend/lib/helper/
then move the content of &quot;lib&quot; from the archive to this directory.

Config files :
--- apps/backend/config/app.yml 
all:
  menu:
    items:
      submissions:
        title:   Submissions
      reports:
        title:   Reports
        children:
          reports:
            title:   Default report
          reports_summary:
            title:   Summary report
--- apps/backend/config/routing.yml 
# default rules
(...)

submissions:
  class: sfDoctrineRouteCollection
  options:
    model:                Submissions
    module:               submissions
    prefix_path:          submissions
    column:               id
    with_wildcard_routes: true

reports:
  url:   /reports
  param: { module: reports, action: index }
reports_summary:
  url:   /reports/summary
  param: { module: reports, action: summary }


Added a dummy function in myUser so i can get the menu anytime from anywhere in the app
--- apps/backend/lib/myUser.class.php
getRequest()-&gt;getAttribute(&#039;sf_route&#039;);

        $routeName = sfContext::getInstance()-&gt;getRouting()-&gt;getCurrentRouteName();
        $builder = sfMenuBuilder::initInstance(sfConfig::get(&#039;app_menu_items&#039;), $route, $routeName, &#039;default&#039;);
        return $builder-&gt;renderTree();
    }
}

Because i want this menu to be &quot;global&quot;
--- apps/backend/templates/_menu.php
getMenu(); ?&gt;

--- apps/backend/templates/layout.php
(...)

(...)

et voila! Well almost, i have an issue : the html is escaped so the menu is still unusable, any idea why? :&#124;</description>
		<content:encoded><![CDATA[<p>Got it to work&#8230; more or less!<br />
So for the REAL newbies like me :</p>
<p>mkdir -p apps/backend/lib/helper/<br />
then move the content of &#8220;lib&#8221; from the archive to this directory.</p>
<p>Config files :<br />
&#8212; apps/backend/config/app.yml<br />
all:<br />
  menu:<br />
    items:<br />
      submissions:<br />
        title:   Submissions<br />
      reports:<br />
        title:   Reports<br />
        children:<br />
          reports:<br />
            title:   Default report<br />
          reports_summary:<br />
            title:   Summary report<br />
&#8212; apps/backend/config/routing.yml<br />
# default rules<br />
(&#8230;)</p>
<p>submissions:<br />
  class: sfDoctrineRouteCollection<br />
  options:<br />
    model:                Submissions<br />
    module:               submissions<br />
    prefix_path:          submissions<br />
    column:               id<br />
    with_wildcard_routes: true</p>
<p>reports:<br />
  url:   /reports<br />
  param: { module: reports, action: index }<br />
reports_summary:<br />
  url:   /reports/summary<br />
  param: { module: reports, action: summary }</p>
<p>Added a dummy function in myUser so i can get the menu anytime from anywhere in the app<br />
&#8212; apps/backend/lib/myUser.class.php<br />
getRequest()-&gt;getAttribute(&#8216;sf_route&#8217;);</p>
<p>        $routeName = sfContext::getInstance()-&gt;getRouting()-&gt;getCurrentRouteName();<br />
        $builder = sfMenuBuilder::initInstance(sfConfig::get(&#8216;app_menu_items&#8217;), $route, $routeName, &#8216;default&#8217;);<br />
        return $builder-&gt;renderTree();<br />
    }<br />
}</p>
<p>Because i want this menu to be &#8220;global&#8221;<br />
&#8212; apps/backend/templates/_menu.php<br />
getMenu(); ?&gt;</p>
<p>&#8212; apps/backend/templates/layout.php<br />
(&#8230;)</p>
<p>(&#8230;)</p>
<p>et voila! Well almost, i have an issue : the html is escaped so the menu is still unusable, any idea why? <img src='http://blog.vworld.at/wp-includes/images/smilies/icon_neutral.gif' alt=':|' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>By: kevin</title>
		<link>http://blog.vworld.at/2009/04/06/creating-a-routing-based-menu-in-symfony-12-part-4-the-full-package/comment-page-1/#comment-4818</link>
		<dc:creator>kevin</dc:creator>
		<pubDate>Fri, 24 Jul 2009 10:56:43 +0000</pubDate>
		<guid isPermaLink="false">http://blog.vworld.at/?p=131#comment-4818</guid>
		<description>This is GREAT stuff,
but i&#039;m also newbie to symfony and could not get it to work just yet... because i don&#039;t where to put the files!

&quot;The structure is intended for the lib/ folder, the example.php file states how the code could be called – I’m doing this actually inside a helper (MenuHelper.php) in my app’s lib/helper folder.&quot;
-&gt; What&#039;s in MenuHelper.php exactly? confused there...

Anyway, imho this should definitely be a plugin for the community to use! :) so useful!</description>
		<content:encoded><![CDATA[<p>This is GREAT stuff,<br />
but i&#8217;m also newbie to symfony and could not get it to work just yet&#8230; because i don&#8217;t where to put the files!</p>
<p>&#8220;The structure is intended for the lib/ folder, the example.php file states how the code could be called – I’m doing this actually inside a helper (MenuHelper.php) in my app’s lib/helper folder.&#8221;<br />
-&gt; What&#8217;s in MenuHelper.php exactly? confused there&#8230;</p>
<p>Anyway, imho this should definitely be a plugin for the community to use! <img src='http://blog.vworld.at/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  so useful!</p>
]]></content:encoded>
	</item>
</channel>
</rss>

