Posts by Rodrigo Santos • 259 points
19 posts
-
1
votes1
answer219
viewsA: Dynamic background with CSS? How to do it?
Good afternoon you can use the card numbers and assemble an array with them and when using them just call the position of the array. example: var cartas = []; cartas[0] = '#f333dd'; cartas[1] =…
-
0
votes2
answers112
viewsA: window.innerWidth does not work on Windows Phone
You could try using css and solve this problem and still not using javascript processing because I believe that with css your case can be solved. //Html <div class="slide"> <div…
-
0
votes1
answer130
viewsA: Loading screen only when necessary
You can include the HTML part in the master part of your project and include the code in your css: .loader { .... display:none; } And on your screens that will use you can control the display of it…
-
0
votes1
answer322
viewsA: How to delete a product with ID in sessionStorage
//Salve o local storage da seguinte maneira var obj = { "dadosproduto": [{ "id": "01", "nome": "nome1", "quantidade": "10", "valor": "4" }, { "id": "02", …
-
0
votes3
answers4104
viewsA: Auto height in iframe?
Create a class and assign the property 'height:auto', if you wanted to limit a maximum size you can use max-height:''. Html <iframe class="frame"></iframe> Css…
-
1
votes1
answer693
viewsA: Delete session value from a variable
Creates a function that will call the reset that you currently use and will clean the Session through Ajax, all you need to do is call the function on the button where the type will be Button and…
-
1
votes2
answers79
viewsA: Refresh with php
The way in the example below you will call this function in the button, and in your page fav.php you mount the update, as you will have nothing to return or be an Alert or something like this can…
phpanswered Rodrigo Santos 259 -
0
votes1
answer162
viewsA: PHP-Mysql-Dialog
Just adapt to your use more follows a practical example. ///PHP code $campEmail = $_POST['campEmail']; // faz consulta no banco $sql = "SELECT * FROM usuarios WHERE email ='".$campEmail."; $consulta…
-
2
votes4
answers1318
viewsA: Disappear Button From Side
To select the element by class you use as follows. document.getElementsByClassName("classbutton").style.display="none";
javascriptanswered Rodrigo Santos 259 -
0
votes2
answers188
viewsA: Invert order of names in inputs?
Following practical example. <html> <head> <script> function inverso(){ var nome1 = document.getElementById("txtNome0").value; var nome2 =…
-
0
votes1
answer646
viewsA: Dropdown does not work in android browser
Recently in a project that uses mobile version I use the way below and met me perfectly, including in the issues that involves responsive design. <div class="collapse navbar-collapse"…
-
1
votes1
answer1794
viewsA: Redirect to mobile site
If it is the case of a fixed url you can use as in the example below that will return the full url to you in javascript. //get the url window.location.href; With this you just apply the rule of…
-
2
votes4
answers2160
viewsA: When filling in the Date field, perform a jQuery action
Using this way you are firing the event with each key typed in the element in focus, the correct would be to use . Blur() because the event would only be triggered when leaving the field ie having a…
-
6
votes1
answer1839
viewsA: How to close a database connection using PDO?
$pdo = null; You can use as in the above example more is not mandatory use as the connection is automatically closed after running the script.
-
1
votes1
answer80
viewsA: Animation with Problem in Safari
This may occur by the browser not recognizing the css properties try as the example below, which is an example where it runs in all browsers. //OPACITY -moz-opacity: 0.28; -khtml-opacity: 0.28;…
-
1
votes4
answers549
viewsA: How to get user name in URL?
$parse = parse_url( 'http://www.meusite.com/NICKUSUARIO' ); $value = trim( $parse['path'] , '/' ); Its url would be fixed and the user would type only what comes after the /, ex:…
phpanswered Rodrigo Santos 259 -
1
votes3
answers598
viewsA: Is it possible to assemble default layout for HTML pages?
/////javascript function function url(link){ document.getElementById("conteudo").setAttribute('src','paginas/'+link); } ////html links <div onclick="url('inicio.html')">Início</div>…
-
-1
votes3
answers598
viewsA: Is it possible to assemble default layout for HTML pages?
I usually use a standard page I call Masterpage.html and add my fixed elements to it, and the other pages I call via include the way I need to. Example have the default page with my Header and my…
-
3
votes2
answers21648
viewsA: Image alignment with CSS
In a search with this same problem one day I found this solution! ///////// CSS .center { display: flex; display: -webkit-flex; justify-content: center; align-items: center; } //////// HTML <div…