var setting = new Array(); setting.siteRootUrl = "https://www.kinthia.com"; setting.socketioUrl = "https://www.kinthia.com:5000"; setting.urlRewriting = "1"; setting.currencySymbol = "$"; setting.languageCode = "en"; setting.lang = new Object(); setting.lang["javascriptConfig_today"] = "Today"; setting.lang["javascriptConfig_characters_left"] = "Characters left"; setting.lang["javascriptConfig_expert_availability_confirm"] = "Are you available?"; setting.lang["javascriptConfig_yes"] = "Yes"; setting.lang["javascriptConfig_timezone_has_been_changed"] = "Your timezone has been changed"; setting.lang["javascriptConfig_confirm"] = "You won't be able to revert this!"; setting.lang["javascriptConfig_success"] = "Success"; setting.lang["Loading"] = "Loading"; setting.lang["Loading..."] = "Loading..."; setting.lang["Please enter your pseudo"] = "Please enter your pseudo"; setting.lang["Please enter your email"] = "Please enter your email"; setting.lang["Please confirm your email"] = "Please confirm your email"; setting.lang["Please enter password"] = "Please enter password"; setting.lang["Please confirm your password"] = "Please confirm your password"; setting.lang["Please enter captcha code"] = "Please enter captcha code"; setting.lang["Your email must be in format - name@domain.com"] = "Your email must be in format - name@domain.com"; setting.lang["Your changes were saved"] = "Your changes were saved"; setting.lang["You just add to cart the next product"] = "You just add to cart the next product"; setting.lang["Your message was sent"] = "Your message was sent"; setting.lang["Your comment was saved"] = "Your review was saved"; setting.lang["New password was sent to your email"] = "New password was sent to your email"; setting.lang["Wrong password"] = "Wrong password"; setting.lang["Change email"] = "Change email"; setting.lang["Change password"] = "Change password"; setting.lang["This field is required"] = "This field is required"; setting.lang["New password changed"] = "New password changed"; setting.lang["Thank you, we are processing your payment"] = "Thank you, we are processing your payment"; setting.lang["Please enter a correct date, needed format is dd/mm/YYYY"] = "Please enter a correct date, needed format is dd/mm/YYYY"; setting.lang["Please enter a subject"] = "Please indicate the subject of your request"; setting.lang["Please enter a description"] = "Please describe your request"; setting.lang["Refund request sended"] = "Your refund request has been sent successfully."; setting.lang["Your password changed"] = "Your password has been successfully changed. You can now log in with your new password."; setting.lang["File"] = "File"; setting.lang["was uploaded sucessfully"] = "was uploaded sucessfully"; setting.lang["of"] = "of"; setting.lang["available photos uploaded"] = "available photos uploaded"; setting.lang["Passwords aren't equal"] = "Passwords aren't equal"; setting.lang["Emails aren't equal"] = "Emails aren't equal"; setting.lang["Email was used earlier"] = "javascript_config_emails_was_used_earlier"; setting.lang["Expert Cancel Request"] = "The expert has cancelled your consultation request."; setting.lang["Expert is not online"] = "The expert is not available"; setting.lang["User cancel request"] = "The user has cancelled your consultation request."; setting.lang["Maintenance Mode"] = "Maintenance Mode"; setting.lang["You have cancel the request"] = "You have cancelled your consultation request"; setting.lang["Request sent to expert, please wait for response"] = "Consultation request sent to the expert, please wait..."; setting.lang["User is not online"] = "User is not online."; setting.lang["Please wait for response from user"] = "Consultation request sent to user, please wait..."; setting.lang["javascript_start_typing"] = "[user] is typing"; setting.lang["Server is down"] = "Server not responding"; setting.lang["Sorry, the expert you wish to consult could not answer. You can try again later or choose another expert"] = "Sorry, the expert you wish to consult is unable to attend. You can try again later or choose another expert."; setting.lang["In consultation since"] = "In consultation for: "; setting.lang["Verify that you are human."] = "Verify that you are human."; setting.lang["Loading challenge..."] = "Loading challenge..."; setting.lang["Select the image displayed the least amount of times"] = "Select the image displayed the least amount of times"; setting.lang["Verification complete."] = "Verification complete."; setting.lang["Uh oh."] = "Uh oh."; setting.lang["You've selected the wrong image."] = "You've selected the wrong image."; setting.lang["Please wait."] = "Please wait."; setting.lang["You made too many incorrect selections."] = "You made too many incorrect selections."; setting.lang["Delete favorite"] = "Delete favorite"; setting.lang["Make favoris"] = "Make favorite"; setting.lang["No More Reviews"] = "No more reviews"; setting.lang["Start consultation"] = "Start consultation"; setting.lang["Buy a time pack"] = "Buy a credit pack"; setting.lang["Are you sure?"] = "Are you sure?"; setting.lang["Be alerted to the expert presence"] = "Be alerted to the expert's presence"; setting.lang["Not supporting in browser"] = "Not supporting in browser"; setting.lang["Denided in browser"] = "Denided in browser"; setting.lang["Not yet a member?"] = "Not yet a member?"; setting.lang["Invalid credentials"] = "Invalid credentials"; setting.lang["email sent for reinitialization"] = "An email has just been sent to you containing a link to reset your password."; setting.lang["New email changed"] = "Your email has been successfully changed"; setting.lang["Your question has been saved"] = "Your question has been saved and sent to the expert."; setting.lang["Ask a question"] = "Ask your question"; setting.lang["Please enter your question"] = "Please enter your question"; setting.lang["question must be at least 10 characters long"] = "Question must be at least 10 characters long"; setting.lang["Please change Rating"] = "Please select a note"; setting.lang["Your review must be at least 50 characters long"] = "Your review must be at least 50 characters long"; setting.lang["You will be redirected in 5 seconds to the homepage"] = "You will be redirected in 5 seconds to the homepage"; setting.lang["Consultation refused"] = "Consultation refused"; setting.lang["activated"] = "Activated!"; setting.lang["deactivated"] = "Deactivated!"; setting.lang["Phone consultation activated!"] = "Voice call consultation activated!"; setting.lang["Phone consultation deactivated!"] = "Voice call consultation deactivated!"; setting.lang["Webcam consultation activated!"] = "Video call consultation activated!"; setting.lang["Webcam consultation deactivated!"] = "Video call consultation deactivated!"; setting.lang["Email consultation activated!"] = "Email consultation activated!"; setting.lang["Email consultation deactivated!"] = "Email consultation deactivated!"; setting.lang["Chat consultation activated!"] = "Chat consultation activated!"; setting.lang["Chat consultation deactivated!"] = "Chat consultation deactivated!"; setting.lang["vacation mode deactivated!"] = "Vacation mode deactivated!"; setting.lang["vacation mode activated!"] = "Vacation mode activated!"; setting.lang["phone"] = "Voice call consultation"; setting.lang["webcam"] = "Video call consultation"; setting.lang["chat"] = "Chat consultation"; setting.lang["email"] = "Email consultation"; setting.lang["consultation_time_is_up"] = "Psychic reading in progress. Credit is counted down."; setting.lang["wait_for_experts_response"] = "Connection in progress... Please wait."; setting.lang["time_not_counted"] = "Configuration in progress. Credit is not counted."; setting.lang["Should be selected at least one value"] = "Should be selected at least one value"; setting.lang["calendar_saved_success"] = "Your schedule has been successfully updated."; setting.lang["calendar_deleted"] = "Your schedule has been successfully updated."; setting.lang["Add new event"] = "Manage your schedule"; setting.lang["End consultation"] = "Consultation over"; setting.lang["Please review and confirm your response"] = "Once sent, the service/question will be marked as processed. Are you sure?"; setting.lang["javascriptConfig_btn_cancel"] = "Cancel"; setting.lang["javascript_config_consultation_count"] = "Consultation details"; setting.lang["javascript_config_rules"] = "Rules"; setting.lang["javascriptConfig_cookieBanner_desc"] = "We use cookies to improve your experience on our website. By browsing this website, you agree to our use of cookies."; setting.lang["javascriptConfig_btn_cookie"] = "Accept"; setting.lang["javascriptConfig_day"] = "javascriptConfig_day"; setting.lang["javascriptConfig_days"] = "javascriptConfig_days"; setting.lang["javascriptConfig_expired"] = "javascriptConfig_expired"; setting.lang["Please enter a valid phone number"] = "Please enter a valid phone number"; setting.lang["Pseudo was used earlier"] = "Username already used"; setting.lang["Your password must be at least 6 characters long"] = "Your password must be at least 6 characters long"; setting.lang["Your password cannot exceed 32 characters"] = "Your password cannot exceed 32 characters"; setting.lang["Email was used earlier"] = "Email already used"; setting.lang["Phone was used earlier"] = "Phone already used"; setting.lang["javascriptConfig_personal_information"] = "Personal information"; setting.lang["javascriptConfig_documents"] = "Documents"; setting.lang["javascriptConfig_professional_experience_and_availability"] = "Professional experience and availability"; setting.lang["javascriptConfig_step"] = "Step"; setting.lang["javascriptConfig_date_day"] = "day"; setting.lang["javascriptConfig_month"] = "month"; setting.lang["javascriptConfig_year"] = "year"; function _t(phrase, attr = {}) { let translated = (setting.lang && setting.lang[phrase]) ? setting.lang[phrase] : phrase; for (const key in attr) { if (attr.hasOwnProperty(key)) { const value = attr[key]; const placeholder = `[${key}]`; translated = translated.split(placeholder).join(value); } } return translated; } var AppRouter = { rewrites: new Array(), addRewriteRule: function(pattern, replacement) { AppRouter.rewrites.push({"pattern": new RegExp(pattern), replacement: replacement}); }, getRewrittedUrl: function(url) { // Removing http from star prevent ajax access policy problems with OPTIONS requests var rewrittedUrl = setting.siteRootUrl.replace(/http:\/\/[^\/]+/gi, ''); if(!setting.urlRewriting)rewrittedUrl += "/index.php"; for(var i = 0; i < AppRouter.rewrites.length; i++) { var rewrite = AppRouter.rewrites[i]; url = url.replace(rewrite.pattern, rewrite.replacement); } if(setting.languageCode){ rewrittedUrl += '/'+setting.languageCode; } rewrittedUrl += url; return rewrittedUrl; } }