Posts by Caique Romero • 7,039 points
223 posts
-
4
votes2
answers7073
viewsA: Put If to Where
There are several solutions, I will mention 3 of them. In the examples below I check if the variable @idUsuario is void if the user name is not searched with the idUsuario corresponding to variable.…
sqlanswered Caique Romero 7,039 -
6
votes3
answers27822
viewsA: Show/Hide with CSS only
You can do this using the Checkbox Hack: Basically you connect a <label> to a <input type="checkbox" /> so by clicking on <label> you change the state of <input type="checkbox"…
-
1
votes1
answer12496
viewsA: Convert received value as int to char type in C
A character can only represent a number from 0 to 9. If you want to convert a number greater than 9 into a string see: Converting int to string Case really wanted a whole like char, you can do it…
-
1
votes2
answers817
viewsA: calculate input values with the same class
Just put your calculation in a function and call this function every time one of your <input /> of class Quant is changed. $('.quant').on("blur", Soma); function Soma(){ var soma = 0;…
-
7
votes3
answers11852
viewsA: Show a number in 2 decimal places
The calculation you already do, so I understood what you want is to show the value in 2 decimal places, for this, you can use the method toFixed() of JS. The toFixed() method formats a number using…
javascriptanswered Caique Romero 7,039 -
4
votes3
answers130
viewsA: How do I call the next field of a table with Javascript or Jquery?
I created a método to shift focus and placed the call from método in the <input /> dynamically created. <input type='text' onkeydown='MudaFoco($(this), event)' value='" + conteudoOriginal +…
-
1
votes1
answer656
viewsA: btoa javascript e base64_decode php
I made a simulation similar to your PHP code and it worked correctly. What may be affecting result is the value you receive in request, see if there is no special character. You can use the function…
-
0
votes2
answers58
viewsA: List of Numbers
First think of the logic you need, basically we will get the following idea: If the counter is equal to 2 or equal to 9 I should not display it OR If the counter is different from 2 and different…
javascriptanswered Caique Romero 7,039 -
7
votes6
answers1015
viewsA: How could I highlight the radio button that is selected?
Here is a suggestion to highlight the selected option. I added a background to the text and made it alternate according to the selected gravity: CSS added: h1 { background-color: rgb(212, 212, 212);…
-
0
votes1
answer1669
viewsA: It is possible to edit the html 5 input date style
Below I put an example of the use of datepicker of jquery with its basic theme, in this link you can see the css of the basic theme (just search for datepicker and you will see some of its classes…
html5answered Caique Romero 7,039 -
1
votes4
answers381
viewsA: remove text inside small without raising the "a" tag with jquery
I created a button that when clicked will store the link in a variable (selecting by its class hyperlink) then clear the contents of the tag <small> with the method Empty() and then add to its…
jqueryanswered Caique Romero 7,039 -
1
votes3
answers930
viewsA: Email Submission Form - Classic Asp
Below is a basic example of sending E-mail with the component CDOSYS of the classic Asp. <%@LANGUAGE="VBSCRIPT"%> <% 'Passo 1: Criar o objeto CDO.Message Dim objMail Set objMail =…
-
4
votes1
answer835
viewsA: onClick function does not work properly
The problem is in the way the onclick. The error occurs because the JS is case sensitive and the correct syntax is in lowercase. var colorButton = document.getElementById('colorButton');…
javascriptanswered Caique Romero 7,039 -
0
votes3
answers104
viewsA: Doubt with sql Inner Join in multiple tables
If you want to view the first saved photo you can use the MIN() if you wanted last inserted you can use the MAX(), note that I asked you if there was a column to identify the photos in your table…
mysqlanswered Caique Romero 7,039 -
2
votes1
answer162
viewsA: Mysql problem with empty column query
You can return all contacts regardless of the existence of a company using LEFT JOIN: LEFT JOIN: Returns all records from the left table (table A) and any matches with the right table (table B).…
mysqlanswered Caique Romero 7,039 -
1
votes5
answers683
viewsA: How to take input readonly
Well there are some small syntax errors in your code that are affecting the functioning. Check the closure of your <div class='form-group'> for some were left without </div> Do not use…
-
9
votes4
answers24927
viewsA: Regex - Picking text up to a given string
You can use /(.*?a\))/s to obtain all characters including to) You can use /(.*?)a\)/s for all characters prior to to) Explanation: .*? Identifies all characters a Identifies a a literally…
regexanswered Caique Romero 7,039 -
0
votes2
answers263
viewsA: join sql tables without Primary Keys or Foreign Keys common to 2 tables
Even if there are no keys declared, you have described these fields as follows: agency.id = account.agency_id So a simple JOIN resolveia, depending on the result you want a subselect may be…
sqlanswered Caique Romero 7,039 -
1
votes1
answer353
viewsA: How to fill in selected input only
From what I understand you want to manipulate the last focused element before clicking the modal button. To do this I added a classe to all the input I wish to observe every time one of these input…
-
5
votes1
answer416
viewsA: How to group Counts for different queries into one?
Yes you can unify them in a single query, for that you will make use of CASE WHEN and GROUP BY. GROUP BY: With its use it is possible to group several records based on one or more columns of a…
-
4
votes1
answer47
viewsA: Problem with . find()
You can simply take the "id" attribute of the element that has both the "bull" class and the "Selected" class": var slide_act = $(".bull.selected").attr("id"); Jquery class selector See example…
jqueryanswered Caique Romero 7,039 -
0
votes1
answer1418
viewsA: Name table resulting from SELECT
You must position the Subselect in front of the INNER JOIN and then you can give a nickname to your selection as if it were a table. SELECT * FROM hierarquia INNER JOIN ( SELECT * FROM recurso WHERE…
-
0
votes3
answers1292
viewsA: How can I manipulate CSS from parent element to clicked element?
To access the parent element you can use the .Parent() of Jquery to catch the div "clicked father" and so manipulate his CSS. $(this).parent("div").css("background-color","red"); Follow below…
-
1
votes5
answers1124
viewsA: View JSON object
You can use the method foreach() to traverse the arrays of his objeto json. var json = [ { "nome": "Meu Nome", "amigos": [ { "amigo": "João", "idade": 20 } ] } ]; json.forEach(function(item) {…
-
0
votes4
answers3686
viewsA: How to get javascript/jquery array content?
An alternative only with JS without having to convert your array for a objeto JQuery is using the method foreach() performing a given function on each element of a array, so you will need to create…
-
5
votes1
answer276
viewsA: Change the visibility of a select
You must not define onchange 3 times, the way it is only the first method (showCampogol) will be fired. You must include the 3 function calls in a single onchange: <select class="form-group"…
-
1
votes3
answers1115
viewsA: Filtar Birthday of the day
You can search all records that are from a given day using the function DAY() and month using function MONTH() as follows: SELECT * FROM tblcliente WHERE MONTH(DataNascimento) = 12 AND…
mysqlanswered Caique Romero 7,039 -
4
votes2
answers3896
viewsA: Cancel sending jQuery form
Use the Event.preventDefault() to prevent the submit is executed, call the function by passing the event as parameter. Example: $("#form-anuncio-edita-texto").submit(function(event){…
-
21
votes2
answers3969
viewsQ: What is Garbage Collector and how does it work?
What is Garbage Collector, how it works? When should we care about him?
-
4
votes0
answers40
viewsQ: Difference in Javascript array declaration
What is the difference between these two forms? var a = []; var a = new Array();
-
0
votes0
answers106
viewsQ: Run order of searched CASE expression
The CASE WHEN has two forms of functionally, with simple and researched expressions: The expression SIMPLE CASE compares an expression with a set of simple expressions to determine the result. The…
-
3
votes4
answers15459
viewsA: What is the difference between LIKE, IN and BETWEEN in Mysql?
Between: Definition, used to return records based on a range of values. Property for numeric type or date fields, e.g..: SELECT * FROM Funcionario WHERE Admissao BETWEEN '2017-09-01' AND…
-
0
votes1
answer61
viewsA: Catch Ids Tagsmanager
By default when you create a tag its value is added to input by name Hidden-tags: <input type="hidden" name="hidden-tags" value=""> Only with this field already possible to get the data on the…
-
1
votes3
answers588
viewsA: hiding component input when selecting a value in the select field
Basically you will need to observe every time the value of your select is changed and when the value changed is equal to the value of the "Brazil" option then you must hide the input. You can do…
-
2
votes2
answers153
viewsA: Hide everything but the clicked element
I think you are hampered your life needlessly, try to classicize the elements you want to hide or display, and use the $(this) to identify what was clicked. Understand how the this and what’s your…
jqueryanswered Caique Romero 7,039 -
1
votes2
answers305
viewsA: Button conflict when sending form with jquery
You must define the type of <button> for the value pattern for the maroria of the navigators is Submit, with the exception of IE7 and its previous versions where type standard is button. type…
-
9
votes5
answers47771
viewsA: Centralize a table (HTML)
The text-align serves only to align the text of an element, so it is not able to align the table. The estate margin allows you to define the margins around the element (a space around it, being it a…
-
0
votes1
answer1903
viewsA: Automatically set date and time in HTML table
I made an example using your way of creating the date and the HTML that you shared. I created a function that searches the first column of the first table with the class table and concatenates the…
-
3
votes4
answers190
viewsA: What is the default value of the "cursor" attribute?
The CSS cursor property specifies the mouse cursor shown when the mouse pointer is on an element. The initial value of this property is auto, what happens is that he is converted by browser in…
cssanswered Caique Romero 7,039 -
1
votes2
answers1699
viewsA: Image appear while hovering over text
I made an example using only CSS, I left the code commented for a better understanding, follows below the code and some references: :Hover Combinator ~ Display property /* Defino o tamanho de todas…
-
5
votes2
answers260
viewsQ: What is the difference between Cssclass="example" and class="example"
I came across the following piece of code: <asp:Label ID="lblStatus" CssClass="labelFiltro" runat="server" Text="Status:"></asp:Label> Until then I didn’t know CssClass, would like to…
-
1
votes2
answers890
viewsA: Modal bootstrap does not appear when clicking button
Try to change from: <link rel="stylesheet" type="text/css" href="./DataTables/DataTables-1.10.16/js/bootstrap.min.js"/> To: <script type="text/javascript"…
-
0
votes5
answers1054
viewsA: How to make each input stay on a separate line?
There are several ways you can do by using CSS display input { display: block; } You can entertain the elements in Div .log-adm { text-align:center; } <form action="" method="post" name="loguin"…
-
6
votes1
answer73
viewsQ: Meaning of expression <%# "example" %>
I’m used to seeing expressions like <%= "Olá" %> but I came across a code: <asp:Image id="imagemStatusDocumento" runat="server" ImageUrl='<%# ObtemImagem(Eval("NomeTipo")) %>' />…
-
0
votes2
answers63
viewsA: Put records on one line only
You can do this query using a subquery. See working: Sqlfiddle SELECT s1.nomusuario [Usuario] , 'Login/Logout' , s1.data [Login] , ( SELECT MIN(data) FROM sistema [s2] WHERE s2.nomusuario =…
sqlanswered Caique Romero 7,039 -
4
votes2
answers503
viewsA: How to write numbers between 0 and 10 to a file
First bar is reversed in the file path. According to function fopen receives some parameters the parameter fopen("file", **a**) indicates that it will concatenate at the end of the file, use the…
canswered Caique Romero 7,039 -
1
votes1
answer322
viewsA: Image in select
I researched and found several ways to do this, I will put here the one I found most practical, using HTML, CSS, JQuery. Reference with tutorial: Reinventing a drop down with css and jquery…
-
2
votes2
answers711
viewsA: INNER JOIN + LEFT JOIN
Failed to list all tables, try the select down below. SELECT TAFCBHISTPED.NUPED, TAFCBHISTPED.DTEMIS, TAFGRPROD.CDGRPR, TAFGRPROD.DSGRPR, TAFPROD.CDPROD, TAFPROD.CDGRPR, TAFITHISTPED.NUPED,…
-
7
votes4
answers3636
viewsA: Input date to disable the next 7 days from the current date
You can use the function getDate() to get the current date day and add up 7, then you can use the function setDate() to set a new day for the date, being the result of the sum. Note: If the number…
-
0
votes3
answers406
viewsA: PHP array that is not getting values
You incremented the values in the variable $pos but tried to display the values of $sum, Another thing you’re not doing is displaying the vector values at each iteration. See working Follow full…