[Date Prev][Date Next][Thread Prev][Thread Next][Interchange by date
][Interchange by thread
]
[ic] updating address book, mv_check versus mv_click
Quoting Jeff Dafoe (jeff@badtz-maru.com):
> > > =====
> > > [userdb function=get_shipping nickname="test2"]
> > > <form action="[process]" method=POST>
> > > ...form fields including s_nickname
> > > </form>
> > >
> > > [button name="mv_check" value="Save Shipping"
> > > src="/html/assets/images/changeUpdate.gif" border=0 hidetext=1]
> > >
> > > [set Save Shipping]
> > > mv_todo=return
> > > mv_nextpage=myAccount
> > > [userdb function=set_shipping nickname="test2"]
> > > [/set]
> > > =====
>
> I now know the secrets of mv_click and mv_check. The secret is to chain
> the mv_check to a mv_click, so the code becomes as follows:
>
> [userdb function=get_shipping nickname="test2"]
> <form action="[process]" method=POST>
> ...form fields including s_nickname
> </form>
>
> [button name="mv_click" value="click1"
> src="/html/assets/images/changeUpdate.gif" border=0 hidetext=1]
>
> [set click1]
> mv_todo=return
> mv_nextpage=myAccount
> mv_check=check1
> [/set]
>
> [set check1]
> [userdb function=set_shipping nickname="test2"]
> [/set]
>
You can also chain mv_click items:
[set click1]
[perl] $Scratch->{what} = "<li>Did something"; [/perl]
mv_click=click2
[/set]
[set click2]
[perl]
$Scratch->{what} .= "<li>Did something else";
[/perl]
[/set]
<ul>[scratch what]</ul>
[set what][/set]
[page
href=@@MV_PAGE@@
form="
mv_action=return
mv_click=click1
"]Do something and also something else</A>
Of course this means you can do an endless loop, so don't do that. 8-)
--
Mike Heins
Perusion -- Expert Interchange Consulting http://www.perusion.com/
phone +1.513.523.7621 <mike@perusion.com>
Software axiom: Lack of speed kills.