Published on : July 24, 2020
Title : if.equal
Purpose : To compare two values are equal or not
Syntax : [if.equal lhs=’left hand side value’ rhs=’right hand side value’]
//** Do something if left hand side value is equal to right hand side value **//
[/if.equal]
Input Parameters :
lhs : left hand side value to be compared with right hand side
rhs : right hand side value to be compared with left hand side
Return Value : It does not return anything
Example 1 :
Code :
[if.equal lhs=”abc” rhs=”abc”]
    Both are equal
[/if.equal]
Output : Both are equal.
Description : In the example, lhs holds the value “abc” and rhs holds the value “abc”. As both the values are equal, the condition will get satisfied and the logic inside the condition will get executed.
Example 2 :
Code :
[if.equal lhs=”200″ rhs=”300″]
    Both are equal
[/if.equal]
Output :
Description : In the example, lhs holds the value “200” and rhs holds the value “300”. As both the values are not equal, the condition will not get satisfied and the logic inside the condition will not get executed.