简体   繁体   English

小型Web问答页面-JSP还是HTML? 1页还是几页?

[英]Small web Q&A page - JSP or HTML? 1 page or several?

I've been tasked with a small web flow. 我的工作量很小。 I need to ask a series of questions, then stop them or send them to a specified URL. 我需要提出一系列问题,然后停止它们或将其发送到指定的URL。 I envision each line below shown by itself: 我设想下面单独显示的每一行:

- Q1. -Q1。 If Yes goto URL, No goto Q2 如果是,请转到URL,否则请转到Q2
- Q2. -Q2。 If Yes goto URL, No goto Q3-7 如果是,请转到URL,否则请转到Q3-7
- Q3-7 Any Yes goto Stop page, all No goto Input page -Q3-7任意是转到停止页面,全部否转到输入页面
- Input customer name, Next -输入客户名称,下一步
- Print Preview - show all 7 Q&A, customer name and current date, let user print, then Next to final URL -打印预览-显示所有7个问答,客户名称和当前日期,让用户打印,然后显示在最终URL旁边

So my questions are, should I have each of these be a separate JSP pages with a Form carrying the answers as hidden? 所以我的问题是,是否应该让我每个人都是一个单独的JSP页面,并且表单中包含隐藏的答案? Or should I put them all on one HTML page, and hide/display the questions using JavaScript (it would only appear they are moving page to page)? 还是我应该将它们全部放在一个HTML页面上,然后使用JavaScript隐藏/显示问题(只会出现在页面之间移动)? Either way I'll use JavaScript to validate the questions. 无论哪种方式,我都将使用JavaScript来验证问题。

This is an internal-use only thing, and no data is saved. 这是仅供内部使用的内容,不会保存任何数据。 It will be hosted on a Tomcat server with other Java apps running, so JSP's are not a problem - I'm just wondering if its overkill. 它将托管在运行其他Java应用程序的Tomcat服务器上,因此JSP不是问题-我只是想知道它是否过大。

I'd approach this issue from a maintenance standpoint. 我将从维护的角度解决这个问题。 How often do you think there could be changes to the questions? 您认为问题多久可以更改一次? If your boss calls you in and wants to see every Q in the app, printing one HTML page would be easy enough for him/her to do themselves. 如果您的老板打来电话给您,并希望查看应用程序中的每个问题,那么打印一个HTML页面将很容易让他/她自己完成。

If there was no saving of data, I would go one with the one page approach to keep it simple and easy to manage. 如果没有保存数据,我将采用一页方法来使数据保持简单和易于管理。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM