Questions tagged as 'php'

2
answers

Validate that date and time are not less than the current datetime-local input

I have a datetime-local type field in a form, and I need that the entered date and time are not lower than the current ones. Is it possible to do that? I tested with the min attribute of html5 and assigned the current date and time to avoid bein...
asked by 03.10.2017 / 18:28
2
answers

I do not understand the array in php

<?php $empleados = array( array('Powell, Alfredo','Administrativo',5500), array('Pérez, Verónica','Administrativo',5200), array('Goldstein, Juan','Recursos Humanos',6800), array('Giaccomo, Walter','Recursos Humanos',6200),...
asked by 03.10.2017 / 14:05
2
answers

I do not work fetch_all (MYSQLI_ASSOC)

I am a student and in one of my video classes I realize that my code is broken by using the function fetch_all (MYSQLI_ASSOC) verify the syntax of my code again and again until I have done it practically from the beginning and not yet I can solv...
asked by 03.10.2017 / 00:19
2
answers

Unknown column when using WHERE (ERROR) codeigniter

I am trying to show a value of the Database in an input, however I get the following error. Why is this happening? A Database Error Occurred Error Number: 1054 Unknown column '17811942-4' in 'where clause' SELECT 'horario'.'hrs_ini' FROM 'h...
asked by 04.10.2017 / 16:23
1
answer

Problem with jQuery Ajax and PHP

I am trying to make a record in the BD without recharging the page. The record is saved correctly, but when I want to capture the answer the PHP document is displayed. Code js $('#btnagregarO').click(function(){ var obs = $("#txtob").val(...
asked by 20.09.2017 / 20:19
1
answer

Php artisan error no direct script access allowed

I am working with laravel 5.2 and php 7.1.7 , the problem is that when I try to use some artisan command to raise the server with the command php artisan serve I get:    no direct script access allowed on the console and it will n...
asked by 21.09.2017 / 14:30
2
answers

Id of the users table from the login

Users table: iduser, name, user, password, group In the login you must enter username, password and group <?php include('00_conn.php'); $consulta = "SELECT * FROM $t98 WHERE (98_username= '$usuario' AND 98_clave = '$clave' AND '98_grupo = '...
asked by 20.09.2017 / 00:30
2
answers

Increase a date month by month PHP

I have the following variables $fehchaI ='2016-01-01'; $fehchaF ='2017-01-31'; What I want to do is increase the dates month by month and the result is 2016-01-01 2016-01-31 2016-02-01 2016-02-28 2016-03-01 2016-03-31 or 2016-01...
asked by 20.09.2017 / 19:37
1
answer

Check with a search engine in laravel

I wanted to know if the query is well done Where to find the posts of a blog that contain a word "query": public function search(Request $request) { //guarda la palabra en $query $query = $request->input('query');...
asked by 19.09.2017 / 02:16
2
answers

SQL See DB count

I have a table called decree in the database with the following fields: and I want to see the years that I have in my database in which I have entered data. Example in the database I entered dates in 2016 2017 2018 and the query that shows...
asked by 20.09.2017 / 15:35