Posts by WMomesso • 2,489 points
115 posts
-
-3
votes2
answers79
viewsQ: Regular expression for validating string and int in php
I need to validate this string. $scop = "ES-1236"; fixed value access key ES- dynamic 1236 the dynamic being only integer numbers. to validate I am creating a variable with the search $lets = "ES-";…
-
1
votes1
answer129
viewsQ: How to change the value of an attribute within a`TD` using jquery?
I have the following table: var saldo = 10; $(".saldo").click(function(e){ e.preventDefault(); $(this).closest('tr').find('td[data-saldo]').html("10.00");//setando o valor da coluna…
-
2
votes1
answer120
viewsA: V-FOR is not working in my APP?
Problem solved by inserting a div father with the class="row" within the component. In the index.html file <div class="container"> <div id="app"> <router-view></router-view>…
-
0
votes1
answer120
viewsQ: V-FOR is not working in my APP?
I am developing an app in Vue.js but I have some error in the array data: that contains some chat rooms, if I leave only the template it renders normally, but when entering the data with data :…
-
3
votes1
answer132
viewsA: I’m having trouble ordering the birthday boys of the month on Eloquent of Laravel 5.7
It’s simpler than I was imagining, just change orderBy('birthday') for: orderByRaw('day(birthday) asc') How claulas work with termination Raw It does the raw query to the database, meaning you can…
-
2
votes1
answer132
viewsQ: I’m having trouble ordering the birthday boys of the month on Eloquent of Laravel 5.7
My query returns the birthday boys correctly, but when sorting by table column it sorts by year and by day. This is my query $birthday = \App\Admin\Clients::whereMonth('birthday',…
-
1
votes1
answer53
viewsQ: Update one table to another with Where?
I have two tables one where the purchase order data and the second table where the items are. Table A id | ordem_compra | fornecedor | data Table B id | ordem_compra | desc | qtdade | valor | status…
-
1
votes2
answers82
viewsQ: Select inside the Where leaving the query too slow?
I have the following structure: And my query is that way SELECT tbl_nfes.*, count(tbl_nfe_itens.pedido > 0) as v, tbl_nfe_itens.status FROM tbl_nfes INNER JOIN tbl_nfe_itens ON tbl_nfes.nfe =…
-
0
votes2
answers865
viewsQ: Stop running a javascript function, inside jQuery each?
I need to interrupt the execution of .each when an option is not met, I am using return false;, but the code after the block each is still running. Follow the example of the code: function…
-
1
votes1
answer128
viewsQ: Do I want to show the birthday boy two days before or after the event?
I have a consultation that shows on the system Dashboard the birthdays of the week, all who make birthdays between Sunday and Saturday are displayed on the screen, but it is very annoying to watch…
-
0
votes1
answer261
viewsA: How to put 3 parameters in input value? Laravel 5.7
After searching a little, I found a solution that met my problem, just enter in the value a third parameter using the ternary operator ?:. Example. <input type="text" name="address_province"…
-
0
votes3
answers1764
viewsA: PHP + Mysql - Quote syntax error in String
To escape ' utilize addslashes() it inserts a bar \ that escapes the value. example: $name = "My name is D'Orail"; echo addslashes($name); //result # My name is D\'Orail Access documentation for…
-
-1
votes1
answer261
viewsQ: How to put 3 parameters in input value? Laravel 5.7
I need to put a default value in a text input. The default value will be 'Brazil', but I’m using the old helper in Blade and I don’t know how to enter this default value. the code I’m using is this.…
-
0
votes1
answer42
viewsQ: Find array within a string?
I have a column in the database that saves a free text, and together is saved some data within [ ] is to find only what is inside [ ] in this string to convert it to an array. Example: $texto =…
-
1
votes2
answers1765
viewsA: Sort by value in Datatables
At that time the plugin is able to handle this problem using the language attribute to translate parts of the system to the native language of the system and to enter regional settings, to…
-
2
votes1
answer40
viewsQ: Error incrementing value in inputs with same class?
I have a function that creates a loop of inputs depending on the number of installments entered by the user and when inserting a value in the first one it increases by 1 each of the following…
-
7
votes1
answer173
viewsQ: How to insert 2 inputs into the same TD with duploclick?
I would like to insert 2 inputs in a td, today my code works with only one input, and even saved the information in the database, but I need to include one more input to be inserted a password to…
-
0
votes1
answer1151
viewsQ: Add up final total value using group by Mysql?
I have the Sales table and the seller table and I would like to know the % of sales of each seller. table vendor Id | Vendedor | 1 | Fulano | 2 | Beltrano | table request Id | Id_Vendedor | Valor |…
-
1
votes1
answer864
views -
2
votes1
answer864
views -
2
votes1
answer70
viewsQ: Using a button or dropdown to separate the query by alphabet letter?
I’m using the DataTable to better organize some spreadsheets of my system, however the client suggested me the possibility of pagination buttons to be replaced by letters of the alphabet, instead of…
-
1
votes1
answer38
viewsA: Firefox error to focus input, after element Blur itself?
I solved the problem as follows traded $("#txtPrazo").focus(); For setTimeout(function() { $("#txtPrazo").focus(); }, 0); $('#txtPrazo').blur(function() { var days = parseInt($('#txtPrazo').val());…
-
2
votes1
answer38
viewsQ: Firefox error to focus input, after element Blur itself?
I need the input to stay in focus after the blur if you do not comply with the request. The data of this form are dynamic are created after a consultation ajax, here in the snippet the code worked,…
-
1
votes2
answers61
viewsQ: Query with Internet
I need to check if a data in Table 1 is represented in table 2 In the tabela1 ID | NOME | PARCELAS | DATA | NF In the tabela2 ID | VALOR | PARCELA | VENCIMENTO | NF SQL query with INNER JOIN I may…
-
1
votes1
answer43
viewsQ: Date query in mysql?
I need to consult and introduce the birthday kids of the week at Dashboard system, but today a birthday is not being displayed and would like to know where is the error. Anniversary column:…
-
1
votes2
answers576
viewsQ: Leave input to Focus after Alert
I have a form that is valid if the typed Cpf or cnpj is valid, but if it shows an error it changes to the next input, but I would like it to remain in the Cpf input still for validation. Example:…
-
2
votes1
answer40
viewsQ: I have many INNER JOIN in the query, can you minimize?
I have a query in a database that uses several INNER JOIN and I realize that in some moments the system slows down in this request, has how I reduced it? Below follows explanation of my structure…
-
0
votes1
answer1014
viewsQ: Insert records from one table into another in Mysql?
I’m having difficulty entering data from one table into another, for example I have the budget table that has the items, but the items may be from different suppliers, and when approved this budget…
-
2
votes1
answer253
viewsQ: Increase payments to installments with Jquery?
I have a dynamic form and made a function to somar 30 dias after the first due date, but insert dates having the day 31 or day 01 is making the calculations wrong, for example: if I enter 31/12/2017…
-
2
votes1
answer484
viewsQ: How to focus input from a form constantly?
I have a form and need to focus on an input again until it satisfies the required, example: $('#text1').blur(function() { var teste = $('#text1').val().length; console.log(teste); if(teste > 5){…
-
2
votes1
answer28
viewsQ: Know the Nth of the clicked item to select an input on the same Nth?
I have a table where I have a checkbox to enable editing several items at the same time, that is I can edit several items since the input is selected, but I have a problem that if I want to edit…
javascriptasked WMomesso 2,489 -
0
votes1
answer566
viewsQ: Is it possible to link to php include with jquery?
I have a php page that makes require header, sidebar, and footer, but the content of body would like to pay dynamically by passing the link to require via jquery, do not want to work with framework…
-
2
votes1
answer47
viewsA: Aligning button to center does not work
Utilize Flex-Box, to organize the layout, in case I used only 3 lines to center the button. Start flex - display: flex; display: flex; // para startar o flex align-items: [flex-start] [flex-end]…
-
1
votes1
answer373
viewsA: Tabs inside a modal when clicking disappears the modal
See how the import of css and of his js in the header do html see the sequence. CSS do Bootstrap CSS customizado JQuery JS do Bootstrap JS customizado Whereas the files .JS can be at the end of the…
-
1
votes1
answer79
viewsA: Boostrap Validator
@Jorgeferreira failed to insert the class help-block with-errors which uses the error generated by data-error="Isso nao é kg" $(document).ready(function(){ $("form").submit(function(){ var…
-
1
votes1
answer620
viewsA: Problem with ROW Bootstrap
Let’s go in pieces. Grid in the bootstrap: Up to version 3.3.7 See the BR documentation for version 3.3.7 for a base In version 3.3.7 the bootstrap divides the screen into 12 equal parts, but uses a…
-
1
votes2
answers460
viewsA: Use 2 different frameworks in the same CSS?
If both fremeworks own the files SCSS unification is possible, but let’s go to the pros and cons. Pros As you mentioned that besides the junction will make the minification, this can better load the…
-
6
votes2
answers49314
viewsQ: Commands to update Ubuntu apt-get update or apt update sem get?
In the company we received the instruction to run the following commands every morning, but the current project manager did not know how to answer me the reason and in the internet search I did not…
-
1
votes1
answer563
views -
1
votes1
answer999
viewsA: Line spacing
You need to subscribe to the class .row worthwhile 0 and add the attribute !important, so that it can subscribe to the default value. To subscribe to the classes you need to create a new css file,…
-
2
votes1
answer1253
viewsA: How to place the bootstrap table on a background image?
I will make an example using the table of bootstrap then you need to adapt to your project. I used a div to the example just to exemplify, can be the body page. Remembering that in bootstrap when…
-
1
votes1
answer2632
viewsA: Fill in INPUTS with ajax
Your query of mysql is only seeking ID,NOME, for it to return more results need to enter them in your search or use a joker * return all these data, example exchanges your query: "SELECT ID,NOME…
-
0
votes2
answers79
viewsA: Error trying to minify js files in Grunt
I do not see something wrong in the configuration, and put of the path and the folders conforms your application, I made an example with only the uglify, because it seemed to me that it is in him…
-
1
votes3
answers1416
viewsA: Disable field if another one is filled
In his code was already set to the input internal code be disabled, that way the same would not change the status because you wanted to change to a state that was already set.…
-
1
votes3
answers934
viewsA: Best way to save login data
In the validation of ajax you can already set the variables with the database data. I’m going to make a very small example just to illustrate the use of Session, which saves the php After validating…
-
4
votes3
answers291
viewsA: Is it correct to write CSS with Javascript?
This can have a big impact on layout development, unless you just want to work with the static look of the framework, here comes the problem of customizing the lines of code in the js to have the…
-
1
votes2
answers4381
viewsA: Height of Row in bootstrap using percentage (%)
You must change the value of line-height: i put 2.0 but you need to adjust this in custom css (custom.css I refer to your css file) and insert the attribute !important to subscribe to the bootstrap.…
-
0
votes3
answers1086
viewsA: Storing an attribute’s value in a variable in jquery
You can create an attribute in the link tag <a data-link="valor_atributo" href> and recover this data in jquery. the code below is very simple but provides the answer to the solution. $("li…
-
2
votes1
answer111
viewsA: Using sql_cache in Mysql query
Yes has an impact on the query if it is performed again, and can precede with two types those that store the query in cache and a second that does not store and are used with low frequency. But stay…
-
0
votes3
answers130
viewsA: Deselect checkbox in chain
Have many ways to work with jquery I did with class directly in the element, working on the div you end up forgetting that the element is still set, but just do not forget this detail at the time of…