confirmation

javascript popup alert on link click

我们两清 提交于 2019-12-18 03:05:12
问题 I need a javascript 'OK'/'Cancel' alert once I click on a link. I have the alert code: <script type="text/javascript"> <!-- var answer = confirm ("Please click on OK to continue.") if (!answer) window.location="http://www.continue.com" // --> </script> But how do I make it so this only runs when clicking a certain link? 回答1: just make it function, <script type="text/javascript"> function AlertIt() { var answer = confirm ("Please click on OK to continue.") if (answer) window.location="http:/

Customer name incomplete on order confirmation

僤鯓⒐⒋嵵緔 提交于 2019-12-14 03:25:52
问题 Came across the following during a project: Customer fills out his/her name during checkout: Firstname Middlename Lastname The confirmation email sent contains incomplete name in the form of " Firstname Lastname " on the first sentence of the confirmation I looked at the mail templates and the function order.getCustomerName() does not seem to retrieve all the information. 回答1: You can set this in the customer address settings of admin. Admin → System → configuration → Customer Configuration →

TVirtualStringTree. How to check a node and its children with a single confirmation?

偶尔善良 提交于 2019-12-13 03:29:46
问题 I have a component of type TVirtualStringTree . The option toCheckSupport is enabled. The options related to the propagation of checkstates are also enabled, because the propagation is needed. I want to implement checking a node with a confirmation ("Are you sure you want to check... ?"). Unfortunately, if the options for propagation are enabled, the events OnCheck and OnChecking are triggered including for the child nodes. Therefore, placing the message in the event procedures make it show

Javascript confirmation popup

佐手、 提交于 2019-12-12 19:23:10
问题 I am new to javascript and web development, now I am experimenting in codeigniter and I want to setup a javascript confirmation box on a delete link. Now I got it to work reasonably well using this: <script type="text/javascript"> function con(message) { var answer = confirm(message); if (answer) { return true; } return false; } </script> and this: echo '<a href="/groups/deletegroup/'.$group->id.'" OnClick="return con(\'Are you sure you want to delete the group?\');" class="btn small light

How do I define a custom URL for a form confirmation page?

情到浓时终转凉″ 提交于 2019-12-12 02:54:07
问题 I am creating a basic product landing page with Rails in which users can enter their email address to be notified when the product launches. (Yes, there are services/gems etc that could do this for me, but I am new to programming and want to build it myself to learn rails.) On successful submit of the form, I would like to redirect to a custom '/thanks' page in which I thank users for their interest in the product (and also encourage them to complete a short survey.) Currently, successful

Confirmation box didnt show hebrew

让人想犯罪 __ 提交于 2019-12-11 23:21:23
问题 I build my project in asp.net and for one of my frm I write script with confermation box. The function works great beside the hebrew msg. ie and chrom showen "?" mark instead of the hebrew characters i wrote. function ConfirmDeleteTeacher() { var confirm_value = document.createElement("INPUT"); confirm_value.type = "hidden"; confirm_value.name = "confirm_value"; if (confirm("בלה בלה?")) { confirm_value.value = "Yes"; } else { confirm_value.value = "No"; } document.forms[0].appendChild(confirm

How does this “higher-order functions” thing works in Javascript

牧云@^-^@ 提交于 2019-12-11 19:26:51
问题 From the book Eloquent Javascript by Marijn Haverbeke, there is this example while introducing the concept of higher-order functions: function greaterThan(n) { return function(m) { return m > n; }; } var greaterThan10 = greaterThan(10); console.log(greaterThan10(11)); // → true I'm not quite sure how this works... probably answering my own question, but this is how I see it: First, greaterThan(n) is called in this line, assigning its value to the greaterThan10 variable: var greaterThan10 =

cognalys verification error 550 and 551

霸气de小男生 提交于 2019-12-11 16:51:18
问题 I'm using cognalys sdk in my app for user verification but i get the errors 551 and 550 which are not listed on their site and I don't know what are they, here is the code I use: Cognalys.verifyMobileNumber(SignupActivity.this,"token", "id","number", new VerificationListner() { @Override public void onVerificationStarted() { Toast.makeText(getApplicationContext(), "Started", Toast.LENGTH_LONG).show(); } @Override public void onVerificationFailed(ArrayList<String> errorList) { for (String

Jquery confirmation not working

三世轮回 提交于 2019-12-11 12:30:08
问题 I tried this: https://stackoverflow.com/a/12617274/4164311. The string "Are you sure about this" just appears in my browser and nothing happens when I click the button. <html lang="en"> <head> <meta charset="utf-8"> <title>jQuery UI Dialog - Modal confirmation</title> <link rel="stylesheet" href="jquery-ui.min.css"> <script src="external/jquery/jquery.js"></script> <script src="jquery-ui.min.js"></script> <script> $("#dialog").dialog({ autoOpen: false, modal: true, buttons : { "Confirm" :

Confirmation box from server side in asp.net

随声附和 提交于 2019-12-10 19:56:47
问题 I want to show the confirmation box in asp.net from server side: I want to call it from server side because I have to take the customer message from server side. I am using the below code string str = "Are you sure, you want to Approve this Record?"; ClientScript.RegisterStartupScript(typeof(Page), "Popup", "return confirm('" + str + "');",true); // More code .... Now it is showing the popup and irrespective of what I click, whether "ok" or "Cancel", my code is executing. Please let me know