Re: Multiple Pages
On Oct 13, 9:36 am, Thomas Broyer t.bro...@gmail.com wrote: On 13 oct, 09:21, Elienan elie...@gmail.com wrote: form.addSubmitCompleteHandler(new FormPanel.SubmitCompleteHandler() { @Override public void onSubmitComplete(SubmitCompleteEvent event) { // TODO Auto-generated method stub Window.alert(event.getResults()); form.reset(); commitPanel.add(confirmLabel); commitPanel.add(confirmButton); commitPanel.add(cancelButton); RootPanel.get().clear(); RootPanel.get().add(commitPanel); confirmButton.addClickHandler(new ClickHandler(){ I don't know where you create your confirmButton but, here, each time you submit the form, you'll add a click handler to the button (which as I understand it will be the very same instance each time). Same for your cancelButton and setCampaign. You'll generally add handlers near the line you *create* the widget, not where you *show* it.- Hide quoted text - - Show quoted text - Hi, Thanks a lot for your help. I was missunderstanding that concept of creating widgets and also handlers and then when I want to show them just add to new panel. I was creating the widgets in the beginning of application, but only adding handlers when I want to show the widgets. Now I added the handlers also in the beginning and it's running Ok (just appearing one time the message Window). Now I can add the real code with RPCs :) Thanks a lot!!! -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Multiple Pages
On Oct 11, 5:46 pm, Thomas Broyer t.bro...@gmail.com wrote: On 10 oct, 19:38, Elienan elie...@gmail.com wrote: Hi all, I'm new at GWT, trying to develop my first application with this tool. I already read a lot about multiple pages, and I followed the most common suggestion of have only one page, and then change pannels to change pages. I want to develop a set of pages that allow the users to go back and forward pages according as the button they select. I already can do this with success, but something strange it's happening. As long as I go back to a previous page I already was, the code executes twice the same. Every time I go to a page I already visited, the code is executed one more time than the previous visit. I always do a clear to RootPanel before add a different Panel. I can't understand why the code is incrementing execution times, because all variables from fields are being cleared. Can you please help me understangind why is this happening? Are you talking about using the History class? if so, make sure you're only registering a single ValueChangeHandler (unless you really know you need more); registering multiple times the same ValueChangeHandler will have it called as many times (it's a add not a set). Hi, I'm not using History, not yet :( Here is an example a portion of my code, after form submit. I show a new panel with Confirm or Cancel Button, and first time I choose one of this options, I can see the Window with Confirm or Cancel, and after this options, I go back to the form again, using another Button that appears in a new Panel, like code shows, but second time I fill the form with new values, then when I choose Confirm or Cancel Button, the code where Window appears executes twice, and third time I fill form, it appears three times the Window, and so on and so on... I put debug on the lines, and for example for ConfirmButton ClickHandler, I see it reaching ClickHandler for setCampaign Button and then go back to Window.alert(Confirm) as many times as I filled the form... and can't really understand how this happen and why not follow the code and go down to ClickHandler of setCampaign and so on... Thanks in advance, form.addSubmitCompleteHandler(new FormPanel.SubmitCompleteHandler() { @Override public void onSubmitComplete(SubmitCompleteEvent event) { // TODO Auto-generated method stub Window.alert(event.getResults()); form.reset(); commitPanel.add(confirmLabel); commitPanel.add(confirmButton); commitPanel.add(cancelButton); RootPanel.get().clear(); RootPanel.get().add(commitPanel); confirmButton.addClickHandler(new ClickHandler(){ @Override public void onClick(ClickEvent event) { // TODO Auto-generated method stub Window.alert(Confirm); statusPanel.add(statusLabel); statusPanel.add(setCampaign); RootPanel.get().clear(); RootPanel.get().add(statusPanel); setCampaign.addClickHandler(new ClickHandler(){ @Override public void onClick(ClickEvent event) { // TODO Auto-generated method stub RootPanel.get().clear(); RootPanel.get().add(form); } }); } }); cancelButton.addClickHandler(new ClickHandler(){ @Override
Re: Multiple Pages
On 13 oct, 09:21, Elienan elie...@gmail.com wrote: form.addSubmitCompleteHandler(new FormPanel.SubmitCompleteHandler() { @Override public void onSubmitComplete(SubmitCompleteEvent event) { // TODO Auto-generated method stub Window.alert(event.getResults()); form.reset(); commitPanel.add(confirmLabel); commitPanel.add(confirmButton); commitPanel.add(cancelButton); RootPanel.get().clear(); RootPanel.get().add(commitPanel); confirmButton.addClickHandler(new ClickHandler(){ I don't know where you create your confirmButton but, here, each time you submit the form, you'll add a click handler to the button (which as I understand it will be the very same instance each time). Same for your cancelButton and setCampaign. You'll generally add handlers near the line you *create* the widget, not where you *show* it. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Multiple Pages
On 10 oct, 19:38, Elienan elie...@gmail.com wrote: Hi all, I'm new at GWT, trying to develop my first application with this tool. I already read a lot about multiple pages, and I followed the most common suggestion of have only one page, and then change pannels to change pages. I want to develop a set of pages that allow the users to go back and forward pages according as the button they select. I already can do this with success, but something strange it's happening. As long as I go back to a previous page I already was, the code executes twice the same. Every time I go to a page I already visited, the code is executed one more time than the previous visit. I always do a clear to RootPanel before add a different Panel. I can't understand why the code is incrementing execution times, because all variables from fields are being cleared. Can you please help me understangind why is this happening? Are you talking about using the History class? if so, make sure you're only registering a single ValueChangeHandler (unless you really know you need more); registering multiple times the same ValueChangeHandler will have it called as many times (it's a add not a set). -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: multiple pages
i want to know how to manage pages navigation in other word how to load another page with GWT Component and remove the current component and support back next On Jun 20, 6:39 pm, Stefan Bachert stefanbach...@yahoo.de wrote: Hi Ahmed, with GWT you build a rich internet application. The concept of page does no more fit. This is different to a set of hyperlinked documents. What do you mean with Multiple Pages? a) Multiple entry points. Means different start sequences? Yes, this is possible b) Exchanges the whole application (layout) ? Yes, this is possible c) Something else? Please explain what you are going to achieve Stefan Bacherthttp://gwtworld.de On Jun 20, 1:56 pm, Ahmed Shoeib ahmedelsayed.sho...@gmail.com wrote: can i make multiple pages in GWT it is one have its own onModuleLoad() can i do it ?? -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: multiple pages
Hi Ahmed, with GWT you build a rich internet application. The concept of page does no more fit. This is different to a set of hyperlinked documents. What do you mean with Multiple Pages? a) Multiple entry points. Means different start sequences? Yes, this is possible b) Exchanges the whole application (layout) ? Yes, this is possible c) Something else? Please explain what you are going to achieve Stefan Bachert http://gwtworld.de On Jun 20, 1:56 pm, Ahmed Shoeib ahmedelsayed.sho...@gmail.com wrote: can i make multiple pages in GWT it is one have its own onModuleLoad() can i do it ?? -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Multiple pages question
I'm trying to make a small app to log darts games. Basically, it should be possible to login with a user, register a new user, choose all the options for a new game and play that game. Playing the game means you just click the darts board on screen where you hit the board and the program calculates scores etc. The game page exists of a darts board and all the statistics. This is where I came up with my question because it is really hard to lay out these things in Java code. So I started searching for a possibility to load HTML (where the elements are layed out correctly) and work on the elements by getting them with RootPanel.get(...) instead of building the lay-out with panels in Java. Does this make it more clear what I'm trying to do? Also, how do I actually load HTML from the server into my app through Java? Maarten On 30 jul, 01:14, Ian Bambury ianbamb...@gmail.com wrote: Yes, like I said. Do the layout in the HTML and the functionality in the java code. Why don't you give a simple example of what you are wanting to do. There are many ways to do this and many levels of control you can give to the people who do the layout. It's not really possible to give a one-size-fits-all solution. Ian http://examples.roughian.com 2009/7/29 Maarten Decat maarten.de...@gmail.com Okay, I think I'm starting to see the different options. I can ask the same question more specific now. Formerly, I was used to working like this: I wrote PHP and added all the elements I needed (forms for example) in HTML. Someone else could take control of laying out these elements in any way he liked. He could alter the HTML of the page apart from my PHP and as long as the elements kept their names, everything kept working. This way, I could fix my attention on the program and others could fix their attention at the lay-out. In GWT it's possible to create a lay-out by positioning different widgets in Java code. It's also possible to give these widgets style names which let CSS take control of their layout. But is it also possible of laying out the elements without entering the Java code? I can see how to seperate lay-out with program code but the lay-out would still be specified in Java, no? Maarten On 29 jul, 20:21, Ian Bambury ianbamb...@gmail.com wrote: You have html in your index file. You have code in your java files. How you split everything up is your decision. In your html host page, you could have 2 divs, defining the layout for page1 and page 2. In your GWT code, yo make one or other visible as you need them. It might get a little unmanageable for 100 pages, so you could have html files on the server and go and pick them up as required. You can do both at the same time: have a basic menuing framework and pick up html from server-side pages and slot them into part of your app's display area. That's what my examples site does, mostly to keep all the text out of the initial download. It also means you can easily arrange to get spidered by search engines. Ian http://examples.roughian.com 2009/7/29 maarten.de...@gmail.com maarten.de...@gmail.com Hi, I've been trying out GWT for a couple of weeks now and stumbled upon a beginner's question relating multiple pages. For example, let's suppose an application with users where you have an application page, a login page and a register page. Using GWT for the application page speaks for itself, but what about the other pages? I've read the other topics about this problem in the group. It seems the proper GWT solution is to clear window and load another GUI there. This would actually wrap all the pages within the application. I can see how this solution would work, but then you lack a lot of usefull HTML pages that lay out the login and register forms. This way, making the lay-out of the page cannot be seperated from coding the application, at least not in HTML vs GWT/Java. Is there another way of working for this? One that does permit to seperate page lay-out and coding? Greets, Maarten Decat --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to Google-Web-Toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/Google-Web-Toolkit?hl=en -~--~~~~--~~--~--~---
Re: Multiple pages question
On 30 Jul., 10:22, Maarten Decat maarten.de...@gmail.com wrote: I'm trying to make a small app to log darts games. Basically, it should be possible to login with a user, register a new user, choose all the options for a new game and play that game. Playing the game means you just click the darts board on screen where you hit the board and the program calculates scores etc. The game page exists of a darts board and all the statistics. This is where I came up with my question because it is really hard to lay out these things in Java code. So I started searching for a possibility to load HTML (where the elements are layed out correctly) and work on the elements by getting them with RootPanel.get(...) instead of building the lay-out with panels in Java. Does this make it more clear what I'm trying to do? Also, how do I actually load HTML from the server into my app through Java? Use GWT-RPC or RequestBuilder (both are very well described in the docs) to get your html. Use iframe or just an HTMLPanel to display it. Maarten On 30 jul, 01:14, Ian Bambury ianbamb...@gmail.com wrote: Yes, like I said. Do the layout in the HTML and the functionality in the java code. Why don't you give a simple example of what you are wanting to do. There are many ways to do this and many levels of control you can give to the people who do the layout. It's not really possible to give a one-size-fits-all solution. Ian http://examples.roughian.com 2009/7/29 Maarten Decat maarten.de...@gmail.com Okay, I think I'm starting to see the different options. I can ask the same question more specific now. Formerly, I was used to working like this: I wrote PHP and added all the elements I needed (forms for example) in HTML. Someone else could take control of laying out these elements in any way he liked. He could alter the HTML of the page apart from my PHP and as long as the elements kept their names, everything kept working. This way, I could fix my attention on the program and others could fix their attention at the lay-out. In GWT it's possible to create a lay-out by positioning different widgets in Java code. It's also possible to give these widgets style names which let CSS take control of their layout. But is it also possible of laying out the elements without entering the Java code? I can see how to seperate lay-out with program code but the lay-out would still be specified in Java, no? Maarten On 29 jul, 20:21, Ian Bambury ianbamb...@gmail.com wrote: You have html in your index file. You have code in your java files. How you split everything up is your decision. In your html host page, you could have 2 divs, defining the layout for page1 and page 2. In your GWT code, yo make one or other visible as you need them. It might get a little unmanageable for 100 pages, so you could have html files on the server and go and pick them up as required. You can do both at the same time: have a basic menuing framework and pick up html from server-side pages and slot them into part of your app's display area. That's what my examples site does, mostly to keep all the text out of the initial download. It also means you can easily arrange to get spidered by search engines. Ian http://examples.roughian.com 2009/7/29 maarten.de...@gmail.com maarten.de...@gmail.com Hi, I've been trying out GWT for a couple of weeks now and stumbled upon a beginner's question relating multiple pages. For example, let's suppose an application with users where you have an application page, a login page and a register page. Using GWT for the application page speaks for itself, but what about the other pages? I've read the other topics about this problem in the group. It seems the proper GWT solution is to clear window and load another GUI there. This would actually wrap all the pages within the application. I can see how this solution would work, but then you lack a lot of usefull HTML pages that lay out the login and register forms. This way, making the lay-out of the page cannot be seperated from coding the application, at least not in HTML vs GWT/Java. Is there another way of working for this? One that does permit to seperate page lay-out and coding? Greets, Maarten Decat --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to Google-Web-Toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/Google-Web-Toolkit?hl=en -~--~~~~--~~--~--~---
Re: Multiple pages question
The easiest way is just to have the html in the host html page in a div with display:none Inside that div, have all the elements you need for the page, add widgets to these elements with RootPanel.get(id).add(something); and set the enclosing div to visible = true when you want it to be displayed. The other pages for a small app like this can also be shown and hidden as required in their own divs in the same way. As Alex said, you can keep the (GWT) 'pages' in their own html file, fetch them, extract the part you need and put it in an HTMLPanel as required. It doesn't seem worth it to me in this scenario. Ian http://examples.roughian.com 2009/7/30 Maarten Decat maarten.de...@gmail.com I'm trying to make a small app to log darts games. Basically, it should be possible to login with a user, register a new user, choose all the options for a new game and play that game. Playing the game means you just click the darts board on screen where you hit the board and the program calculates scores etc. The game page exists of a darts board and all the statistics. This is where I came up with my question because it is really hard to lay out these things in Java code. So I started searching for a possibility to load HTML (where the elements are layed out correctly) and work on the elements by getting them with RootPanel.get(...) instead of building the lay-out with panels in Java. Does this make it more clear what I'm trying to do? Also, how do I actually load HTML from the server into my app through Java? Maarten On 30 jul, 01:14, Ian Bambury ianbamb...@gmail.com wrote: Yes, like I said. Do the layout in the HTML and the functionality in the java code. Why don't you give a simple example of what you are wanting to do. There are many ways to do this and many levels of control you can give to the people who do the layout. It's not really possible to give a one-size-fits-all solution. Ian http://examples.roughian.com 2009/7/29 Maarten Decat maarten.de...@gmail.com Okay, I think I'm starting to see the different options. I can ask the same question more specific now. Formerly, I was used to working like this: I wrote PHP and added all the elements I needed (forms for example) in HTML. Someone else could take control of laying out these elements in any way he liked. He could alter the HTML of the page apart from my PHP and as long as the elements kept their names, everything kept working. This way, I could fix my attention on the program and others could fix their attention at the lay-out. In GWT it's possible to create a lay-out by positioning different widgets in Java code. It's also possible to give these widgets style names which let CSS take control of their layout. But is it also possible of laying out the elements without entering the Java code? I can see how to seperate lay-out with program code but the lay-out would still be specified in Java, no? Maarten On 29 jul, 20:21, Ian Bambury ianbamb...@gmail.com wrote: You have html in your index file. You have code in your java files. How you split everything up is your decision. In your html host page, you could have 2 divs, defining the layout for page1 and page 2. In your GWT code, yo make one or other visible as you need them. It might get a little unmanageable for 100 pages, so you could have html files on the server and go and pick them up as required. You can do both at the same time: have a basic menuing framework and pick up html from server-side pages and slot them into part of your app's display area. That's what my examples site does, mostly to keep all the text out of the initial download. It also means you can easily arrange to get spidered by search engines. Ian http://examples.roughian.com 2009/7/29 maarten.de...@gmail.com maarten.de...@gmail.com Hi, I've been trying out GWT for a couple of weeks now and stumbled upon a beginner's question relating multiple pages. For example, let's suppose an application with users where you have an application page, a login page and a register page. Using GWT for the application page speaks for itself, but what about the other pages? I've read the other topics about this problem in the group. It seems the proper GWT solution is to clear window and load another GUI there. This would actually wrap all the pages within the application. I can see how this solution would work, but then you lack a lot of usefull HTML pages that lay out the login and register forms. This way, making the lay-out of the page cannot be seperated from coding the application, at least not in HTML vs GWT/Java. Is there another way of working for this? One that does permit to seperate page lay-out and coding? Greets, Maarten Decat
Re: Multiple pages question
I think that the issue that you're running into here is one of mindset. Web developers think in terms of pages but a Swing/MFC/thick client developers dont. GWT is kind of a bridge between the two. From what i've seen, the GWT way of doing things is to clear out the visible components and render your new components to give the user a different view. (like you said) Now is your question how can i create these two views in separate java files (which is an architecture question) or how can i separate widget (element) composition from Java which is almost a philosophical question because GWT (at least as far as i've seen) is not designed to operate that way. (which i believe is a design feature, not an oversight) One other fly in the ointment that you may not have stumbled into yet which will blow your mind at first is using the back button. There is lots of documentation out there on using GWT History and it's really a different way of thinking coming from a web developer perspective. ...if you are asking the architecture question, so far i havent seen much yet on best practices for organizing your classes and widgets but you should start by searching for 'GWT Custom widgets' and specifically checking out the Composite class. That should get your started in how you can organize and compose your various views. Disclaimer... I've only been using GWT for about a month now but i've been doing Swing/Visual C++/VB gui's for a long time and to me GWT fits as naturally as anything i've ever seen from a web framework perspective. But it is very different from Swing, Spring MVC, JSF and the like. Trevis On Jul 29, 5:34 am, maarten.de...@gmail.com maarten.de...@gmail.com wrote: Hi, I've been trying out GWT for a couple of weeks now and stumbled upon a beginner's question relating multiple pages. For example, let's suppose an application with users where you have an application page, a login page and a register page. Using GWT for the application page speaks for itself, but what about the other pages? I've read the other topics about this problem in the group. It seems the proper GWT solution is to clear window and load another GUI there. This would actually wrap all the pages within the application. I can see how this solution would work, but then you lack a lot of usefull HTML pages that lay out the login and register forms. This way, making the lay-out of the page cannot be seperated from coding the application, at least not in HTML vs GWT/Java. Is there another way of working for this? One that does permit to seperate page lay-out and coding? Greets, Maarten Decat --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to Google-Web-Toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/Google-Web-Toolkit?hl=en -~--~~~~--~~--~--~---
Re: Multiple pages question
You have html in your index file. You have code in your java files. How you split everything up is your decision. In your html host page, you could have 2 divs, defining the layout for page1 and page 2. In your GWT code, yo make one or other visible as you need them. It might get a little unmanageable for 100 pages, so you could have html files on the server and go and pick them up as required. You can do both at the same time: have a basic menuing framework and pick up html from server-side pages and slot them into part of your app's display area. That's what my examples site does, mostly to keep all the text out of the initial download. It also means you can easily arrange to get spidered by search engines. Ian http://examples.roughian.com 2009/7/29 maarten.de...@gmail.com maarten.de...@gmail.com Hi, I've been trying out GWT for a couple of weeks now and stumbled upon a beginner's question relating multiple pages. For example, let's suppose an application with users where you have an application page, a login page and a register page. Using GWT for the application page speaks for itself, but what about the other pages? I've read the other topics about this problem in the group. It seems the proper GWT solution is to clear window and load another GUI there. This would actually wrap all the pages within the application. I can see how this solution would work, but then you lack a lot of usefull HTML pages that lay out the login and register forms. This way, making the lay-out of the page cannot be seperated from coding the application, at least not in HTML vs GWT/Java. Is there another way of working for this? One that does permit to seperate page lay-out and coding? Greets, Maarten Decat --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to Google-Web-Toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/Google-Web-Toolkit?hl=en -~--~~~~--~~--~--~---
Re: Multiple pages question
Okay, I think I'm starting to see the different options. I can ask the same question more specific now. Formerly, I was used to working like this: I wrote PHP and added all the elements I needed (forms for example) in HTML. Someone else could take control of laying out these elements in any way he liked. He could alter the HTML of the page apart from my PHP and as long as the elements kept their names, everything kept working. This way, I could fix my attention on the program and others could fix their attention at the lay-out. In GWT it's possible to create a lay-out by positioning different widgets in Java code. It's also possible to give these widgets style names which let CSS take control of their layout. But is it also possible of laying out the elements without entering the Java code? I can see how to seperate lay-out with program code but the lay-out would still be specified in Java, no? Maarten On 29 jul, 20:21, Ian Bambury ianbamb...@gmail.com wrote: You have html in your index file. You have code in your java files. How you split everything up is your decision. In your html host page, you could have 2 divs, defining the layout for page1 and page 2. In your GWT code, yo make one or other visible as you need them. It might get a little unmanageable for 100 pages, so you could have html files on the server and go and pick them up as required. You can do both at the same time: have a basic menuing framework and pick up html from server-side pages and slot them into part of your app's display area. That's what my examples site does, mostly to keep all the text out of the initial download. It also means you can easily arrange to get spidered by search engines. Ian http://examples.roughian.com 2009/7/29 maarten.de...@gmail.com maarten.de...@gmail.com Hi, I've been trying out GWT for a couple of weeks now and stumbled upon a beginner's question relating multiple pages. For example, let's suppose an application with users where you have an application page, a login page and a register page. Using GWT for the application page speaks for itself, but what about the other pages? I've read the other topics about this problem in the group. It seems the proper GWT solution is to clear window and load another GUI there. This would actually wrap all the pages within the application. I can see how this solution would work, but then you lack a lot of usefull HTML pages that lay out the login and register forms. This way, making the lay-out of the page cannot be seperated from coding the application, at least not in HTML vs GWT/Java. Is there another way of working for this? One that does permit to seperate page lay-out and coding? Greets, Maarten Decat --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to Google-Web-Toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/Google-Web-Toolkit?hl=en -~--~~~~--~~--~--~---
Re: Multiple pages question
Yes, like I said. Do the layout in the HTML and the functionality in the java code. Why don't you give a simple example of what you are wanting to do. There are many ways to do this and many levels of control you can give to the people who do the layout. It's not really possible to give a one-size-fits-all solution. Ian http://examples.roughian.com 2009/7/29 Maarten Decat maarten.de...@gmail.com Okay, I think I'm starting to see the different options. I can ask the same question more specific now. Formerly, I was used to working like this: I wrote PHP and added all the elements I needed (forms for example) in HTML. Someone else could take control of laying out these elements in any way he liked. He could alter the HTML of the page apart from my PHP and as long as the elements kept their names, everything kept working. This way, I could fix my attention on the program and others could fix their attention at the lay-out. In GWT it's possible to create a lay-out by positioning different widgets in Java code. It's also possible to give these widgets style names which let CSS take control of their layout. But is it also possible of laying out the elements without entering the Java code? I can see how to seperate lay-out with program code but the lay-out would still be specified in Java, no? Maarten On 29 jul, 20:21, Ian Bambury ianbamb...@gmail.com wrote: You have html in your index file. You have code in your java files. How you split everything up is your decision. In your html host page, you could have 2 divs, defining the layout for page1 and page 2. In your GWT code, yo make one or other visible as you need them. It might get a little unmanageable for 100 pages, so you could have html files on the server and go and pick them up as required. You can do both at the same time: have a basic menuing framework and pick up html from server-side pages and slot them into part of your app's display area. That's what my examples site does, mostly to keep all the text out of the initial download. It also means you can easily arrange to get spidered by search engines. Ian http://examples.roughian.com 2009/7/29 maarten.de...@gmail.com maarten.de...@gmail.com Hi, I've been trying out GWT for a couple of weeks now and stumbled upon a beginner's question relating multiple pages. For example, let's suppose an application with users where you have an application page, a login page and a register page. Using GWT for the application page speaks for itself, but what about the other pages? I've read the other topics about this problem in the group. It seems the proper GWT solution is to clear window and load another GUI there. This would actually wrap all the pages within the application. I can see how this solution would work, but then you lack a lot of usefull HTML pages that lay out the login and register forms. This way, making the lay-out of the page cannot be seperated from coding the application, at least not in HTML vs GWT/Java. Is there another way of working for this? One that does permit to seperate page lay-out and coding? Greets, Maarten Decat --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to Google-Web-Toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/Google-Web-Toolkit?hl=en -~--~~~~--~~--~--~---
Re: Multiple pages with entry points
Hi I would go with one html page that points to your entry point. Then just import your page 2 widgets. On Oct 21, 11:06 am, Michi_de [EMAIL PROTECTED] wrote: Hi, is there any way to create an application like this for example: page1.html - i implement my gwt application with div id= tag. page1.html - it also contains following code: script type=text/javascript language=javascript src=extGWTformular.Formular.nocache.js/script in my gwt.xml there is the following entry point definded: entry-point class='extGWTformular.client.Formular'/ Works just fine. Now the page1.html includes a href link to page2.html In page2.html i wanted to use some GWT function too. I also thought its just easy as it is in the first entry point: add a div.. tag and the script..., done. But it doesnt work. Is it possible, to implement such a application? Or is it just possible to use one html page which contains all widgets ? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to Google-Web-Toolkit@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/Google-Web-Toolkit?hl=en -~--~~~~--~~--~--~---