Posts by Eduardo Santos • 754 points
48 posts
-
0
votes1
answer115
viewsQ: spin.js is not displayed when the page is loaded
I’m using Spin js. to display a load until the entire page is loaded, once this is done, the spin execution must be terminated. But the load is not even appearing on the screen. I created a jsfiddle…
-
0
votes1
answer47
viewsQ: Subquery returning null value
I am doing this query, and I need to query the cost value of a product using a subquery, because the note table is the same as input and output. The products do not repeat. What differentiates sale…
-
0
votes3
answers1209
viewsQ: Sum hours of an array
I need to total the column hora_agente of the kind time. And I need the return value to be in hours. May be greater than 24 hours. In the example I did, it’s returning 5:55, and it should return…
-
-1
votes2
answers501
viewsQ: Calculate PHP hour percentage
I need to calculate the percentage of each hour of one array. For example: Hora1: 4:45 am Time 2: 1:30 am Time 3: 00:45 Total: 07:00 $array = array('04:45','01:30','00:45'); I did the calculation in…
phpasked Eduardo Santos 754 -
1
votes1
answer246
viewsQ: Calculation of hours in Informix bank
I’m a beginner in banking Informix, and I’m having difficulty calculating the difference between hours in a query. For the calculation, the fields hrinicio and hrfim should be used Query I tried:…
informixasked Eduardo Santos 754 -
2
votes4
answers774
viewsQ: Concatenate variables from an array
I need to concatenate variables from an array, to run an SQL, this array can have differentiated values. If the array is greater than 1, then it must have $variable + $variavel02. If the array is…
-
2
votes2
answers245
viewsQ: Print more than one javascript copy
I can make a print exit automatically in 3 copies? Same in this window below. window.onload = function() { window.print(); }…
javascriptasked Eduardo Santos 754 -
2
votes1
answer831
viewsQ: Take the last exploding position
Guys need to get the last position after giving a explode. How do I do? $geturl = explode('/', $_SERVER['REQUEST_URI']); self::$modulo = isset($geturl[2]) ? $geturl[2] : ''; self::$funcao =…
phpasked Eduardo Santos 754 -
0
votes1
answer72
viewsQ: Table scroll with roll position according to date
I have a table with a birthday list. I use a div that leaves her scroll with horizontal size fixed. I would like the table scroll to be at the position of the current date. As in this picture below:…
javascriptasked Eduardo Santos 754 -
3
votes1
answer448
viewsQ: Simultaneous connection on straight seats PDO
I need to make an appointment using two different banks and simultaneously. One is mysql and another firebird. It is already working separately, I would like to make the connection without having to…
-
0
votes1
answer433
viewsQ: Adjust Background as per resolution
I have a background image, and I would like it to fill in the div and adjust to the resolution of the monitor. The div is already responsive because I use Foundation Zurb. I did that, but the image…
cssasked Eduardo Santos 754 -
1
votes3
answers227
viewsQ: Hyphenate when value is 0 in select
How can I do in the mysql one query (SELECT) so that when the value is equal to 0, replace it with hífen(-). Field of value: int.
-
1
votes3
answers2989
viewsA: Make field mandatory depending on response
Follow example using JavaScript, Jquery and the function required HTML5. $('.pergunta').change(function() { var chars = parseInt(this.value); if (chars === 1) { $('#retorno').html('<input…
-
0
votes2
answers75
viewsA: Google Chart + Foundation Tabs
Follow the solution of the problem: $(document).foundation(); $('#stabs').on('change.zf.tabs', function() { switch ($(this).children('.is-active').text().trim()) { case 'Tab 1': drawVisualization();…
javascriptanswered Eduardo Santos 754 -
4
votes1
answer794
viewsQ: How to use "Count se" in PHP
I need to make a count se in the PHP. I have a table with several status, and I want to count only a certain type. And I need to count by PHP. By SQL is unviable. $data = Connection::Select('SELECT…
phpasked Eduardo Santos 754 -
0
votes1
answer93
viewsA: Background-size (Mozilla Firefox)
Try this: background: url('sua_imagem.jpg')no-repeat center top; -webkit-background-size: cover; -moz-background-size: cover; -o-background-size: cover; background-size: cover;…
-
1
votes1
answer963
viewsA: What is the best connection method between PHP and Firebird?
Follow the class I have: Connection.class.php <?php class Connection { public static $conn; //lê o arquivo .ini com as config public static function open($name) { if…
-
3
votes1
answer146
viewsQ: Open div via ajax
Glacier, I need to open one div via ajax passing a ID via POST. Where am I going wrong. HTML <div class="row"> <div id="retorno_galeria"> <a onclick="galeria_id(this.id,' . $gal["id"]…
-
1
votes0
answers152
viewsQ: Open a gallery via ID with Lightbox
I’m having a hard time doing Lightbox open a gallery specifies to load the images from a certain directory. At this point the code below lists several thumbnails, which would be the picture albums.…
-
0
votes1
answer112
viewsQ: Refresh by clicking on the tab (Foundation)
I need to refresh the content by clicking on aba. This refresh will have to be done in the Content 2 tab. Can anyone help me. <div class="row"> <div class="medium-12 columns"> <ul…
-
1
votes0
answers33
viewsQ: Upload Multiple with problems
I have this code that should do a multiple image upload, but it only uploads the first image. Someone can help me. PHP require('public/plugin/resize2/resize2.php'); if…
phpasked Eduardo Santos 754 -
5
votes2
answers75
viewsQ: Google Chart + Foundation Tabs
I’m facing problems with Google Chart + Foundation. The Gráfico doesn’t stay in width:100%, and it seems to lose formatting. And this happens when I use it in Tab of Foundation. Strange that if you…
javascriptasked Eduardo Santos 754 -
1
votes3
answers95
viewsQ: Load an element in ajax as user chooses
I have a code that inserts a field textearea as a choice of input radio. I would like to simplify this code by making it use Javascript only. Is it possible? Follow below: HTML <p>2.3 - Você…
-
1
votes1
answer201
viewsQ: Forward button and back ajax
I need help making a forward and back button for a birthday list. The data will be sent via POST to a query class. The PHP is ok. I need to adapt the JavaScript. PHP $data = date('Y-m-d');…
javascriptasked Eduardo Santos 754 -
3
votes1
answer906
viewsQ: Vertical lines Google Chart
I would like to add vertical lines to this graph. But I’m not getting it. I would like each group to draw a vertical line, as in this image. My current code: google.charts.load('current',…
-
4
votes3
answers1351
viewsQ: Change String Axis Y Google Chart
Utilise Google Chart to generate charts. I have a array with values from 1 to 4. These values are of the type int. I need to change the description of the Y-axis. To: 1 = Great 2 = Good 3 = regular,…
-
0
votes1
answer209
viewsQ: Case for several fields
I can make a query using 1 case to various fields? The fields are of the type int. If not, I can do it in php? Query select *, (case (pergunta1,pergunta2) when 1 then 'Ótimo' when 2 then 'Bom' when…
-
0
votes4
answers889
viewsA: Character limit
Very simple example: $string = 'String para ser reduzida' $reduzido = substr_replace($string, (strlen($string) > 42 ? '...' : ''),42); I hope it helps.
-
3
votes1
answer1942
viewsA: I can’t import themes in wordpress
If you use xampp navigate to the folder: C: xampp php.ini Search for the line: post_max_size=8M Switches to: post_max_size=50M Or the size you want. Restart the apache and mysql service. For linux…
-
0
votes0
answers83
viewsQ: Modal Foundation via URL
I need to open a modal zurb-foundation via URL. For example http://sistema.com.br/agenda/#modal99 Follows the code: Html: <a href="#modal99">Show Modal</a> Javascript:…
-
1
votes2
answers131
viewsQ: Recover typed URL
I have a system that uses Session which expires with inactivity. Access to files in the system is only released after the session is opened. Until then beauty, is working. I would like to remember…
phpasked Eduardo Santos 754 -
0
votes0
answers68
viewsQ: Blur event does not work on mobile
I have an event Javascript Blur that doesn’t work on mobile phones. Works perfectly on desktops. Even on older browsers. My code: HTML <label>CPF</label> <input type="text" id="cpf"…
-
4
votes2
answers1019
viewsQ: Generate random number for an array
I have a foreach that fetches data from a table and makes a insert in another table. I need to count the amount of foreach, and then generate a random sequence, and feed a field of insert. Look at…
-
1
votes1
answer38
viewsQ: Help for this query
Good afternoon Guys, I have these two tables that relate to know how many times a user accessed the system: And I have this query: select nome_usuario, count(id_log) as qtde from logs as l left join…
mysqlasked Eduardo Santos 754 -
2
votes2
answers509
viewsA: Force Session not to exceed 30 minutes
See if that helps you: session_start(); if (isset($_SESSION['atividade']) && (time() - $_SESSION['atividade'] > 1800)) { session_unset(); session_destroy(); } $_SESSION['atividade'] =…
phpanswered Eduardo Santos 754 -
0
votes1
answer712
viewsQ: Distinct does not work
People, someone can tell me why this query doesn’t work. In fact it works, but brings the values wrong way (duplicating the department field), as if distinct does not work. select distinct…
mysqlasked Eduardo Santos 754 -
-1
votes1
answer58
viewsQ: Conveter PHP function for Javascript
I don’t have much knowledge of Javascript. I need to convert this check below that is in PHP to Javascript. How can I do that? $verificao = $_POST['verificacao_name']; $pesquisa1 = $_POST['p1'];…
-
0
votes2
answers789
viewsQ: Recover data after Submit
Good morning Guys, I have a form that validates in php and not in javascript, and when an error occurs I run a history.back() to return to the form. That returns a blank form. Does anyone have any…
-
0
votes0
answers229
viewsQ: Add a progress bar after an Submit
Hello, I have a script that uploads some files, often heavy files. When I run Submit it uploads, but it shows nothing on screen until the browser copies it to the server. Would you like to add a…
phpasked Eduardo Santos 754 -
0
votes0
answers203
viewsQ: Filter with 2 ajax conditions
Good afternoon guys, I have an ajax filter that filters 1 result only. I need to filter two conditions, like a month and a person’s name in a schedule table. How can I do? <script…
-
0
votes2
answers112
viewsQ: $key starting with 1
Good afternoon guys, as I start a $key from a foreach for 1? foreach ($dados as $key => $reg) { $table .= '<tr> <td width="3%">' . $key . '</td> <td width="18%">' .…
phpasked Eduardo Santos 754 -
1
votes0
answers89
viewsQ: Calendar in php changing color of div
Good morning guys, I got this calendar on the Internet and I need it to change color when I have a notebook in the database. Look: $data = date('d/m/Y'); $data_explode = explode("/", $data); $dia =…
phpasked Eduardo Santos 754 -
0
votes0
answers29
viewsQ: Array with field orders instead of ID
Good afternoon guys, I’m having a hard time here. I have two tables, cursos and alunos_inscritos. The student table has an id(auto_increment), which records the course code for each registration. I…
phpasked Eduardo Santos 754 -
3
votes1
answer2861
viewsQ: Extract name and last mysql surname
Good morning Everyone, how do I extract the name and last name from a record. However the same should return the name and surname when you have only one surname. My table is like this. table =…
-
0
votes1
answer132
viewsQ: Redirect via htaccess
Good afternoon Guys, I need to do the following on my . htaccess. If the REMOTE_ADDR (IP) for nesse range 192.168.0.1 até 192.168.10.254 acessa por 192.168.0.5/system If the REMOTE_ADDR (IP) for an…
htaccessasked Eduardo Santos 754 -
2
votes1
answer69
viewsQ: Check the existence of data in the PHP database
Good afternoon guys, I’m having a hard time displaying a "Empty Data" message in my code, follow how I’m doing: <?php $dados = Connection::select("select * from clientes where clientnro ='" .…
phpasked Eduardo Santos 754 -
3
votes3
answers323
viewsQ: Optimize Ajax Search that Shows Slowness
I have a problem of slowness in this research in ajax. <script type="text/javascript"> $('#nome').keyup(function () { var chars = (this.value); $.post('../Ajax/busca_nome', {val: chars},…
-
1
votes0
answers33
viewsQ: Constants do not work in Javascript
Good morning Guys, I don’t know if I’ll be clear, but I’m having a hard time here. I need to set the URL path in my Javascript. define('URL', 'http://' . $_SERVER['HTTP_HOST'] . '/sistema/'); $html…