Questions tagged as 'if'

3
answers

Appear button according to the condition of the php parameter

I wonder if it is possible to make the button appear only if the parameter is true. By the URL comes the parameter ../usuario?id=1&parametro=1 I tried this way but could not. <?php $parametro = $_GET['Parametro']; i...
asked by 02.01.2018 / 16:47
1
answer

Why does the IDE indicate that a code in the "if" will not be executed?

Look at the code: Why is the development IDE not considering the code in line 34, 35 and 36? Would not it have been to go into the conditional?     
asked by 14.10.2018 / 13:32
2
answers

How to use if else in the code below

When I type the id of the artist and the other data, then I will type the id of the repairer, I need to type the id of the repairer, if it is the same as the artist, he should not accept it and ask for another id, one part, but it does not ask f...
asked by 05.09.2017 / 20:37
3
answers

How to use an if within the other?

The problem is the following 2 soccer teams, wanted to create a decision where it would show "Brazil won" or "Argentina Won" or "There was a tie." But I can not make three decisions, here is my code below. #include<iostream> using nam...
asked by 27.06.2016 / 18:23
2
answers

Change elseif code to switch case

I'm having trouble changing a code I made in else if to switch case . I'm not getting the code to work, it gets values and operation by $_GET and does the selected operation: I leave the code here: if((!is_numeric...
asked by 07.07.2016 / 15:16
1
answer

Do a negation in an IF coding

I have the following condition IF : (ClientesBDM.getNomeEmpresa().toString().equals(ClientesBD.get(1).toString())) How can I check if the variables are different, ie deny this condition in the same IF     
asked by 21.06.2017 / 14:28
4
answers

How to do if and else between 2 variables with output in a third?

I'm sorry but I had to rewrite all my question because it was not being objective enough to make me understand, when I omit code as it was the previous case is not to hide something is just to be able to perceive what they respond to me within m...
asked by 11.09.2014 / 08:50
4
answers

Error checking the IF with array in PHP

I'm trying to make a if within a foreach and the situation is as follows: I have array that I called $ enrollments which returns like this: array(2) { [0]=> array(1) { ["chave"]=> string(1) "1" } [1]=> array(...
asked by 18.07.2016 / 23:58
2
answers

Logic optimization [closed]

I have the following logic that I need to optimize using PHP Parâmetros: máximo mínimo alerta Se ultrapassar o nível máximo enviar um alerta Se alerta já tiver sido enviado não enviar nada Se o nível voltar ao normal enviar alerta The...
asked by 07.12.2016 / 18:42
1
answer

Placing an IF with various conditions

I want to put an If with several conditions. if ($row[??] != '' or NULL or 0000-00-00 ) I currently have this, but I want to add two more Rows. do I have to create more if or can I add in this If?     
asked by 04.08.2014 / 13:24