javascript invokes the url you give it, so it looked like it should
work. you might have to trace deeper to see whats going on.

-igor

On Thu, Jul 23, 2009 at 4:41 AM, Arthur Leigh
Allen<arthurleigh.al...@yahoo.de> wrote:
> Hi Igor,
>
> I did it as you said.
> I took the code from AjaxFallbackButton and I copied it to an own class.
> In the constructor I overwrite the getCallbackUrl() method of the 
> AjaxFormSubmitBehavior.
> I added the value https://localhost:8443/projectname/ as a prefix to 
> super.getCallbackUrl().
> By the way: getCallbackUrl() returns a long relative url beginning with 
> ";sessionid".
> So my url is https://localhost:8443/projectname/;sessionid...
>
> When starting tomcat and accessing the website, the url wasn't applied.
> When clicking the link, the url http://localhost:8080/projectname/# was 
> called.
> I believe it's the wrong place to manipulate the url. Maybe it is expected to 
> return a relative path
> beginning with ";sessionid". That url is maybe manipulated at a different 
> place, so in my case the
> end result would be 
> http://localhost:8080/projectname/https://localhost:8443/projectname/;sessionid.
> That would result in an error and maybe 
> http://localhost:8080/projectname/# is used therefore.
>
> Am I wrong?
>
> Thx
> Arthur
>
>
>
>
> ________________________________
> Von: Igor Vaynberg <igor.vaynb...@gmail.com>
> An: users@wicket.apache.org
> Gesendet: Mittwoch, den 22. Juli 2009, 18:31:27 Uhr
> Betreff: Re: AW: SSL - ajax login
>
> ah, i thought i replied already because i looked into this yesterday.
>
> you will have to roll your own button. i would recommend looking at
> the sourcecode of the default button. when you add the
> formsubmitbehavior in your button you can override getcallbackurl()
> and append https to it.
>
> -igor
>
> On Wed, Jul 22, 2009 at 2:37 AM, Arthur Leigh
> Allen<arthurleigh.al...@yahoo.de> wrote:
>> Hi again,
>>
>> I need to know if it's possible to switch to SSL via button or form.
>> Otherwise I have to switch back to wicket 1.3.5. I'm in hurry because
>> we will go online within the next 10-14 days.
>>
>> Can anyone give me a prompt answer please?
>>
>> Thx & Best regards
>> Arthur
>>
>>
>>
>> ________________________________
>> Von: Arthur Leigh Allen <arthurleigh.al...@yahoo.de>
>> An: users@wicket.apache.org
>> Gesendet: Dienstag, den 21. Juli 2009, 19:18:18 Uhr
>> Betreff: AW: SSL - ajax login
>>
>> Hello Igor,
>>
>> thanks for your early reply.
>> Yes, my login form is submitted via ajax.
>>
>> public class BasePage {
>>
>>     public void switchViaAjax(...) { ... }
>>     public void navigateViaAjax(...) { ... }
>>
>> }
>>
>> @RequireHttps
>> public class SSLForm extends Form { ... }
>>
>> public class LoginPanel {
>>
>>     public LoginPanel() { ... }
>>
>>     public create() {
>>         SSLForm form = new SSLForm("loginForm");
>>         form.add(username);
>>         form.add(password);
>>
>>         AjaxFallbackButton loginButton = new 
>> AjaxFallbackButton("loginButton", form) {
>>             protected void onSubmit(AjaxRequestTarget target, Form form) {
>>                 // perform login => login is done via http
>>             }
>>         }
>>     }
>> }
>>
>> As you said @RequireSSL is for pages.
>> Do you have any idea how I can remove @RequireHttps from the top of my 
>> BasePage and switch to https on login?
>> Currently I think the only way to provide a ssl ajax call is to show the 
>> base page via ssl as a starting basis.
>>
>> Therefore I have to use @RequireSSL on the BasePage but that means every 
>> communication is done via ssl
>> and that means more server ballast and a slower page refresh.
>>
>> Greetings
>> Arthur
>>
>>
>>
>> ________________________________
>> Von: Igor Vaynberg <igor.vaynb...@gmail.com>
>> An: users@wicket.apache.org
>> Gesendet: Dienstag, den 21. Juli 2009, 18:08:48 Uhr
>> Betreff: Re: SSL - ajax login
>>
>> @RequreHttps is meant to be a page-level feature, so it doesnt fit your 
>> usecase.
>>
>> is your login form submitted via ajax?
>>
>> show us the code to sslform, your login form - making sure to include
>> the code to the component that submits it.
>>
>> -igor
>>
>> On Tue, Jul 21, 2009 at 8:34 AM, Arthur Leigh
>> Allen<arthurleigh.al...@yahoo.de> wrote:
>>> Hello folks,
>>>
>>> I'm using wicket 1.4 RC7 now and I have a question regarding the usage of 
>>> ssl.
>>> I use the HttpsRequestCycleProcessor with the annotation @RequireHttps.
>>>
>>> Imagine the following case like it is realized on different sites like 
>>> web.de or gmx.de as well as xing.com.
>>> The first call will result in a http url. If you enter your login name and 
>>> your password and submit the form,
>>> then the form will be send via https.
>>>
>>> I only have one page. Everything on my page is exchanged via ajax. The 
>>> login is also done via ajax.
>>> Currently I use the annotation above for my BasePage but from the first 
>>> call, the whole communication
>>> is done with ssl.
>>>
>>> What I would like to realize is: Using the @RequireHttps annotation on 
>>> forms or submit buttons.
>>> I implemented an own SSLForm class extending the wicket form class with the 
>>> annotation.
>>> But when I use the SSLForm for my login, the communication is done without 
>>> ssl.
>>> I would like to use my page via http, but the ajax login should be done 
>>> with ssl.
>>>
>>> The only thing I can do now is:
>>> -page completely with ssl
>>> -page completely without ssl
>>>
>>> I would appreciate any help.
>>>
>>> Best regards,
>>> Arthur
>>>
>>>
>>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>> For additional commands, e-mail: users-h...@wicket.apache.org
>>
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org

Reply via email to