[Date Prev][Date Next][Thread Prev][Thread Next][Interchange by date
][Interchange by thread
]
[ic] Profiles for checking without ordering
John Allman wrote:
> Aaron Hazelton wrote:
>
> >John Allman wrote:
> >
> >
> >>Hi - i realise this is a bit of a stupid question but i'm
> having real
> >>hassle. can somebody post a simple example of using
> >>mv_order_profile to
> >>ensure that fields are filled out correctly in a page when
> >>that page has
> >>nothing to do with the order process?
> >>
> >>
> >>
> >
> >im not exactly sure if this is what you are looking for, but
> >if you say, would like to require certain fields in a form and
> >it does not have to do with the ordering, then you can do
> >this:
> >
> > [set Check_form]
> > &success=fbresults
> > &fail=@@MV_PAGE@@
> > email=required
> > &fatal=1
> > [/set]
> >
> > <form action="[process]" method="post">
> > <input type=hidden name=mv_todo value=set>
> > <input type=hidden name=mv_form_profile value="Check_form">
> >
> > <td align=right>
> > [error name=email std_label="Your E-mail" required=1]:
> > </td>
> > <td>
> > <input type=text name=email value="[value email]">
> > </td>
> >
> > </form>
> > [seti clear_errors][error all=1 hide=1 comment="Clear
> errors"][/seti]
> >
> >
> >
>
> It is something precicely like this that i am looking for however the
> above code doesn't work for me. I was getting odd page not
> found errors
> which i imagine were related to the @@MV_PAGE@@ bit so i
> tried changing
> it to be index. now, no matter what i enter into the email field, or
> even if i enter nothing at all i get passed to the index page with no
> complaints. Wait, make that "i get the following complaints:
> 192.168.0.145 Ba2unTJd:192.168.0.145 -
> [29/October/2002:17:56:20 +0000]
> hoi /cgi-bin/hoi/process.html Attempted database update without
> permission, table= key=.
> 192.168.0.145 Ba2unTJd:192.168.0.145 -
> [29/October/2002:17:56:23 +0000]
> hoi /cgi-bin/hoi/process.html Attempted database update without
> permission, table= key=."
>
> i'm guessing these are a result of the mv_todo being "set"
> and possibly
> not related to my problem though.
>
> any ideas?
I have one like this that updates a table:
[set update_database]
[set mv_data_enable]1[/set]
[tag flag write]feedback[/tag]
[/set]
[set Check_form]
&success=fbresults
&fail=@@MV_PAGE@@
email=required
&fatal=1
[/set]
<form action="[process]" method="post">
<input type=hidden name=mv_todo value=set>
<input type=hidden name=mv_form_profile value="Check_form">
<input type=hidden name=mv_session_id value="[data session id]">
<input type=hidden name=mv_click value="update_database">
<input type=hidden name=mv_nextpage value="fbresults">
<INPUT TYPE=hidden NAME=mv_data_table VALUE="feedback">
<INPUT TYPE=hidden NAME=mv_data_key VALUE="email">
<INPUT TYPE=hidden NAME=mv_update_empty VALUE="1">
<INPUT TYPE=hidden NAME=mv_data_function VALUE="insert">
<input type=hidden name=mv_data_fields value="email'>
note that I think you still need the mv_nextpage form variable...
_______________________________________________
Sincerely,
Aaron Hazelton
>>Hazenet<<