I'm trying to look for a how I can pass the value from in input textbox *href="sms:?body" It is a dynamic value that changes every time a user creates a new account. The idea is that once I click on the "Send Invite by SMS" the value or referral code that is included in the input text will also be included in the SMS body message.
正在进行的示例工作
<input class="input" disabled="true" placeholder="Referral Code" ng-model="account.referral_code_string" id="input-refcode">
<a ng-model="account.referral_code_string" href="sms:?body=" class="sms-btn" >Send Invite by SMS</a>
更新
我已设法绑定短信主播上的输入文本,但是当我尝试点击该按钮时,短信应用程序无法打开。它显示不安全:短信,但当我尝试仅使用带有示例文本的href(href =“sms:?body = text”)时,它会打开短信应用
答案 0 :(得分:1)
您可以使用ngHref将其附加到您的链接。
static public void GenerateOrder(string Time, string Date)
{
MySqlConnection conn = new MySqlConnection("server = localhost; uid = root; database = coursework; password = root;");
conn.Open();
MessageBox.Show(Date + Time);
string statement = ("INSERT INTO order (CustomerID, Name, Date, Time, Price) VALUES(" + Users.UserID + ",'" + Users.Firstname + "','" + Date + "','" + Time + "'," + OrderPrice + ");");
MessageBox.Show(statement);
MySqlCommand cmd = new MySqlCommand(statement, conn);
cmd.ExecuteNonQuery();
MessageBox.Show("Order successfully placed.");
conn.Close();
}