Re: [Wicket-user] URL redirect
Thomas, you are using a proxy, right? If you enter http://localhost:8080/foo/ in the browser, wicket redirects to http://localhost:8080/foo/?page=0 But with the proxy in between, the browser is redirected to http://localhost:8080/foo?page=0 I have experienced this problem with mod_prox, and I don't have a solution. I hope to be able to fix it when going to 1.2. which seems allows more control over URLs. IMHO wicket should allow full control over rendering of URLs and never rely on the servlet container to complete redirect URLs. This would make working with proxies a lot easier. Timo Tom S. schrieb: Why should it redirect to /foo/xyz.abc? Because I've entered /foo/ and a typical plain-html-webserver redirects to /foo/index.html. You can do that if you mount bookmarkable pages i guess. I have no clue, how to do that, esp. with the home page. What kind of resource is not found? Can you give an example? I've tried to sketch that in my original posting. Sorry, if it wasn't clear enough. I'll try with different wordings: I enter the URL http://localhost:8080/foo/ in the browser. My Index.html (and the page content ariving my browser) contains a graphic reference to graphics/logo.png (it is found and displayed correctly when I enter the URL http://localhost:8080/foo/graphics/logo.png). Since the wicket-servlet obviously is redirecting to http://localhost:8080/foo?page=0, the browser obviously expects the graphic to be at http://localhost:8080/graphics/logo.png (note the missing /foo after the port!). -- Cheers, Tom Johan Compagner wrote: Why should it redirect to /foo/xyz.abc? You can do that if you mount bookmarkable pages i guess. What kind of resource is not found? Can you give an example? johan On 2/14/06, *Thomas Singer* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: does this clear things up? No, not really. it processes because the url http://localhost/foo/index.html matches the /foo/* mapping. see the /foo/ in the url, the /foo/* mapping will match /foo/index.html fragment of the url. This fully is clear, but why http://localhost/foo?page=0 is processed by the /foo/*-mapping? And why does the wicket-servlet redirects to http://localhost/foo?page=0 and not to http://localhost/foo/xyz.abc? I'll ask these things, because this might be the problem why my resource (graphics) cannot not be found. Tom Igor Vaynberg wrote: it processes because the url http://localhost/foo/index.html matches the /foo/* mapping. see the /foo/ in the url, the /foo/* mapping will match /foo/index.html fragment of the url. i am assuming you are deploying the wicket app in the root context, so users should really be starting at http://localhost/index.html http://localhost/index.html. when your users hit http://localhost/foo/ it will be processed by the wicket servlet. since no page is specified the homepage will be retrieved. does this clear things up? On 2/14/06, *Tom S.* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: Hi Igor, I meant something different. What happens, when the user enters the URL http://localhost/foo/ in its browser? I guess, this address is sent to the web server. If it is a passive one, it might redirect the browser to http://localhost/foo/index.html (note, the directory is the same). But the wicket-servlet tells the browser to try it again at http://localhost/foo?page=0 (which is a different directory). Is this correct so far? Just curious, why does the wicket-servlet processes this request, when the servlet-mapping is set to the URL-pattern /foo/*? Tom PS: Please excuse my trivial wordings, these are my first deeper steps in webapp development. Igor Vaynberg wrote: you should put index.html in your context root and have a metaredirect to /foo inside something like this: html head meta http-equiv=Refresh content=0; url=foo /head /html -Igor On 2/13/06, *Tom S.* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: OK, I now can read my html files from a different location. But I still have a serious problem with resources ( e.g. graphics). The servlet
Re: [Wicket-user] URL redirect
Hi Igor, I meant something different. What happens, when the user enters the URL http://localhost/foo/ in its browser? I guess, this address is sent to the web server. If it is a passive one, it might redirect the browser to http://localhost/foo/index.html (note, the directory is the same). But the wicket-servlet tells the browser to try it again at http://localhost/foo?page=0 (which is a different directory). Is this correct so far? Just curious, why does the wicket-servlet processes this request, when the servlet-mapping is set to the URL-pattern /foo/*? Tom PS: Please excuse my trivial wordings, these are my first deeper steps in webapp development. Igor Vaynberg wrote: you should put index.html in your context root and have a metaredirect to /foo inside something like this: html head meta http-equiv=Refresh content=0; url=foo /head /html -Igor On 2/13/06, *Tom S.* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: OK, I now can read my html files from a different location. But I still have a serious problem with resources ( e.g. graphics). The servlet mapping in the web.xml looks like this: servlet-mapping servlet-nameMyWebApplication/servlet-name url-pattern/foo/*/url-pattern /servlet-mapping When I open the URL http://localhost:8080/foo/graphics/logo.png, the graphic is shown. In the Index.html (my home page), it is references as graphics/logo.png. Unfortunately it cannot be found when displaying the home page with the URL http://localhost:8080/foo/, most likely because it redirects the request to http://localhost:8080/foo?path=0, which is a directory change. Is there a possibility to redirect to http://localhost:8080/foo/index.html http://localhost:8080/foo/index.html or something similar, so the relative paths work as expected? -- Thanks in advance, Tom PS: I'm not experienced with web applications, so please excuse these dumb questions. --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net mailto:Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user https://lists.sourceforge.net/lists/listinfo/wicket-user --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] URL redirect
In the current version of 1.2 the home page shouldn't be redirected if it was justmounted on / if it was mounted to another path then a redirect is done (in 1.1 this was an option what to do with the home page: redirect to bookmarkable varant, redirect to path=x or don't redirect) johanOn 2/14/06, Tom S. [EMAIL PROTECTED] wrote: Hi Igor,I meant something different. What happens, when the user enters the URLhttp://localhost/foo/ in its browser? I guess, this address is sent tothe web server. If it is a passive one, it might redirect the browser to http://localhost/foo/index.html (note, the directory is the same). Butthe wicket-servlet tells the browser to try it again at http://localhost/foo?page=0 (which is a different directory). Is thiscorrect so far?Just curious, why does the wicket-servlet processes this request, whenthe servlet-mapping is set to the URL-pattern /foo/*? TomPS: Please excuse my trivial wordings, these are my first deeper stepsin webapp development.Igor Vaynberg wrote: you should put index.html in your context root and have a metaredirect to /foo inside something like this: html head meta http-equiv=Refresh content=0; url=""> /head /html -Igor On 2/13/06, *Tom S.* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: OK, I now can read my html files from a different location. But I still have a serious problem with resources ( e.g. graphics). The servlet mapping in the web.xml looks like this:servlet-mappingservlet-nameMyWebApplication/servlet-nameurl-pattern/foo/*/url-pattern /servlet-mapping When I open the URL http://localhost:8080/foo/graphics/logo.png, the graphic is shown. In the Index.html (my home page), it is references as graphics/logo.png. Unfortunately it cannot be found when displaying the home page with the URL http://localhost:8080/foo/, most likely because it redirects the request to http://localhost:8080/foo?path=0, which is a directory change. Is there a possibility to redirect to http://localhost:8080/foo/index.html http://localhost:8080/foo/index.html or something similar, so the relative paths work as expected? -- Thanks in advance, Tom PS: I'm not experienced with web applications, so please excuse these dumb questions. --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems?Stop!Download the new AJAX search engine that makes searching your log files as easy as surfing theweb.DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net mailto: Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user https://lists.sourceforge.net/lists/listinfo/wicket-user--- This SF.net email is sponsored by: Splunk Inc. Do you grep through log filesfor problems?Stop!Download the new AJAX search engine that makessearching your log files as easy as surfing theweb.DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642___ Wicket-user mailing listWicket-user@lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] URL redirect
Hi Johan, Do you also remember, where this option can be set? Thanks in advance, Tom Johan Compagner wrote: In the current version of 1.2 the home page shouldn't be redirected if it was just mounted on / if it was mounted to another path then a redirect is done (in 1.1 this was an option what to do with the home page: redirect to bookmarkable varant, redirect to path=x or don't redirect) johan On 2/14/06, *Tom S.* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: Hi Igor, I meant something different. What happens, when the user enters the URL http://localhost/foo/ in its browser? I guess, this address is sent to the web server. If it is a passive one, it might redirect the browser to http://localhost/foo/index.html (note, the directory is the same). But the wicket-servlet tells the browser to try it again at http://localhost/foo?page=0 (which is a different directory). Is this correct so far? Just curious, why does the wicket-servlet processes this request, when the servlet-mapping is set to the URL-pattern /foo/*? Tom PS: Please excuse my trivial wordings, these are my first deeper steps in webapp development. Igor Vaynberg wrote: you should put index.html in your context root and have a metaredirect to /foo inside something like this: html head meta http-equiv=Refresh content=0; url=foo /head /html -Igor On 2/13/06, *Tom S.* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: OK, I now can read my html files from a different location. But I still have a serious problem with resources ( e.g. graphics). The servlet mapping in the web.xml looks like this: servlet-mapping servlet-nameMyWebApplication/servlet-name url-pattern/foo/*/url-pattern /servlet-mapping When I open the URL http://localhost:8080/foo/graphics/logo.png, the graphic is shown. In the Index.html (my home page), it is references as graphics/logo.png. Unfortunately it cannot be found when displaying the home page with the URL http://localhost:8080/foo/, most likely because it redirects the request to http://localhost:8080/foo?path=0, which is a directory change. Is there a possibility to redirect to http://localhost:8080/foo/index.html http://localhost:8080/foo/index.html or something similar, so the relative paths work as expected? -- Thanks in advance, Tom PS: I'm not experienced with web applications, so please excuse these dumb questions. --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net mailto:Wicket-user@lists.sourceforge.net mailto: Wicket-user@lists.sourceforge.net mailto:Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user https://lists.sourceforge.net/lists/listinfo/wicket-user https://lists.sourceforge.net/lists/listinfo/wicket-user --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net mailto:Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user https://lists.sourceforge.net/lists/listinfo/wicket-user --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new
Re: [Wicket-user] URL redirect
it processes because the url http://localhost/foo/index.html matches the /foo/* mapping. see the /foo/ in the url, the /foo/* mapping will match /foo/index.html fragment of the url. i am assuming you are deploying the wicket app in the root context, so users should really be starting at http://localhost/index.html.when your users hit http://localhost/foo/ it will be processed by the wicket servlet. since no page is specified the homepage will be retrieved. does this clear things up?On 2/14/06, Tom S. [EMAIL PROTECTED] wrote: Hi Igor,I meant something different. What happens, when the user enters the URLhttp://localhost/foo/ in its browser? I guess, this address is sent tothe web server. If it is a passive one, it might redirect the browser to http://localhost/foo/index.html (note, the directory is the same). Butthe wicket-servlet tells the browser to try it again at http://localhost/foo?page=0 (which is a different directory). Is thiscorrect so far?Just curious, why does the wicket-servlet processes this request, whenthe servlet-mapping is set to the URL-pattern /foo/*? TomPS: Please excuse my trivial wordings, these are my first deeper stepsin webapp development.Igor Vaynberg wrote: you should put index.html in your context root and have a metaredirect to /foo inside something like this: html head meta http-equiv=Refresh content=0; url=""> /head /html -Igor On 2/13/06, *Tom S.* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: OK, I now can read my html files from a different location. But I still have a serious problem with resources ( e.g. graphics). The servlet mapping in the web.xml looks like this:servlet-mappingservlet-nameMyWebApplication/servlet-nameurl-pattern/foo/*/url-pattern /servlet-mapping When I open the URL http://localhost:8080/foo/graphics/logo.png, the graphic is shown. In the Index.html (my home page), it is references as graphics/logo.png. Unfortunately it cannot be found when displaying the home page with the URL http://localhost:8080/foo/, most likely because it redirects the request to http://localhost:8080/foo?path=0, which is a directory change. Is there a possibility to redirect to http://localhost:8080/foo/index.html http://localhost:8080/foo/index.html or something similar, so the relative paths work as expected? -- Thanks in advance, Tom PS: I'm not experienced with web applications, so please excuse these dumb questions. --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems?Stop!Download the new AJAX search engine that makes searching your log files as easy as surfing theweb.DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net mailto: Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user https://lists.sourceforge.net/lists/listinfo/wicket-user--- This SF.net email is sponsored by: Splunk Inc. Do you grep through log filesfor problems?Stop!Download the new AJAX search engine that makessearching your log files as easy as surfing theweb.DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642___ Wicket-user mailing listWicket-user@lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] URL redirect
does this clear things up? No, not really. it processes because the url http://localhost/foo/index.html matches the /foo/* mapping. see the /foo/ in the url, the /foo/* mapping will match /foo/index.html fragment of the url. This fully is clear, but why http://localhost/foo?page=0 is processed by the /foo/*-mapping? And why does the wicket-servlet redirects to http://localhost/foo?page=0 and not to http://localhost/foo/xyz.abc? I'll ask these things, because this might be the problem why my resource (graphics) cannot not be found. Tom Igor Vaynberg wrote: it processes because the url http://localhost/foo/index.html matches the /foo/* mapping. see the /foo/ in the url, the /foo/* mapping will match /foo/index.html fragment of the url. i am assuming you are deploying the wicket app in the root context, so users should really be starting at http://localhost/index.html. when your users hit http://localhost/foo/ it will be processed by the wicket servlet. since no page is specified the homepage will be retrieved. does this clear things up? On 2/14/06, *Tom S.* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: Hi Igor, I meant something different. What happens, when the user enters the URL http://localhost/foo/ in its browser? I guess, this address is sent to the web server. If it is a passive one, it might redirect the browser to http://localhost/foo/index.html (note, the directory is the same). But the wicket-servlet tells the browser to try it again at http://localhost/foo?page=0 (which is a different directory). Is this correct so far? Just curious, why does the wicket-servlet processes this request, when the servlet-mapping is set to the URL-pattern /foo/*? Tom PS: Please excuse my trivial wordings, these are my first deeper steps in webapp development. Igor Vaynberg wrote: you should put index.html in your context root and have a metaredirect to /foo inside something like this: html head meta http-equiv=Refresh content=0; url=foo /head /html -Igor On 2/13/06, *Tom S.* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: OK, I now can read my html files from a different location. But I still have a serious problem with resources ( e.g. graphics). The servlet mapping in the web.xml looks like this: servlet-mapping servlet-nameMyWebApplication/servlet-name url-pattern/foo/*/url-pattern /servlet-mapping When I open the URL http://localhost:8080/foo/graphics/logo.png, the graphic is shown. In the Index.html (my home page), it is references as graphics/logo.png. Unfortunately it cannot be found when displaying the home page with the URL http://localhost:8080/foo/, most likely because it redirects the request to http://localhost:8080/foo?path=0, which is a directory change. Is there a possibility to redirect to http://localhost:8080/foo/index.html http://localhost:8080/foo/index.html or something similar, so the relative paths work as expected? -- Thanks in advance, Tom PS: I'm not experienced with web applications, so please excuse these dumb questions. --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net mailto:Wicket-user@lists.sourceforge.net mailto: Wicket-user@lists.sourceforge.net mailto:Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user https://lists.sourceforge.net/lists/listinfo/wicket-user https://lists.sourceforge.net/lists/listinfo/wicket-user --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your
Re: [Wicket-user] URL redirect
Why should it redirect to /foo/xyz.abc?You can do that if you mount bookmarkable pages i guess.What kind of resource is not found?Can you give an example?johan On 2/14/06, Thomas Singer [EMAIL PROTECTED] wrote: does this clear things up?No, not really. it processes because the url http://localhost/foo/index.html matches the /foo/* mapping. see the /foo/ in the url, the /foo/* mapping will match /foo/index.html fragment of the url. This fully is clear, but why http://localhost/foo?page=0 is processed bythe /foo/*-mapping? And why does the wicket-servlet redirects to http://localhost/foo?page=0 and not to http://localhost/foo/xyz.abc?I'll ask these things, because this might be the problem why my resource(graphics) cannot not be found. TomIgor Vaynberg wrote: it processes because the url http://localhost/foo/index.html matches the /foo/* mapping. see the /foo/ in the url, the /foo/* mapping will match /foo/index.html fragment of the url. i am assuming you are deploying the wicket app in the root context, so users should really be starting at http://localhost/index.html . when your users hit http://localhost/foo/ it will be processed by the wicket servlet. since no page is specified the homepage will be retrieved. does this clear things up? On 2/14/06, *Tom S.* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: Hi Igor, I meant something different. What happens, when the user enters the URL http://localhost/foo/ in its browser? I guess, this address is sent to the web server. If it is a passive one, it might redirect the browser to http://localhost/foo/index.html (note, the directory is the same). But the wicket-servlet tells the browser to try it again at http://localhost/foo?page=0 (which is a different directory). Is this correct so far? Just curious, why does the wicket-servlet processes this request, when the servlet-mapping is set to the URL-pattern /foo/*? Tom PS: Please excuse my trivial wordings, these are my first deeper steps in webapp development. Igor Vaynberg wrote: you should put index.html in your context root and have a metaredirect to /foo inside something like this: html head meta http-equiv=Refresh content=0; url="" /head /html -Igor On 2/13/06, *Tom S.* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: OK, I now can read my html files from a different location. But I still have a serious problem with resources ( e.g. graphics). The servlet mapping in the web.xml looks like this:servlet-mappingservlet-nameMyWebApplication/servlet-name url-pattern/foo/*/url-pattern/servlet-mapping When I open the URL http://localhost:8080/foo/graphics/logo.png, the graphic is shown. In the Index.html (my home page), it is references as graphics/logo.png. Unfortunately it cannot be found when displaying the home page with the URL http://localhost:8080/foo/, most likely because it redirects the request to http://localhost:8080/foo?path=0, which is a directory change. Is there a possibility to redirect to http://localhost:8080/foo/index.html http://localhost:8080/foo/index.html or something similar, so the relative paths work as expected? -- Thanks in advance, Tom PS: I'm not experienced with web applications, so please excuse these dumb questions. --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems?Stop!Download the new AJAX search engine that makes searching your log files as easy as surfing theweb.DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net mailto: Wicket-user@lists.sourceforge.net mailto: Wicket-user@lists.sourceforge.net mailto: Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user https://lists.sourceforge.net/lists/listinfo/wicket-user https://lists.sourceforge.net/lists/listinfo/wicket-user --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems?Stop!Download the new AJAX search engine that makes searching your log files as easy as surfing theweb.DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net mailto: Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user https://lists.sourceforge.net/lists/listinfo/wicket-user--- This SF.net email is sponsored by:
Re: [Wicket-user] URL redirect
Why should it redirect to /foo/xyz.abc? Because I've entered /foo/ and a typical plain-html-webserver redirects to /foo/index.html. You can do that if you mount bookmarkable pages i guess. I have no clue, how to do that, esp. with the home page. What kind of resource is not found? Can you give an example? I've tried to sketch that in my original posting. Sorry, if it wasn't clear enough. I'll try with different wordings: I enter the URL http://localhost:8080/foo/ in the browser. My Index.html (and the page content ariving my browser) contains a graphic reference to graphics/logo.png (it is found and displayed correctly when I enter the URL http://localhost:8080/foo/graphics/logo.png). Since the wicket-servlet obviously is redirecting to http://localhost:8080/foo?page=0, the browser obviously expects the graphic to be at http://localhost:8080/graphics/logo.png (note the missing /foo after the port!). -- Cheers, Tom Johan Compagner wrote: Why should it redirect to /foo/xyz.abc? You can do that if you mount bookmarkable pages i guess. What kind of resource is not found? Can you give an example? johan On 2/14/06, *Thomas Singer* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: does this clear things up? No, not really. it processes because the url http://localhost/foo/index.html matches the /foo/* mapping. see the /foo/ in the url, the /foo/* mapping will match /foo/index.html fragment of the url. This fully is clear, but why http://localhost/foo?page=0 is processed by the /foo/*-mapping? And why does the wicket-servlet redirects to http://localhost/foo?page=0 and not to http://localhost/foo/xyz.abc? I'll ask these things, because this might be the problem why my resource (graphics) cannot not be found. Tom Igor Vaynberg wrote: it processes because the url http://localhost/foo/index.html matches the /foo/* mapping. see the /foo/ in the url, the /foo/* mapping will match /foo/index.html fragment of the url. i am assuming you are deploying the wicket app in the root context, so users should really be starting at http://localhost/index.html http://localhost/index.html. when your users hit http://localhost/foo/ it will be processed by the wicket servlet. since no page is specified the homepage will be retrieved. does this clear things up? On 2/14/06, *Tom S.* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: Hi Igor, I meant something different. What happens, when the user enters the URL http://localhost/foo/ in its browser? I guess, this address is sent to the web server. If it is a passive one, it might redirect the browser to http://localhost/foo/index.html (note, the directory is the same). But the wicket-servlet tells the browser to try it again at http://localhost/foo?page=0 (which is a different directory). Is this correct so far? Just curious, why does the wicket-servlet processes this request, when the servlet-mapping is set to the URL-pattern /foo/*? Tom PS: Please excuse my trivial wordings, these are my first deeper steps in webapp development. Igor Vaynberg wrote: you should put index.html in your context root and have a metaredirect to /foo inside something like this: html head meta http-equiv=Refresh content=0; url=foo /head /html -Igor On 2/13/06, *Tom S.* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: OK, I now can read my html files from a different location. But I still have a serious problem with resources ( e.g. graphics). The servlet mapping in the web.xml looks like this: servlet-mapping servlet-nameMyWebApplication/servlet-name url-pattern/foo/*/url-pattern /servlet-mapping When I open the URL http://localhost:8080/foo/graphics/logo.png, the graphic is shown. In the Index.html (my home page), it is references as graphics/logo.png. Unfortunately it cannot be found when displaying the home page with the URL
Re: [Wicket-user] URL redirect
Why should it redirect to /foo/xyz.abc?Because I've entered /foo/ and a typical plain-html-webserver redirects to /foo/index.html.Thats not true many serve you the index.html on that dir but in the url you mostly just see /At least for homepages this is mostly the case. What kind of resource is not found? Can you give an example?I've tried to sketch that in my original posting. Sorry, if it wasn'tclear enough. I'll try with different wordings:I enter the URL http://localhost:8080/foo/ in the browser. My Index.html(and the page content ariving my browser) contains a graphic referenceto graphics/logo.png (it is found and displayed correctly when I enter the URL http://localhost:8080/foo/graphics/logo.png). Since thewicket-servlet obviously is redirecting tohttp://localhost:8080/foo?page=0 , the browser obviously expects thegraphic to be at http://localhost:8080/graphics/logo.png (note themissing /foo after the port!). so you just want to mix wicket pages and resources in the root of youre webapplication?Or are you also serving index.html (a plain resource) in the /foo/ dir what is mapped as the wicket servlet url? That shouldn't be done. What does that index.html do?? Move it to the real root of youre webapplication./foo is there for dynamic pages.johan
Re: [Wicket-user] URL redirect
Thats not true many serve you the index.html on that dir but in the url you mostly just see / At least for homepages this is mostly the case. Visually it does not change to /foo/index.html, but it behaves like this, because the resources are fetched relative to this path. so you just want to mix wicket pages and resources in the root of youre webapplication? First, /foo/ should be the root of our web-application. According to our provider, we later can map a domain to such a directory, so www.company.com maps to http://ourserver/foo/. At least, that's how I understood it. Or are you also serving index.html (a plain resource) in the /foo/ dir what is mapped as the wicket servlet url? No, there is no index.html anywhere on our server, I just used it to explain my felt difference to a plain html-web-server. -- Cheers, Tom Johan Compagner schrieb: Why should it redirect to /foo/xyz.abc? Because I've entered /foo/ and a typical plain-html-webserver redirects to /foo/index.html. Thats not true many serve you the index.html on that dir but in the url you mostly just see / At least for homepages this is mostly the case. What kind of resource is not found? Can you give an example? I've tried to sketch that in my original posting. Sorry, if it wasn't clear enough. I'll try with different wordings: I enter the URL http://localhost:8080/foo/ in the browser. My Index.html (and the page content ariving my browser) contains a graphic reference to graphics/logo.png (it is found and displayed correctly when I enter the URL http://localhost:8080/foo/graphics/logo.png). Since the wicket-servlet obviously is redirecting to http://localhost:8080/foo?page=0 http://localhost:8080/foo?page=0, the browser obviously expects the graphic to be at http://localhost:8080/graphics/logo.png (note the missing /foo after the port!). so you just want to mix wicket pages and resources in the root of youre webapplication? Or are you also serving index.html (a plain resource) in the /foo/ dir what is mapped as the wicket servlet url? That shouldn't be done. What does that index.html do?? Move it to the real root of youre webapplication. /foo is there for dynamic pages. johan --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] URL redirect
wicket just does everything under /foo?xxxSo if you have plain web resources that are not served by wicket through shared resourcesthen just take that path into account in youre html files On 2/14/06, Tom S. [EMAIL PROTECTED] wrote: Thats not true many serve you the index.html on that dir but in the url you mostly just see / At least for homepages this is mostly the case.Visually it does not change to /foo/index.html, but it behaves like this, because the resources are fetched relative to this path. so you just want to mix wicket pages and resources in the root of youre webapplication?First, /foo/ should be the root of our web-application. According to our provider, we later can map a domain to such a directory, so www.company.commaps to http://ourserver/foo/. At least, that's how I understood it. Or are you also serving index.html (a plain resource) in the /foo/ dir what is mapped as the wicket servlet url?No, there is no index.html anywhere on our server, I just used it to explainmy felt difference to a plain html-web-server. --Cheers,TomJohan Compagner schrieb: Why should it redirect to /foo/xyz.abc? Because I've entered /foo/ and a typical plain-html-webserver redirects to /foo/index.html. Thats not true many serve you the index.html on that dir but in the url you mostly just see / At least for homepages this is mostly the case. What kind of resource is not found? Can you give an example? I've tried to sketch that in my original posting. Sorry, if it wasn't clear enough. I'll try with different wordings: I enter the URL http://localhost:8080/foo/ in the browser. My Index.html (and the page content ariving my browser) contains a graphic reference to graphics/logo.png (it is found and displayed correctly when I enter the URL http://localhost:8080/foo/graphics/logo.png). Since the wicket-servlet obviously is redirecting to http://localhost:8080/foo?page=0 http://localhost:8080/foo?page=0, the browser obviously expects the graphic to be at http://localhost:8080/graphics/logo.png (note the missing /foo after the port!). so you just want to mix wicket pages and resources in the root of youre webapplication? Or are you also serving index.html (a plain resource) in the /foo/ dir what is mapped as the wicket servlet url? That shouldn't be done. What does that index.html do?? Move it to the real root of youre webapplication. /foo is there for dynamic pages. johan---This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems?Stop!Download the new AJAX search engine that makessearching your log files as easy as surfing theweb.DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642___Wicket-user mailing list Wicket-user@lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/wicket-user
[Wicket-user] URL redirect
OK, I now can read my html files from a different location. But I still have a serious problem with resources (e.g. graphics). The servlet mapping in the web.xml looks like this: servlet-mapping servlet-nameMyWebApplication/servlet-name url-pattern/foo/*/url-pattern /servlet-mapping When I open the URL http://localhost:8080/foo/graphics/logo.png, the graphic is shown. In the Index.html (my home page), it is references as graphics/logo.png. Unfortunately it cannot be found when displaying the home page with the URL http://localhost:8080/foo/, most likely because it redirects the request to http://localhost:8080/foo?path=0, which is a directory change. Is there a possibility to redirect to http://localhost:8080/foo/index.html or something similar, so the relative paths work as expected? -- Thanks in advance, Tom PS: I'm not experienced with web applications, so please excuse these dumb questions. --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] URL redirect
you should put index.html in your context root and have a metaredirect to /foo insidesomething like this:htmlhead meta http-equiv=Refresh content=0; url="" /head/html-IgorOn 2/13/06, Tom S. [EMAIL PROTECTED] wrote: OK, I now can read my html files from a different location. But I still havea serious problem with resources ( e.g. graphics). The servlet mapping in theweb.xml looks like this: servlet-mapping servlet-nameMyWebApplication/servlet-name url-pattern/foo/*/url-pattern /servlet-mappingWhen I open the URL http://localhost:8080/foo/graphics/logo.png, the graphicis shown. In the Index.html (my home page), it is references as graphics/logo.png. Unfortunately it cannot be found when displaying thehome page with the URL http://localhost:8080/foo/, most likely because itredirects the request to http://localhost:8080/foo?path=0, which is adirectory change.Is there a possibility to redirect to http://localhost:8080/foo/index.html or something similar, so the relative paths work as expected?--Thanks in advance,TomPS: I'm not experienced with web applications, so please excuse these dumbquestions.--- This SF.net email is sponsored by: Splunk Inc. Do you grep through log filesfor problems?Stop!Download the new AJAX search engine that makessearching your log files as easy as surfing theweb.DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642___ Wicket-user mailing listWicket-user@lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/wicket-user