Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6202359
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T04:43:12+00:00 2026-05-24T04:43:12+00:00

I am trying to use the Dojo/Dijit declarative menu with Spring ROO 1.1.4, but

  • 0

I am trying to use the Dojo/Dijit declarative menu with Spring ROO 1.1.4, but even if I replace the complete roo generated menue.jspx with the example (ligthly addapted) from the Dojo/Dijit hompage, it does not replace the decorated menu divs with the menu.

that is how it look

how it look

that is how should look:

how shoul look

My modified menu.jspx

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<jsp:root xmlns:jsp="http://java.sun.com/JSP/Page"
    xmlns:menu="urn:jsptagdir:/WEB-INF/tags/menu"
    xmlns:sec="http://www.springframework.org/security/tags" 
    version="2.0">
    <jsp:directive.page contentType="text/html;charset=UTF-8" />
    <jsp:output omit-xml-declaration="yes" />

    <script type="text/javascript">
            dojo.require("dijit.MenuBar");
            dojo.require("dijit.PopupMenuBarItem");
            dojo.require("dijit.Menu");
            dojo.require("dijit.MenuItem");
            dojo.require("dijit.PopupMenuItem");
        </script>   
    </head>

        <div dojoType="dijit.MenuBar" id="navMenu">
            <div dojoType="dijit.PopupMenuBarItem">
                <span>
                    File
                </span>
                <div dojoType="dijit.Menu" id="fileMenu">
                    <div dojoType="dijit.MenuItem" onClick="alert('file 1')">
                        File #1
                    </div>
                    <div dojoType="dijit.MenuItem" onClick="alert('file 2')">
                        File #2
                    </div>
                </div>
            </div>
            <div dojoType="dijit.PopupMenuBarItem">
                <span>
                    Edit
                </span>
                <div dojoType="dijit.Menu" id="editMenu">
                    <div dojoType="dijit.MenuItem" onClick="alert('edit 1')">
                        Edit #1
                    </div>
                    <div dojoType="dijit.MenuItem" onClick="alert('edit 2')">
                        Edit #2
                    </div>
                </div>
            </div>
        </div>
</jsp:root>

Can anybody give me a hint what I am doing wrong?
(I know the fallback to do the menu programmatic, but I want to do it declarative.)


The html header is looks like that:

<head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=8" />    

    ...
    <script type="text/javascript">var djConfig = {parseOnLoad: false, isDebug: false, locale: '${fn:toLowerCase(userLocale)}'};</script>

    <script src="${dojo_url}" type="text/javascript"><!-- required for FF3 and Opera --></script>
    <script src="${spring_url}" type="text/javascript"><!-- /required for FF3 and Opera --></script>
    <script src="${spring_dojo_url}" type="text/javascript"><!-- required for FF3 and Opera --></script>
    <script language="JavaScript" type="text/javascript">dojo.require("dojo.parser");</script>      


    <spring:message code="application_name" var="app_name"/>
    <title><spring:message code="welcome_h3" arguments="${app_name}" /></title>
</head>
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T04:43:14+00:00Added an answer on May 24, 2026 at 4:43 am

    I don’t knows anything about Spring Roo, so maybe I’m saying something very stupid here…

    Is that menu.jspx compiling into some static html? If this is the case, you can tell Dojo to parse your initial page simply by setting parseOnLoad to true on your djConfig

    var djConfig = {parseOnLoad: true, ...}
    

    (no need to require dojo.parser in this case).

    On the other hand, if that template is inserted dinamicaly, you will need to call dojo.parser.parse() on the root ‘navMenu’ node yourself. You seem to be require-ing it, but I don’t see where it is being called.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm using spring-roo trying to use dojox.grid.DataGrid. The page renders as a plain table.
Hi I'm new to javascript and dojo. I'm trying to use two dijit DateTextBoxes
I'm trying to use Dojo dnd Source(1.4.2) to create an interface where I can
I'm desperately trying to use json data to fill my dojo spider chart. First
I am trying to use dojo.xhrGet to get some json back from a php
I am trying use filehelpers class builder but I am kinda confused on what
I'm trying to use Dojo to post to my server. The server is returning
I am trying to understand the difference between dijit.byId and dojo.byId For this i
I am trying to use the StoreSeries with Dojo in order to create charts.
I am trying to write my own Dojo/Dijit Editor Plugin. the only Information i

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.