<%@ LANGUAGE = JScript %> <% // Edit the account information account, like password and e-mail address. var DEBUG_NoMail = true; var DEBUG_IdentityXSL = false; var DEBUG_AllLanguages = false; var DEBUG_WriteFormParams = false; var DEBUG_WriteKeyValues = false; var paramSecondRound; var paramLang = "DE"; // check first if user logged in already... // if not redirect to login page, carry the arguments along. Response.Buffer=true; var sessionID = Request.Cookies("sic-user"); if (sessionID == "0" || sessionID == ""){ // user has not registered yet, go to login script Response.Redirect("login.asp"); } paramLang = Request.QueryString("param-lang").item; if (paramLang == null) paramLang = Request.Form("param-lang").item; if (paramLang == null) paramLang="EN"; var translations = Server.CreateObject("Microsoft.XMLDOM"); translations.async=false; translations.load(Server.MapPath("translations\\" + paramLang + ".xml")); var outTitle = translations.selectSingleNode("/translations/ui/editAccount/title/@translation").text; var outBody = translations.selectSingleNode("/translations/ui/editAccount/body").xml; var outCurrentPassword = translations.selectSingleNode("/translations/ui/editAccount/currentPassword/@translation").text; var outEmail = translations.selectSingleNode("/translations/ui/editAccount/email/@translation").text; var outPasswordInfo = translations.selectSingleNode("/translations/ui/editAccount/passwordInfo").xml; var outNewPassword = translations.selectSingleNode("/translations/ui/editAccount/newPassword/@translation").text; var outNewPassword2 = translations.selectSingleNode("/translations/ui/editAccount/newPassword2/@translation").text; var outSubmit = translations.selectSingleNode("/translations/ui/editAccount/submit/@translation").text; var outCancel = translations.selectSingleNode("/translations/ui/editAccount/cancel/@translation").text; var outCanceled = translations.selectSingleNode("/translations/ui/editAccount/canceled").xml; var outChanged = translations.selectSingleNode("/translations/ui/editAccount/changed").xml; var outWrongPassword = translations.selectSingleNode("/translations/ui/editAccount/wrongPassword").xml; var outWrongMatch = translations.selectSingleNode("/translations/ui/editAccount/wrongMatch").xml; paramSecondRound = Request.Form("paramSecondRound").item; Response.ContentType="text/html"; %> SIC Gruppe - Karriere: Email-Formular


                  <%=outTitle %>

 
<% if (paramSecondRound == null){ // get form content from translation file // set hidden parameter paramSecondRound %> <%=outBody%>

<%=outCurrentPassword%>:

<%=outEmail%>:

<%=outPasswordInfo%>:
<%=outNewPassword%>:
<%=outNewPassword2%>:

<% }else{ var submitRequest = Request.Form("submit").item != null; if (!submitRequest){ Response.Write(outCanceled); }else { var profiles = openDB(); var loginName = getLoginNameFromSessionID(sessionID, profiles); var paramPassword = Request.Form("param-password").item; var dom = null; try{ dom = getAccountDom(loginName, profiles); }catch(e){;} if (dom == null){// login name not defined Response.Write("internal error"); }else{// check password var passwordNode = dom.selectSingleNode("/accounts/account[loginName = '" + loginName + "']/password"); var emailNode = dom.selectSingleNode("/accounts/account[loginName = '" + loginName + "']/email"); // check that password is OK if (passwordNode.text != paramPassword){ Response.Write(outWrongPassword); }else{ var paramEmail = Request.Form("param-email").item; var paramNewPassword1 = Request.Form("param-new-password1").item; var paramNewPassword2 = Request.Form("param-new-password2").item; if (paramNewPassword1 != paramNewPassword2){ Response.Write(outWrongMatch); }else{ // do the changes... if (paramNewPassword1 != null && paramNewPassword1 != ""){ passwordNode.text = paramNewPassword1; } if (paramEmail != null && paramEmail != ""){ emailNode.text = paramEmail; } setAccountDom(dom, profiles); Response.Write(outChanged); } } } profiles.close(); } } %>
 
 

Copyright (c) 2000 SIC Group
Design by Fragment Art & Research, Inc.

 

<% Response.Flush(); %>