Questions tagged as 'php'

2
answers

Including external .js files

Well, I have a .js file in mydomain.com/file.js (example). This file contains functions that send requests via Ajax to another file, data.php (search and return in json), which is in the same folder as the hosting of the .js file. The idea is to...
asked by 04.03.2016 / 02:15
1
answer

Display div elsewhere, according to screen resolution

Would you like to give a different include for each resolution? Like ... If the resolution (width) is greater than 768 I want to display 2 columns (grid_6 and grid_6), opening the text next, ok. Butifitisalessresolution,Iwanttodisplayonlyone...
asked by 22.03.2016 / 15:42
1
answer

How to intercept the result of a query?

I need to test whether the query you have done is fine or you hear something wrong. I have tried to find something that does not satisfy what I need. Example: I submitted a sql in the database, and it was done correctly, but I heard an err...
asked by 06.12.2015 / 13:14
2
answers

Error passing PHP Array to AngularJS by JSON

I am in doubt on a code I am developing, I am passing a query on the MySql database and I need this response to return in JSON for angularJS to understand and write in HTML. Follow the code: <?php header('Content-Type:text/html;charset...
asked by 06.12.2015 / 17:11
1
answer

Error 'Duplicate entry' 1 'for key' PRIMARY '"

I'm not sure how to do this, but I'm not sure how to do this. Duplicate entry '1' for key 'PRIMARY' Using the following code: mysql_query("INSERT INTO vendaproduto (id, id_venda, produtos) SELECT venda.id_venda, venda.id_venda, venda...
asked by 14.12.2015 / 13:59
2
answers

Display only array values

I'm a PHP developer and I'm currently studying the arrays, and I'm having a silly question. When I print my arrays, it comes that way Array ( [0] => Array ( [0] => 10 ) [1] => Array ( [0] => 20 ) [2] => Array ( [0] =>...
asked by 08.11.2015 / 19:25
1
answer

How to execute a function from a url?

If I leave the code just below the inside of the funcoes.php file of my system, when the page reloads, it deletes the post that I had deleted. $tipo = $_GET['tipo']; $funcao = $_GET['funcao']; if($_GET['tipo'] == 'blog' &&...
asked by 09.11.2015 / 14:56
1
answer

How to send Google Chart by email?

What would be a viable solution to send a Chart via email via PHP? To get the Chart, I use the following form: google.load("visualization", "1", {packages:["corechart"]}); google.setOnLoadCallback(drawChart);...
asked by 10.11.2015 / 18:55
2
answers

phpmailler error sending email

How can I send more than one 'email' with 'phpmailler' it always gives this error 'Mail error: You must provide at least one email address.' I'm developing a newsletter system that will select all the registered emails but it always does. detail...
asked by 17.11.2015 / 19:24
1
answer

System of Log in Data Management System

I am developing a data management system in PHP Laravel 5 . On this system I want to put a Logs System. 1 - Does Laravel have any library that facilitates this system? 2 - If Laravel does not have the best way to do such a system?...
asked by 17.11.2015 / 17:17