Tema: Error
Ver Mensaje Individual
  #1 (permalink)  
Antiguo 27/06/2015, 12:17
saminsoo
 
Fecha de Ingreso: mayo-2015
Ubicación: Manta
Mensajes: 2
Antigüedad: 9 años
Puntos: 0
Pregunta Error

Soy principiante en la programacion, quiero guardar mi contenido de mi tabla en una matriz. Pero me bota el siguiente error:


Warning: mysql() expects at least 2 parameters, 1 given in C:\xampp\htdocs\turingsystemphp\includes\conexiond atos.php on line 17

Notice: Use of undefined constant usuario - assumed 'usuario' in C:\xampp\htdocs\turingsystemphp\includes\conexiond atos.php on line 18

Warning: mysql() expects parameter 3 to be resource, string given in C:\xampp\htdocs\turingsystemphp\includes\conexiond atos.php on line 18

Warning: mysql_fetch_array() expects parameter 1 to be resource, null given in C:\xampp\htdocs\turingsystemphp\includes\conexiond atos.php on line 20



Código:
<?php
session_start();
switch ($_SESSION['proceso']){
case (1):
    $ingresousuario = $_POST['user'];
    $contrasena = $_POST['clave'];
    $conexion = mysql_connect("localhost","root","");
    
    if (!$conexion) {
        
        die("No hay conexion MySQL".mysql_error());
        
    }
    
    mysql_select_db("turingsystem",$conexion);
    
    $peticion =  mysql("SELECT * FROM usuario");
    mysql("turingsystem","SELECT* FROM", usuario);
    
    while ($fila=  mysql_fetch_array($peticion)){
        echo $fila['USER_Id']."".$fila['USER_Nivel']."".$fila['USER_Apellido']."".$fila['USER_Correo']."".$fila['USER_Clave'];
        echo'<br>';
    }