I try to put ($func = new PhpExt_Handler($click1);) only
but in this case the redirection to login.php don't work....
On 25 fév, 16:59, Sergei Walter Guerra <
serg...@gmail.com> wrote:
> I think the problem is in the PhpExt_Handler constructor. You are setting
> two statements for the handler function:
>
> var redirect = 'login.php';
> window.location = redirect;
>
> and
>
> simple.getForm().submit({method:'POST',
> url: 'login.php'});
>
> the generated javascript for that should be:
>
> function() {
> var redirect = 'login.php';
> window.location = redirect;
> simple.getForm().submit({method:'POST',
> url: 'login.php'});
>
> }
>
> if you look closely you are redirecting the page before making the submit.
> Try not including the first statement as
>
> $func = new PhpExt_Handler($click1);
>
> I think that should make the submit as standard submit (since you are using
> '$simple->setStandardSubmit(true)' ) and send a post to login.php as you
> intend.
>
> Let me know if that works
>
> Sergei Walter
>
serg...@gmail.com
>
>
>
> On Tue, Feb 24, 2009 at 3:50 AM, Ba9 <
baklouti.wa...@gmail.com> wrote:
>
> > Hello,
> > I use in my web application the complex (Border,Accordion,tab ) and I
> > want to create a login form in the east region but at this moment I
> > can't fetch the value of the user and password with Post method then
> > this my code :
>
> > <?php
> > // East Region
> > $east = new PhpExt_Panel();
> > $east->setTitle(utf8_encode("Menu"))
> > ->setCollapsible(true)
> > ->setWidth(200);
>
> > //
>
> > ***********************SimpleForm**************************************************************************
> > ////////////////////////////////////////////////////////////////////////////////////////////////////////////////
>
> > $submit = PhpExt_Button::createTextButton("Connect")
> > ->setType(PhpExt_Button::BUTTON_TYPE_SUBMIT)
> > ->setHandler($func);
>
> > $simple->addItem($login)
> > ->addItem($pass);
>
> > $simple->addButton($submit);
>
> > $east->addItem($simple);
> > ?>
>
> > and in my OnReady function i have this code:
> > $simple->getJavascript(false, "simple"),
> > $simple->render("simple")
>
> > please help me as soon as possible and thank you in advance- Masquer le texte des messages précédents -
>
> - Afficher le texte des messages précédents -