好的,这是CFML的答案:)
<cfset email = "bob@google.com" />
<cfif ListLast(email, "@") EQ "google.com">
Horray!
</cfif>
Run Code Online (Sandbox Code Playgroud)
编辑
特别为Amarghosh.我们可以这样做,不用担心:
<cfscript>
email = "bob@google.com";
if (ListLast(email, "@") == "google.com") {
// here you go
}
</cfscript>
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
311 次 |
| 最近记录: |