Questions tagged as 'php'

1
answer

Use registered addresses in the database in JavaScript / Google Maps

I have in a database the following columns: client name, active or inactive, address and lat and lng coordinates. I need to develop an application in PHP that will display in the Google Maps green bookmarks the active clients, and red the ina...
asked by 19.11.2014 / 13:54
1
answer

Laravel Results of a Query Builder for eloquent model

I'm doing a query using Query Builder $users = DB::select( DB::raw(" SELECT users.* from users, permissions_customers WHERE permissions_customers.customer_id in ( SELECT permissions_customers.customer_id from permissions_customers WHER...
asked by 05.09.2014 / 14:50
1
answer

Structure of a database for 'Secret Friend'

I am creating a secret friend system for the family, where it will be possible to have: User registration with your given data (ex: Tennis size, shirt, etc ...) ; Registered user groups; Generate a draw with users entered into that part...
asked by 03.11.2014 / 12:32
2
answers

Join a number of people without repeating the combination with the maximum stipulated

I have N pessoas to form as many meetings as possible. These N pessoas can not speak to anyone who has already spoken at other meetings. Each meeting has at most N pessoas . Based on this information I can set up an exampl...
asked by 03.11.2014 / 19:46
4
answers

How do I reset the time and decrease one day of a DATETIME?

I have a field DATETIME that I get from SQL, format YYYY-mm-dd H-m-s and I need to zero the time and decrease one day. I'm getting a day off by using date_modify($date, '-1 day'); , but how do I reset the time?     
asked by 21.03.2014 / 14:45
1
answer

How not to display past date records

I made a schedule and I need events that have already passed do not appear any more, the dates are with 3 DAY / MONTH / YEAR fields, I am using concat and date to join and format the dates, so the current query is as follows: $query = mysql_qu...
asked by 13.04.2014 / 07:38
1
answer

Date field preclude with the current date automatically

How do I set up mysql in phpmyadmin so that when I insert a record the data_lancamento field automatically pops up with the current date without me needing to be passing the date through php, does anyone know?    I saw a question just...
asked by 18.06.2014 / 17:54
2
answers

Use of unmapped entities in Symfony2

I have read that the Entity folder of a bundle normally stores the entities that will be persisted (in my case, by Doctrine) in the database. But for the ease of working with "annotations" formatting within an Entity, I have chosen to create...
asked by 13.12.2013 / 21:55
4
answers

How to create a PDF stream in PHP?

Is there any alternative to implementing a stream of PDF files that are on the server? I would like the browser to download the pdf as it is viewed. Same as the preview of google books     
asked by 30.01.2014 / 01:54
2
answers

How do I set the width of columns in an Excel spreadsheet generated as HTML?

I need to convert an HTML table and generate the file in excel. How to set the width of columns in excel? I create the HTML file using PHP and export using: header ("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); header ("Last-Modified: " . gmdate(...
asked by 17.02.2014 / 21:13