%include;css %include;hed
%message_to_wizard; %( do not use %include;perso_header %) %include_perso_header; %define;nav() %end; %define;card_header(xx,yy)
 

%end; %define;date(xlab,xvar,xdt,xcond) %let;day_input;pattern="(?:0?[1-9]|1[0-9]|2[0-9]|3[0-1])" size="1" maxlength="2" xcond%in; %let;month_input;pattern="(?:0?[1-9]|1[0-2]|VD|BR|FM|NI|PL|VT|GE|FL|PR|ME|TH|FT|JC|vd|br|fm|ni|pl|vt|ge|fl|pr|me|th|ft|jc)" size="1" maxlength="2" xcond%in; %let;year_input;pattern="[?><~/-+]?\d*/?" size="4" maxlength="8" xcond%in;
xlab
%if;([!dates order]0 = "ddmmyy" or [!dates order]0 = "ddmmyyyy" or [!dates order]0 = "dmyyyy") %elseif;([!dates order]0 = "mmddyyyy") %else; %end;
%if;([!dates order]0 = "ddmmyy" or [!dates order]0 = "ddmmyyyy" or [!dates order]0 = "dmyyyy") %elseif;([!dates order]0 = "mmddyyyy") %else; %end;
%end; %define;note(xx)
%end; %define;source(xx)
%end; %define;selector_pevent(xcnt) %end; %define;insert_pevent(xcnt)
%end; %define;insert_witness(xcnt, wcnt, evt_name)
%(
[*insert]  [nouveau(x)::witness/witnesses]0 %if;("evt_name" = "#bapt")/ [godfather/godmother/godparents]2%end;
%) %end; %define;one_witness(xcnt, wcnt, evt_name)
[*witness/witness/witnesses]0 wcnt
[*sex]
%end; %(%) %define;one_pevent(xcnt) %if;(event.e_name != "#birt" and event.e_name != "#bapt" and event.e_name != "#deat" and event.e_name != "#buri" and event.e_name != "#crem")
%apply;selector_pevent(xcnt)
%apply;date([*date/dates]0, "e_datexcnt", "event_date", "")
%if;(event.e_src!="") %else; %end;
%if;has_witness; %foreach;witness; %apply;one_witness(xcnt, wcnt, "") %if;is_last;%apply;insert_witness(xcnt, wcnt, "")%end; %end; %else; %apply;insert_witness(xcnt, "0", "") %end;
%end; %end %(%) %define;one_specific_pevent(xcnt, evt_name) %if;(event.e_name = "evt_name") %if;("evt_name" = "#deat")
%end; %if;("evt_name" = "#buri" or "evt_name" = "#crem")
%end;
%apply;date%with;[*date/dates]0%and;e_datexcnt%and;event_date%and;%if;("evt_name" = "#deat")onfocus='set_death_focus(xcnt)'%end;%end;
%if;(event.e_src!="") %else; %end;
%if;(has_witness) %foreach;witness; %apply;one_witness(xcnt, wcnt, "evt_name") %if;is_last;%apply;insert_witness(xcnt, wcnt, "evt_name")%end; %end; %else; %apply;insert_witness(xcnt, "0", "evt_name") %end; %end; %end; %define;one_empty_specific_pevent(xcnt, evt_name) %if;("evt_name" = "#deat")
%end; %if;("evt_name" = "#buri" or "evt_name" = "#crem" or "evt_name" = "buri_or_crem")
%end;
%( should be %evt_name; ? %)
%if;("evt_name"="#deat") %apply;date([*date/dates]0, "e_datexcnt", "event_date", "onfocus='set_death_focus(xcnt)'") %elseif("evt_name"="buri_or_crem") %apply;date([*date/dates]0, "e_datexcnt", "event_date", "onfocus='set_buri(xcnt)'") %else; %apply;date([*date/dates]0, "e_datexcnt", "event_date", "") %end;
%( %if;("evt_name" = "#bapt") %apply;one_empty_witness(xcnt, "1", "evt_name") %apply;one_empty_witness(xcnt, "2", "evt_name") %end; %if;("evt_name" = "#bapt") %apply;insert_witness(xcnt, "1", "evt_name") %else; %apply;insert_witness(xcnt, "0", "evt_name") %end; %) %apply;insert_witness(xcnt, "0", "evt_name") %end %let;l_on1s;onkeydown="if (event.keyCode == 13) if (!event.shiftKey) javascript:document.upd.submit()"%in;
%apply;nav()
%hidden; %if;(evar_m = "MRG_IND_OK" or evar_m = "MRG_MOD_IND_OK") %if;(evar_i2 != "") %end; %if;(evar_ini1 != "" and evar_ini2 != "") %end; %if;(evar.iexcl != "" or evar.fexcl != "") %if;(evar.iexcl != "") %end; %if;(evar.fexcl != "") %end; %end; %elseif;(evar_m = "MOD_IND" or evar_m = "MOD_IND_OK") %else; %end;

