Saving User Input in a JBoss Seam Web Project web page - jsf

I have a question for any JBoss Seam developers out there:
I am creating a web project using JBoss Seam by generating entities and reverse-engineering code from existing database tables. This is my first time developing a web app in JBoss/Java/JSF, being an old school .NET web developer from years ago.
How do I save user input in text controls, so that it stays on the web page after a page refresh? I used to use Viewstate or Sessionstate in .NET, not sure what the equivalent of this would be in Java/JSF. Someone mentioned using java beans, but not sure how to do that, and Googling produces little help.
Any comments much appreciated, thanks.

Rather than going through the steps required here, it might be easier for you to go through the Seam tutorial, which will give you the basics. You can then clarify things here afterwards:
http://docs.jboss.org/seam/latest/reference/en-US/html/tutorial.html#registration-example

Related

Need help learning Liferay 7 MVC

Are there any basic tutorials for creating my first liferay 7 portlet like a Hello World App?
I am new to Liferay and need some help getting started. I have read over the liferay 7 tutorials and I have tried following the Liferay 7 Creating An MVC Portlet, but having trouble understanding where everything goes and how it all works together, and I feel that it is not a comprehensive tutorial.
About Me and My Liferay Aspirations:
I have experience with JAVA, JavaScript and Node.js.
I'd eventually like to be able to display a google map and display content on it, but just want to make some baby steps understanding portlets. Correct me if a portlet is not the right thing for me to be focusing on for this goal.
There is an excellent book "Liferay in Action". It helpls a lot, but there are a lot of mistakes in code. On the other hand, there is "Portlet in action", but it doesn't have free pdf-version :\
Also, you can visit web.liferay.com, I don't like this forum but there are good questions from time to time.
And any other issues you can only google, google and google again. Unfortunately, there is no alternative way.
The tutorials are not going to give you all the details, because they must be as short as possible. That said, the Creating an MVC Portlet tutorial should get you pretty well on your way. Which parts, specifically, are you having trouble understanding?
Have you read the Liferay MVC Portlet introductory tutorial? It's even sparser on details but it might fill in a few gaps.
If you are first time developing using liferay then this link might help you. It is guide to liferay 6.2. Creating plugin portlets is same in liferay 6.2 and 7. Just setup is different.
For creating liferay modules refer liferay 7 documentation.

Lotus Notes Application, Web Based Converting

Does anyone have tips or an ebook that can give me a good foundation on how to create applications in lotus notes using web browsers instead of clients. Links or tips are much appreciated.
Thanks!
Books are a good starter. But you'll find there is alot more to it than you see in books. So, here is a quick list of places to look.
Books
You've got these options for books (all downloadable as eBooks to)
Classic Web development prior to Notes 8.5 -- Reviews here and here
Latest Web stuff with Xpages if you have Notes 8.5+ (kindle/paper)
There are IBM wiki's (html). But have found the IBM wiki experience underwhelming. (The adjectives "half-ar$ed" and "piece-meal" comes to mind alot when reading these.)
IBM's redbook site (pdf/html) has better produced content than the wiki's.
Sites
One of the best web development tip/technique sites for the trickier problems is codestore.net and nsftools.com
OpenNtf a well used site for free code and solutions written by alot of smart people.
Quite a few good bloggers have "coagulated" on planetLotus
Try Searching for XPages in Google. Or start here
If you enable http on the server, you should be able to see your domino applications from the web. You then need to modify them to make them a bit more web friendly. The basic technique for this is to have 2 design elements with the same alias, hide one from notes and the other from the web. This will make it a bit easier to make it functional from both the client and the web browser.
Other functionality which makes this a bit easier would be 'Pass through HTML', the Domino CGI Variables and the 'WebQueryOpen' and 'WebQuerySave' events. As Jasper points out, XPages is the new sparkling way to do this, but it might not be an option for existing systems (It requires the latest version of Domino server). Good Luck!
What version of Domino are you running? If it's an 8.5 variant, I would suggest you use XPages to bring your old client apps to the web (XPages are not an option in releases prior to 8.5).
As to how you go about this, that's well beyond the scope of an answer on Stack Overflow: it's a book in and of itself! To learn about web development with XPages, I suggest visiting some of the well-known sites out there, and perhaps picking up a course or two. Here are some links:
http://xpages101.net
http://www.qtzar.com/blogs/qtzar.nsf/htdocs/LearningXPages.htm
http://notesin9.com/
(Also, IBM publish a book on XPages development, although I've not read it).
With regards "classic" Domino development, your best bet is to view your existing Notes app in a web browser and then start hacking on the default HTML generated (which is nasty). The best single resource out there for classic Domino web development tips and hacks is Jake Howlett's Codestore
Start small, build yourself a small database with a subset of data and explore what you can do. I've been a notes client developer for 10+ years and doing domino web work for last three or four years and still on steep learning curve. Its a very powerful platform but you also need to know html as on many occasions the html that you see in the browser helped me pin down the faults in my application code.

Is JSF2 usable in concert with the "Snaps" web UI framework based on Eclipse Virgo?

Snaps is a (rather new) web framework growing out of the Eclipse Virgo community that (will) allow dynamic, componentized web UIs by exploiting the OSGi infrastructure. Apparently it is the heir of "Slices", the previous attempt at this.
What I am wondering is whether there is any work ongoing in looking at how JSF (2) can be combined with such an approach? Is this at all possible? If so, is there any concrete work ongoing?
There is no work going on looking at JSF specifically or any other Web framework for that matter. Snaps aims to give you the dynamic runtime ability to compose your web app without restricting your choice of web framework in any way. It definitely doesn't aim to be another web framework.
I know some people have had JSF running on Virgo so I don't see any reason that you can't use it with snaps although I haven't tried it so I can't say for certain. If you do find a problem raise a bug on the Virgo project :)
Chris.
In case you're still interested:
At the Virgo formus I know there is some guy who does have it running with FancyFaces.
If you might have found another solution, would be glad to hear.
Grts

Beginner Question, working with JSF using Ajax/CSS

i have to make a GUI using JSF, Ajax and CSS working with Apache Database. Im new to this so can someone suggest me any any suitable framework to start with?
You can get some knowledge about JSF in the following site
http://www.coreservlets.com/JSF-Tutorial/jsf2/
It will be helpful for your development activity

Are JSF/Seam/Spring suited for non-enterprise work? (website, not "web application")

I'm starting work on a new website (sort of an e-commerce product comparison thing) and I'm trying to choose what technologies to build it on. I've ruled out PHP and I don't think I want to use Python or Ruby. I really like Java and Hibernate so I started looking into Java-based web technologies.
My problem is that all of the documentation and examples I've read can't seem to stop repeating the words "enterprise" and "web applications." I'm afraid of ending up with giant XML configuration files and business-oriented components while losing the ability to actually design the website. From what I've read of JSF, I like the idea of reusable components, but I still want the ability to customize individual pages. So my question is, are JSF/Seam/Spring well-suited for non-enterprise development? If not, what Java technologies are?
I have just started looking into JSF/Seam so please forgive me if this is an uninformed quesiton. Thanks in advance. :)
No problem. The JSF/Seam stack gives you all the customization you want, and it has very few XML files. In fact, it uses a lot of annotations to define entities and components, so you don't have to worry about writing tou much XML (it is one of the reason why Seam was invented).
JSF's standard components are rendered as simple HTML tags, while if you want to go AJAX and use Richfaces it will be a little harder to customize it, but nothing dramatic. I can assure you that for the view part, you can write whatever you want in your webpages.
Here's a nice reference of how the JSF tags are rendered.
For the model and DB part, the JPA framework gives you the ability to work with simple Java Objects, and sometimes using it in an "enterprise" context with legacy schema is even more difficult, so don't worry.
For a simple website you may safely skip the EJB part, this will help you writing a more cleaner project structure. You can package all your website in a simple .WAR file.
As for the "enterprise" word, I think it is more related to the fact that the Java EE framework gives you the feature you may need in an enterprise context, (i.e. EJBs), but you can avoid them.
They don't bite.

Resources