Solved

What does this mean: if (!$st['StatementRollUp'] || $st['templateid'] == '9') {

Posted on 2016-07-25
4
71 Views
Last Modified: 2016-07-25
I'm looking at this and I'm thinking this is a shorthand way of coding an IF statement. But what does it mean? I was under the impression the "|" character is saying that both of the values have to equal 9, but the exclamation point is baffling me. What's the bottom line?
0
Comment
Question by:brucegust
  • 2
4 Comments
 
LVL 110

Accepted Solution

by:
Ray Paseur earned 450 total points
ID: 41728116
In plain language,...

If $st['StatementRollUp'] contains a falsy value, or $st['templateid'] contains 9, the if statement will evaluate TRUE.
0
 
LVL 110

Assisted Solution

by:Ray Paseur
Ray Paseur earned 450 total points
ID: 41728132
0
 
LVL 143

Assisted Solution

by:Guy Hengel [angelIII / a3]
Guy Hengel [angelIII / a3] earned 50 total points
ID: 41728155
and the ! means NOT ...
0
 

Author Comment

by:brucegust
ID: 41728160
Rock on!
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Wordpress Security 29 71
Change static entered data to dynamic with counter 5 32
Survey branching tutorial 11 37
CURL sending XML without spaces PHP 5 28
I imagine that there are some, like me, who require a way of getting currency exchange rates for implementation in web project from time to time, so I thought I would share a solution that I have developed for this purpose. It turns out that Yaho…
Things That Drive Us Nuts Have you noticed the use of the reCaptcha feature at EE and other web sites?  It wants you to read and retype something that looks like this.Insanity!  It's not EE's fault - that's just the way reCaptcha works.  But it is …
The viewer will learn how to dynamically set the form action using jQuery.
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.

685 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question