或“|| “运算符不在php中的if语句中工作

I am using codeigniter and wants to shwo the js code only if following condition true

<?php 
if(($this->uri->segment(1)!='reports') || ($this->uri->segment(2)!='manageflyers' && $this->uri->segment(3)!='save')){?>
    //some js code
<?php }?>

But i does not work please help where i am making the mistake.

A couple of != with an OR || will always equal true because that string variable will only equal one thing and not be the other

so your code will work like this

<?php 
if(($this->uri->segment(1)=='reports') || ($this->uri->segment(2)=='manageflyers' && $this->uri->segment(3)=='save')){ 
    //do nothing
 }else{
    //some js code
 }