Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the meaning of " |= " in php?

Tags:

operators

php

I don't know what is the meaning of "|=" in php. Searching Google doesn't help. Please someone explain exactly what they do.

My Question is meaning of "|=" not "!=" ?

I have already search "Reference - What does this symbol mean in PHP?" but i did't get my answer.

like image 837
SAR Avatar asked Feb 20 '16 04:02

SAR


Video Answer


1 Answers

This is bitwise OR operator

$var1 |= $var2; is equal to $var1 = $var1 | $var2;
like image 78
dhi_m Avatar answered Oct 04 '22 16:10

dhi_m