el的判斷
html**
<
c:if
test
="$"
>
currentroleid為空
c:if
>
<
c:if
test
="$"
>
currentroleid不為空
c:if
>
<
c:if
test
=>
currentroleid和sysadmin相等
c:if
>
<
c:if
test
=>
currentroleid和sysadmin不相等
c:if
>$
[html]view plain
copy
print?
<
c:if
test
="$"
>
currentroleid為空
c:if
>
<
c:if
test
="$"
>
currentroleid不為空
c:if
>
<
c:if
test
=>
currentroleid和sysadmin相等
c:if
>
<
c:if
test
=>
currentroleid和sysadmin不相等
c:if
>
$
el的判斷
html**
<
c:if
test
="$"
>
currentroleid為空
c:if
>
<
c:if
test
="$"
>
currentroleid不為空
c:if
>
<
c:if
test
=>
currentroleid和sysadmin相等
c:if
>
<
c:if
test
=>
currentroleid和sysadmin不相等
c:if
>$
[html]view plain
copy
print?
<
c:if
test
="$"
>
currentroleid為空
c:if
>
<
c:if
test
="$"
>
currentroleid不為空
c:if
>
<
c:if
test
=>
currentroleid和sysadmin相等
c:if
>
<
c:if
test
=>
currentroleid和sysadmin不相等
c:if
>
$
示例:spring mvc伺服器端:
string rolename = adminroleservice.getrolenamebyadminid(administer.getid().longvalue());
string customerman = "客戶經理";
model.addattribute("rolename",rolename);
model.addattribute("customerman",customerman);
jsp頁面客戶端:
審 核
el 表示式判斷
c if test currentroleid為空 c if c if test currentroleid不為空 c if c if test currentroleid和sysadmin相等 c if c if test currentroleid和sysadmin不相等 c if html v...
EL表示式 EL表示式顯示資料
1.基本資料型別與string型別 request.setattribute scores 滿分 request.setattribute a 1 頁面顯示為 滿分2.自定義型別 a 在頁面中要顯示的自定義類成員變數必須要有getter b 如何顯示 建立乙個student類 request.set...
EL判斷語句的表示式
總結一下el表示式的邏輯判斷 1 eq相等 ne neq不相等 2 gt大於,lt小於 3 ge大於等於 le 小於等於 4 not非 mod求模 is not div by是否能被某數整除 is not even是否為偶數 is not even by b即 a b 2 0 is not odd是...