Questions tagged as 'php'

2
answers

Capture values after an input checkbox

Good morning, I have a 'Attendance' form where there is a checkbox for each service. CurrentlyIcangettheidofeachselectedcheckbox,putitinanarrayandprintthisarray,butthat'snotmygoal.Iwouldlikeforeachcheckedcheckboxtocapturethevalueoftheservice...
asked by 29.05.2016 / 18:08
2
answers

Editable table in PHP [closed]

I have a table with a list of companies. I want from a click on the table line to load a modal with the information of this company. Any suggestions on how to do it?     
asked by 23.05.2016 / 22:47
1
answer

Error using a function inside array in PHP

I'm using laravel 5.2 and in my class IndexController I'm trying to create an array with the function date('Y') like this: <?php namespace App\Http\Controllers; use Illuminate\Http\Request; use App\Http\Requests; cl...
asked by 08.05.2016 / 21:19
2
answers

Date being recorded wrong in bank m-d-Y instead of Y-m-d

I set the date format for viewing to "d-m-Y", while the recording format is the "Y-m-d" bank. However at the time of recording in the bank, something happens and the data is going in the format "mdY", and with that the data will be truncated,...
asked by 22.12.2013 / 23:37
3
answers

Get content that is enclosed in parentheses using regex

I've been studying regex a lot, but I got caught trying to "clean" a text, leaving only the first occurrence, and the data in parentheses, the string is like this : $string = "Mais de - valor: R$3.21 - Tipo: (+05)"; As all text before...
asked by 20.05.2015 / 08:51
2
answers

Enter minute by minute in function

I have the following php function below: function showComboHorarios($name, $default = '08:00') { $hi = 6; // hora inicial $hf = 23; // hora final ?> <select style="width: 80px;" name="<?php echo $name; ?>"> <?php for...
asked by 11.06.2015 / 14:54
1
answer

Why, in PHP, are some predefined constants case-insensitive?

Because in PHP , some predefined constants are case-insensitive (they are not case sensitive) and some are not? Example 1: echo __FILE__; // index.php echo __file__; // index.php echo __fiLE__; // index.php Example 2: ec...
asked by 15.07.2015 / 16:29
2
answers

Is it possible to open a dll extension without entering php.ini?

I need to use php_openssl.dll , but I do not have access to php.ini , the server is foreign and the support is also difficult to access. extension=php_openssl.dll Is there any way to use it without entering php.ini ?     
asked by 22.05.2015 / 20:34
3
answers

Url Friendly with Mysql

I'm building a website that pulls ids from the database and makes the page of the post, but when it asks the url it stays as id like this: http://www.meusite.com.br/posts.php?id=2 I wanted instead of showing the id, show the Title of the po...
asked by 19.07.2015 / 21:40
3
answers

Difficulties in sending E-mail using PHP

Based on the code below, used for sending e-mail: <?php $from = $_POST['email']; $to = '[email protected]'; $subject = $_POST['subject']; $message = $_POST['content']; $headers = 'From: ' . $from . "\r\n...
asked by 01.06.2015 / 21:16