Questions tagged as 'php'

1
answer

AJAX Update live data

I am writing a system that should update two divs, as much as possible, in real time. The way I found it is as follows, using AJAX: function actualizarDatos(){ $.ajax({ type: 'POST', cache: false, async:true, url: 'l...
asked by 25.09.2018 / 13:05
1
answer

How to hide lectures on a web server

I am setting up my website, I have a login section, but if I put the full url to the next page after login it is within reach, although it has no data, since I use PHP through POST, but I would like to know if there is any form inside my server...
asked by 15.04.2018 / 22:55
1
answer

Send records to several tabalas- mysqli

I would like to know how it is sent from a single form to different tables. for example I have the following code could add an example by sending different records to two tables. <!doctype html> <html> <head> <meta char...
asked by 17.04.2018 / 01:31
1
answer

Save a two-dimensional array created in Php in a MySQL table

While there are similar questions answered, I could not solve my problem. I have generated from Php, a two-dimensional array obtained from a previous page, from where I passed the data by the POST method, now I need to save them in a table previ...
asked by 06.11.2018 / 14:01
2
answers

Read txt from bottom to top

I have this simple code that reads an arch; notes.txt. The last data leaves them down and not up, that is normal for how they are saved, but how can I make them read from bottom to top. <?php $ar = fopen("notas.txt","r") or die("NULL"); whi...
asked by 06.11.2018 / 04:32
1
answer

Submit silent in form

I have a problem with my form. The functionality of sending information to an email is good thanks to PHPMailer , when you submit, the information is sent to a php file called contacto.php, this is where I check that it is not spam and I think...
asked by 13.09.2018 / 09:55
1
answer

cut a string by a php delimiter

I need to cut words after ", " in PHP I have something similar to this $string = "dato, dato, dato" , it's the same name only that is repeated.     
asked by 13.09.2018 / 12:52
2
answers

show variable php in txt with onclick in button?

How can I put the result in the txt when I click on the button? without submit? thanks in advance for the help <?php function generarCodigos($cantidad=3, $longitud=10, $incluyeNum=true){ $caracteres = "ABCDEFGHIJKLMNOPQ...
asked by 13.09.2018 / 15:20
1
answer

get a link to a search in php

I'm doing a php validator initially with a simple function. $url = $_POST['url']; $estado; $amp = file_get_contents("$url"); $buscar = "/amp"; $resul = strpos($amp, $buscar); if($resul!= false){ $estado= 'La página existe!'; }else{ $es...
asked by 13.09.2018 / 20:01
1
answer

sudo apachectl configtest not working

I have a website in digital ocean, com LAMP. The local project works. when I put it on the remote server, and set the file /etc/apache2/apache2.conf with the project route. but this command sudo apachectl configtest I miss this er...
asked by 22.09.2018 / 02:15