This week's book giveaway is in the Server-Side JavaScript and NodeJS forum.
We're giving away four copies of Node.js Design Patterns: Design and implement production-grade Node.js applications using proven patterns and techniques and have Mario Casciaro & Luciano Mammino on-line!
See this thread for details.
Win a copy of Node.js Design Patterns: Design and implement production-grade Node.js applications using proven patterns and techniques this week in the Server-Side JavaScript and NodeJS forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Rob Spoor
  • Tim Cooke
  • Junilu Lacar
Sheriffs:
  • Henry Wong
  • Liutauras Vilda
  • Jeanne Boyarsky
Saloon Keepers:
  • Jesse Silverman
  • Tim Holloway
  • Stephan van Hulst
  • Tim Moores
  • Carey Brown
Bartenders:
  • Al Hobbs
  • Mikalai Zaikin
  • Piet Souris

Add a new page

 
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I would add a new page in JForum but I don't understand the mechanism that lies behind the link, for exmple how is "${contextPath}/${moduleName}/permissions/${node.id}${extension}" formed?
I have to add a page, what are the files I have to modify?
Thanks, bye bye.
[originally posted on jforum.net by abdujaparov]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I don't understand how JForum link a page. In my case I have to add a page in the group management of JForum.
I have added this line into the templatesMapping.properties:



Then I inseted into TemplateKeys.java this line:


Then I have inserted into the GroupAction.java this method:


And then I created the page group_import_user.htm:


So I would that when I clink on the link defined in group_list.htm in this way:


JForum opens the group_import_user.htm an shows me Hello.

But I receive this error:


The link generated by JForum is: Importa utenti /jforum/adminGroups/importUser/X.page
where X is the number of the line of the group.

Please could someone help me?
Thanks, bye bye.
[originally posted on jforum.net by abdujaparov]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
FWIW, the error about a class cast exception is coming from a know bug in the error handling code. See:

https://coderanch.com/t/578221 #19661

That said, I think that you need to add the group_id parameter definition to the urlPattern.properties file. E.g.,

adminGroups.insertUser.1 = group_id

This file maps the parameter locations to the tags used to get the parameter.. e.g. getIntParameter("group_id").

In the dimm past, jforumURLs used to be a single servlet URL with query strings instead of a .page mapping. E.g.,
/jforum?module=groups&action=insertUser&group_id=1. There is still some legacy code that uses this format. So the urlPattern file maps positional parameters into "named" query parameters so both forms work.
[originally posted on jforum.net by monroe]
reply
    Bookmark Topic Watch Topic
  • New Topic