%nn; %if;(evar_m = "MRG_IND_OK" or evar_m = "MRG_MOD_IND_OK") [*merge::person/persons]1[:] %first_name; %surname; %if;(first_name != "?" and surname != "?") %sp;([reference key][:] %first_name;.%if;(occ = "")0%else;%occ;%end; %surname) %end; %elseif;(evar_m = "MOD_IND" or evar_m = "MOD_IND_OK") [*modify::person/persons]0[:] %first_name;.%if;(occ = "")0%else;%occ;%end; %surname; %else; [*add::person/persons]0%end;

[*other action][:] [*invert::event/events]1 | %if;(bvar.can_send_image != "no" and image = "" and first_name != "?" and surname != "?") [*modify::]/[delete::]/[add picture] %end; | [*merge::] | [*delete::]
[*sex]
[*access]0
%if;has_qualifiers; %foreach;qualifier;
%end; %elseif;(bvar.propose_qualifier != "no")
%end; %if;has_aliases; %foreach;alias;
%end; %elseif;(bvar.propose_alias != "no")
%end; %if;has_first_names_aliases; %foreach;first_name_alias;
%end; %else;
%end; %if;has_surnames_aliases; %foreach;surname_alias;
%end; %else;
%end;
%if;(occupation!="") %else; %end;
%if;(sources!="") %else; %end;
%apply;card_header("birth","birth")
[*born]2...
%apply;date([*date/dates]0, "birth", "birth", "") %apply;note("birth") %apply;source("birth")
%if;has_pevent_birth; %foreach;pevent; %apply;one_specific_pevent(cnt, "#birt") %end; %else; %apply;one_empty_specific_pevent%with;%next_pevent;%and;#birt%end; %incr_next_pevent; %end;
%apply;card_header("baptism","baptism")
[*baptized]2...
%apply;date([*date/dates]0, "bapt", "bapt", "") %apply;note("bapt") %apply;source("bapt")
%if;has_pevent_baptism; %foreach;pevent; %apply;one_specific_pevent(cnt, "#bapt") %end; %else; %apply;one_empty_specific_pevent%with;%next_pevent;%and;#bapt%end; %incr_next_pevent; %end;
%apply;card_header("death","death")
%apply;date([*date/dates]0, "death", "death", "onfocus='setDead()'")
%apply;note("death") %apply;source("death")
%if;has_pevent_death; %foreach;pevent; %apply;one_specific_pevent(cnt, "#deat") %end; %else; %apply;one_empty_specific_pevent%with;%next_pevent;%and;#deat%end; %incr_next_pevent; %end;
%apply;card_header("burial","burial")
%apply;date([*date/dates]0, "burial", "burial", "") %apply;note("burial") %apply;source("burial")
%if;has_pevent_burial; %foreach;pevent; %apply;one_specific_pevent(cnt, "#buri") %end; %end; %if;has_pevent_cremation; %if;has_pevent_burial;

%end; %foreach;pevent; %apply;one_specific_pevent(cnt, "#crem") %end; %end; %if;(not has_pevent_burial and not has_pevent_cremation) %apply;one_empty_specific_pevent%with;%next_pevent;%and;buri_or_crem%end; %incr_next_pevent; %end;
%apply;card_header("events","event/events")
%if;has_secondary_pevents; %foreach;pevent; %apply;one_pevent(cnt) %end; %apply;insert_pevent%with%next_pevent;%end; %incr_next_pevent; %else; %apply;insert_pevent%with%next_pevent;%end; %incr_next_pevent; %end;
%define;insert_relation(xx)
[*insert]
%end; %define;relation_type(xx)
%end; %define;one_relation(xcnt,xvar,xrel,xsex)

([sex]0 xsex)

%end;
%apply;card_header("relations","relation/relations")
%apply;insert_relation("0") %if;has_relations; %foreach;relation;
%apply;relation_type(cnt) %apply;one_relation(cnt,"fath","r_father",[M/F]0) %apply;one_relation(cnt,"moth","r_mother",[M/F]1)
%apply;insert_relation(cnt) %end; %else;
%apply;relation_type("1") %apply;one_relation("1","fath","r_father",[M/F]0) %apply;one_relation("1","moth","r_mother",[M/F]1)
%apply;insert_relation("1") %end;
%define;insert_title(xcnt)
%end; %define;one_title(xcnt)
%apply;date([*begin]0, "t_date_startxcnt", "title_date_start", "") %apply;date([*end]0, "t_date_endxcnt", "title_date_end", "") %end
%apply;card_header("titles","title/titles")
%apply;insert_title("0") %if;has_titles; %foreach;title; %apply;one_title(cnt)
%apply;insert_title(cnt) %end; %else; %apply;one_title("1")
%apply;insert_title("1") %end;
%apply;card_header("notes","note/notes")
%include;toolbar
%sq;
%include;accent
%include;trl %include;copyr
%include;js