[ic] Profiles for checking without ordering

John Allman interchange-users@icdevgroup.org
Fri Nov 1 04:31:01 2002


paul jordan wrote:

>[snip]
>  
>
>>>John, the page that handles the above profile is account.txt, look at its
>>>form.
>>>
>>>AS for your latest email. I have never seen what you are doing
>>>      
>>>
>>the way you
>>    
>>
>>>are doing... that doesn't mean it can't be done. I don't believe you can
>>>write to userdb like that.
>>>
>>>Are you trying to write this to userdb??  You may need to use it in
>>>conjunction with a [tag flag write] but I don't know is that is safe... I
>>>recommend looking into [userdb] tag if that is what you are dealing with.
>>>
>>>Paul
>>>
>>>
>>>
>>>      
>>>
>>You know i take it back. The "construct something" demo does not work
>>fine. i just generated a shiny new demo store with makecat and restarted
>>interchange. i went to the account page and left out bits of information
>>that are required fields but it doesn't complain. Now i'm thinking i've
>>borked something . i'm using interchange 4.6.5.
>>
>>this is exceedingly frustrating. the examples of verifiying form data
>>that work are in the order process. I'll try hacking one of them but i
>>know there was some reason i didn't want to do that...
>>
>>one last cry for a simple functional example for me to hack?
>>
>>going slightly mad here:(
>>
>>John
>>    
>>
>
>
>
>John, this works for me.... it has nothing to do with an order, it just
>verifies that fields are correct (to an extent), if a user decides to alter
>their address info. Again, profiles.order does not neccessarily deal only
>with the ordering process. account_change is a great axample.
>
>
>
><FORM ACTION="[process secure=1]" METHOD="POST" name="account">
><INPUT TYPE=hidden NAME=mv_session_id VALUE="[data session id]">
>
>[if type=explicit compare="[error all=1 show_var=1 keep=1]"]
><P>
><b>There were errors in your last submission.</b>
><br>
>They are shown in <FONT color="red">this color</FONT> below.</FONT>
><P>
>[/if]
>
><INPUT TYPE=hidden NAME=mv_order_profile VALUE=account_change>
><INPUT TYPE=hidden NAME=mv_todo VALUE=return>
><INPUT TYPE=hidden NAME=mv_nextpage VALUE=@@MV_PAGE@@>
><INPUT TYPE=hidden NAME=mv_failpage VALUE=account>
><INPUT TYPE=HIDDEN NAME=mv_check VALUE="Save_database">
>
>[set Save_database]
>[userdb save]
>[/set]
>
>[button text="Save" src="__BUTTON_DIR__/saveindex.gif" hidetext=1
>form="account"]
>mv_todo=submit
>mv_nextpage=profile
>[/button]
>
></form>
>
>
>In etc/profiles.order........
>
>
>__NAME__                            account_change
>fname=required
>lname=required
>address1=required
>city=required
>country=required
>[if value country =~ /^(US|CA)$/i]
>        state=state_province
>        zip=postcode Appears incorrect
>[/if]
>phone_day=phone Appears incorrect
>email=required Appears incorrect
>
>&fatal = yes
>
>email=email
>
>__END__
>
>  
>
This is looking exceedingly hopeful. Thanks!

John