Posts by Pedro Erick • 186 points
8 posts
-
1
votes2
answers290
viewsA: Secure Login with Remember
I have faced problems where I put session for unlimited time and still expire after a period of inactivity and in my case was the Garbage Collector. The configuration gc_maxlifetime of php.ini…
-
0
votes1
answer206
viewsA: Help with foreach error
In this case is being used a foreach of the large images inside the small images, try to use a foreach only. The example below may not work 100% because it considers that large images have the same…
-
1
votes1
answer2473
viewsA: Upload PHP Images and Ajax send file path to Input
To recover image data you need to make changes to your ajax request and server response. Client side changes $.post allows you to capture the server response by simply adding a parameter to your…
-
3
votes2
answers162
viewsA: Automatic line break with regex
Just put spaces followed by + out of square brackets: $arr = preg_split('/ +[v|x] +/', $var); This regex will remove the characters " x ", " v " and also those who have more than one space such as "…
-
1
votes2
answers1377
viewsA: Watermark in images with PHP
$filename is provided by the method create, to ignore the name in MD5 just put the parameter when creating the photo. Code example that saves the photo as jpg test. require_once('RDSImage.php');…
phpanswered Pedro Erick 186 -
1
votes2
answers112
viewsA: JSON powered by while
In this code the while is inside the variable date, the variable must be set before as an array and inside the while you go adding the values. An example close to yours that should work: <script…
-
3
votes2
answers355
viewsA: Tokenmismatchexception after any ajax error on Laravel 5.1
Just complementing @Wallace Maxters' reply. If there is no need to use CSRF protection anywhere in the project, you can disable this option completely by changing the file app/Http/Kernel.php and…
-
1
votes3
answers410
viewsA: Send variables to PHP via Ajax - undefined variables
I believe the problem is in the file sessUser.php. Variables are being set outside the function and used within the function, which can cause zeroed values. Try this code below and check if it…