Questions tagged as 'mysqli'

2
answers

How to do AUTO_INCREMENT on a composite key that only affects a key?

I have a 'Group' table that handles the groups that are open for subjects. The key to this table is the group number + subject code If I have: Materia No_Grupo TC2016 1 TC2016 2 TC2016 3 The AUTO_INCREMENT works fine but I want that when...
asked by 27.11.2016 / 10:32
1
answer

How to jump from mysql records using a php loop, and from each iterated record, calculate between field values?

What this code does is to receive in a variable the number of classes taught, in array the number of absences for each student, in another'array' the idGroup, which is always the same, and in another array receives the idAlumno, th...
asked by 21.12.2016 / 01:59
3
answers

How it could show the history of an ID in PHP mysql

I would like to make a web system which shows me the X client (ID) history and I have the complete crud but at the point of how to create a history as the client asks me unfortunately I do not know how it is done. Explanation in detail of wha...
asked by 04.01.2017 / 00:45
1
answer

how to avoid being shown twice?

I have a user system in which I send a request (who sends) so that the other user (who receives it) responds.When.I do the sending the button that said "Add" changes to "Request sent" The problem is that when I enter the profile or better said e...
asked by 09.11.2016 / 02:47
1
answer

What is this error? Warning: mysqli_query (), (fetch_array, num_rows) :: expects parameter 1 to be mysqli, null given in,

function loguearDocente($user, $pass) { global $conexion; //$user = mysqli_real_escape_string($conexion, $_POST['user']); //$pass = mysqli_real_escape_string($conexion, $_POST['pass']); $sql = "SELECT * FROM users_profesores WHERE (User='"...
asked by 22.10.2016 / 21:48
2
answers

mysqli_query SELECT can not find items

I have a problem, in a login in php I have a line of code that checks if the user and password are correct, if so, the code continues. The error is that I enter the username and password that exist in the DB and it says as if they did not exist....
asked by 23.09.2016 / 17:50
2
answers

Problem to insert data in a database from PHP

Good morning everyone! Well, my problem is the one mentioned in the title. From a form in php I'm trying to get the data I collect inserted in a bbdd, and I can not find the fault. First HTML document called "index.html": <docty...
asked by 24.11.2016 / 16:30
2
answers

How to consult between months or dates

I am trying to make a query to my table by specifying, taking an id, in specific: $id=$_GET['id']; $Consult= "SELECT * FROM pagos_colegio WHERE id='$id' AND mes BETWEEN ('jan' AND 'Dec'); "; $result= $conexion->query($Consult...
asked by 02.07.2016 / 14:35
1
answer

Check if there is mail in BD [closed]

You will see I have a form in which I have a name, last name, two mail fields (the second to verify if it is equal to the first one), a password, and two RadioButton with the sexes. What I need is to check only the mail if it is repeated or n...
asked by 23.08.2016 / 04:04
1
answer

calculate values of a dynamic table

What I want to do is calculate the values of the SubTotal field, since this is the result of the multiplication between the values of the Price field and the value entered in field text Quantity . In addition to calculating the VAT of the s...
asked by 24.06.2016 / 21:52