Posts by Rafael Weber • 604 points
27 posts
-
-2
votes1
answer86
viewsQ: How to run wmv in <video> (Google Chrome) tag?
I am unable to run . wmv, . mpg for example, in Chrome via tag . The code is more or less this, <video id="video1" class="videos"> <source src="temp/meuVideo.wmv" type="video/wmv" />…
-
4
votes3
answers457
viewsA: How can I return zero in front of other numbers?
I could do the following using the str_pad $texto = "A0001"; $novotexto = substr($texto, -4); $tempIni = substr($texto, 0,1); //Guardar inicio na variavel $soma = ($novotexto+1); $resultado =…
phpanswered Rafael Weber 604 -
0
votes0
answers62
viewsQ: Default acceptable parameter set in PHP function
In the example: public function getEstoqueDeposito($busca, $deposito = FALSE) { ... } I know what I could do: public function getEstoqueDeposito($busca, $deposito = FALSE) { if($busca == 'TOTAL'){…
-
8
votes3
answers2732
viewsA: Return hours and minutes apart with PHP
According to the PHP Documentation the version must be greater than or equal to 5.3 PHP Datetime::diff For your version I found a Question already answered that can help you.…
-
0
votes2
answers120
viewsA: Remove repetitions in select Oracle sequence
Finally, as I could not do via query, I played this part for application as a method in the class. Stayed like this... public function getEstagiosPorRoteiro($roteiro = 1) { $estagios = array();…
-
0
votes2
answers120
viewsQ: Remove repetitions in select Oracle sequence
I have a question to mount a query on Oracle, I have the following so far... SELECT M5.NIVEL_ESTRUTURA , M5.GRUPO_ESTRUTURA , M5.SUBGRU_ESTRUTURA , M5.ITEM_ESTRUTURA , M5.SEQ_OPERACAO ,…
-
1
votes1
answer349
viewsQ: PHP require_once without the need to pass the full path
I am with a legacy project, where all PHP files connect to the database through the file "oracle_ado.php" This file is in the folder ".. /inc/" and the rest in the folder ".. /Prod/". I am mounting…
-
2
votes5
answers7507
viewsQ: Change function of onclick
Guys I’m having a question. I have a button: <button type="button" class="btn btn-success btn-xs" onclick="vincularContato($(this))"><span class="glyphicon…
-
2
votes3
answers11376
viewsQ: How to return the first and last day of the current month in Javascript?
I’m having doubts on how to return the first and last day of the current month in JS.
-
6
votes3
answers11376
viewsA: How to return the first and last day of the current month in Javascript?
In charge of sharing knowledge, my solution was... var date = new Date(); var primeiroDia = new Date(date.getFullYear(), date.getMonth(), 1); var ultimoDia = new Date(date.getFullYear(),…
-
0
votes0
answers955
viewsQ: PHP accessing files from another micro on the network
I know this question can be marked as duplicate, but I haven’t found any definitive answer. After all, it is possible to access files from a computer on the same network, using PHP, without changing…
-
2
votes2
answers363
viewsQ: Using & in Oracle Search
I’m having a question about using & on Oracle. See below my table. When searching for the description 'Easy Breezy Emailmkt & Eu', Oracle opens a window for passing parameter, as shown…
-
1
votes2
answers257
viewsA: Concatenate variables in Jquery to send php only from the selected record
Since the data are not unique change the ids to 'classes'. I had a similar case and I took it this way. In the onclick of the button, I put a function passing the same button. In your case it would…
-
1
votes1
answer28
viewsQ: Doubt regarding the IN in Oracle
I’m putting together a query and bumped into a question. My query is like this: SELECT BASI_030.NIVEL_ESTRUTURA NIVEL, BASI_030.REFERENCIA GRUPO, BASI_030.DESCR_REFERENCIA, BASI_030.CONTA_ESTOQUE,…
-
0
votes1
answer249
viewsQ: AJAX return JSON size
I’m having doubts about using AJAX, I’m doing a function to assemble a list according to some filters. Everything is working perfectly, I return the JSON and mount the table. The problem is when my…
-
1
votes2
answers50
viewsA: I would like to know why python is saying that I have provided 3 arguments in this role?
The intention is to choose a number from 1 to 100? You can use random.randrange(1, 100); //random.randrange([start], stop[, step]) or random.choice(range(1, 100, 1)) //random.choice(range(start,…
python-3.xanswered Rafael Weber 604 -
3
votes1
answer962
viewsQ: Problems with Datepicker Orientation
I’m having trouble getting the datepicker to open down. Follow the datepicker parameters I’m using. $('.date').datepicker({ format: "dd/mm/yyyy", todayBtn: "linked", forceParse: false, autoclose:…
-
1
votes1
answer448
viewsA: Questions with File Upload
I don’t know if it’s right, but I managed to get around it this way. $('#arquivoCliente').fileinput({ language: 'pt-BR', uploadAsync: true, showPreview: false, maxFileSize: 200, uploadUrl:…
-
1
votes1
answer448
viewsQ: Questions with File Upload
My question is regarding File Upload using the http://plugins.krajee.com/file-input I have the following JS code $('#arquivoCliente').fileinput({ language: 'pt-BR', uploadAsync: false, showPreview:…
-
1
votes1
answer74
viewsQ: Questions with Dates less than 12/31/69 in PHP
Galley, I’m having a problem turning database dates to be displayed on screen. In my code I do the following. $objReturn['DADOS'][$key]['DATA_NASCIMENTO'] = date('d/m/y',…
-
1
votes2
answers2803
viewsQ: File storage, database or disk?
I am developing an intranet system, with a file storage module (exclusively PDF). What you tell me about the storage location, save to disk on the server or in a database? Remembering that it is an…
-
1
votes1
answer4141
viewsQ: Checking that the value of the database column contains only numbers in select
I need to find out if the value of a given column of the database contains only numbers in the select itself, because if it is numerical, I need to display the value of another column. I use an…
-
0
votes1
answer4141
viewsA: Checking that the value of the database column contains only numbers in select
Guys, I was able to solve it using the following: SELECT LENGTH(TRIM(TRANSLATE(TABELA.MEU_CAMPO_A_TESTAR, '0123456789',' '))) TESTE FROM DUAL; If the TEST returns null, the field contains only…
-
0
votes2
answers551
viewsA: Background printing issues using bootstrap in Firefox
Oops, I found a solution. I modified the style following Douglas' suggestion. style=" -webkit-print-color-adjust: exact !important; color-adjust: exact !important; background-color: #752740…
-
0
votes2
answers551
viewsQ: Background printing issues using bootstrap in Firefox
Good afternoon friends, I haven’t had much practice with Bootstrap yet, I haven’t been able to figure out a way to keep a div background when I print a page through the window.print() I have the…
-
3
votes1
answer103
viewsA: Doubt in SQL ORACLE query
I managed using UNPIVOT SELECT ID_3_ETAPA , PUBLICO FROM MINHA_TABELA UNPIVOT ( PUBLICO FOR PUBLICO_COR IN ( PUBLICO1 AS '1' , PUBLICO2 AS '2' , PUBLICO3 AS '3' , PUBLICO4 AS '4'))…
-
3
votes1
answer103
viewsQ: Doubt in SQL ORACLE query
I am thinking of making a View for the development of reports, and I bumped into the following problem. I would like to join columns PUBLICO1, PUBLICO2, PUBLICO3, PUBLICO4 in a single column. Ex.:…