Posts by Jefferson Alison • 3,804 points
104 posts
-
1
votes2
answers278
viewsQ: Slow to load facebook like button
I have a div where you can find the social media section. I have a Facebook, Twitter and Google Plus like button. The Twitter and Google Plus finish loading together and is shown, while the Facebook…
-
2
votes2
answers415
viewsQ: How to use css Calc() in safari?
Calc() in safari is not working. I tried prefixes and it didn’t work either. Someone knows a solution? I’m wearing it like this: #myDiv{ width: calc(100% - 160px); width: -webkit-calc(100% - 160px);…
-
2
votes2
answers167
viewsQ: How to use Jquery Custom Scrollbar on elements with display:None
It does not mount the scroll bar on elements that are "display: None". Does anyone know how to solve? Here the scrollbar plugin…
-
0
votes1
answer240
viewsQ: How to leave textarea and button next to each other?
I need to implement a textarea(message) and a button(send) on your right side, but it is liquid (100%), that is, if you decrease the size of the window the textarea decreases and the button keeps…
-
3
votes8
answers5526
viewsA: How to make a DIV fill all available width
I guess that’s right: EXAMPLE CSS: //Opcional para pegar 100% de altura body, html, .menu, .resto{ height: 100%; color: #fff; } .menu{ width: 250px; float: left; background-color: #f09;…
-
12
votes3
answers18362
viewsQ: How to preview a loaded image in an "file" input?
Description: I have an example here of how my system is working. EXAMPLE LINK HTML <input type=file> <input type=button class=hide value="Adicionar outro"> JAVASCRIPT function…
-
4
votes0
answers931
viewsQ: How to make multiple image uploads with Rails 3?
I ran a scaffold with the name "Property", I need to add images next to it preferably in a different model referencing (1 Property can have many images), where the user can select more than one…
-
9
votes3
answers1752
viewsQ: How to take the current position of a div by his class?
For example: <div class="container"> <div class="position"></div> <!-- Essa tinha que ser position [0]--> <div class="position"></div> <!-- Essa tinha que ser…
-
5
votes2
answers262
viewsQ: How to use fadein() in addClass()?
I have ten "Id" class elements, minus the first. By clicking a button I remove the next Hide and add the class "show", but when adding it I want to put a fadein effect(). It is possible?
-
3
votes2
answers5577
viewsQ: How to see if a "file" input file has been selected?
Is there any way to know if the file type input has any file already loaded, ready to be sent? I want to make a condition where if you have some file to upload in the first input, then show an add…
-
4
votes1
answer252
viewsQ: How to use fadein() with an append()?
How to add fadein() effect, along with an append(). EXAMPLE
-
5
votes3
answers22986
viewsQ: How to add +1 in a counter variable to each click?
Each time I click a button, I want to add +1 to a variable. For example: I have a variable count receiving the value 5, when clicking a button I want the value 5 to change to 6 and so on, displaying…
-
8
votes1
answer506
viewsQ: How do I catch the current percentage of a download?
I want to get the value of the percentage of an ajax request on an external server. How to do? $("#uptade_space_disk").click(function(){ var url = "/calcular-espaco-em-disco" jQuery.ajax({ url: url,…
-
0
votes4
answers3248
viewsA: How to implement a textarea responsibly?
I advise you to always do styling in style file (.css, .scss, etc) and not inline or incorporated. Try it like this: Remove the style that is inline from the textarea; Use this css: #desc_pt{ width:…
-
2
votes2
answers1741
viewsA: How to fade icons using jQuery?
It is possible to do this using only css, through trasitions: HTML: <div class="circle"> <i class="icon-wrench"></i> </div> CSS: @import…
jqueryanswered Jefferson Alison 3,804 -
0
votes2
answers241
viewsA: Firing CSS Transition when performing ajax request
I think with fadein() and fadeOut() or maybe also with Animate() can help you.
-
5
votes7
answers39327
viewsA: How to create input masks with Javascript?
Here an example, works with 8 and 9 digits: Script: /* Máscaras ER */ function mascara(o,f){ v_obj=o v_fun=f setTimeout("execmascara()",1) } function execmascara(){ v_obj.value=v_fun(v_obj.value) }…
javascriptanswered Jefferson Alison 3,804 -
-2
votes3
answers1906
viewsA: Sublime Text File Browser just disappeared
Go to the view/view option => side bar/sidebar => show side bar/ show sidebar or press Ctrl+K and Ctrl+B.
sublime-text-2answered Jefferson Alison 3,804 -
-1
votes1
answer201
viewsQ: How to create a button with the Custom Scrollbar plugin?
Custom Scrollbar My idea is to create only one button. When you click it it is activated and with the automatic scroll working, when you click again it is disabled and disables the automatic scroll.…
-
6
votes2
answers8421
viewsA: How to run Android projects, on Eclipse, on a smartphone?
Left USB debugging option checked in Moto G? Then just turn on the device.
-
10
votes2
answers4248
viewsA: How to adjust the height of the div according to the text?
Use: word-wrap: break-word; in that div.
-
3
votes4
answers51666
viewsA: Responsive font-size depending on screen size
I have two options. 1) You can use a plugin to do this, here is a: FLOW TYPE 2) You can do this with media queries, where you can set in what width there will be modification, for example: /*…
-
0
votes11
answers97880
viewsA: Center image vertically within a div
Here a way: EXAMPLE HTML: <div> Este div está no centro! </div> CSS: div { width: 200px; height: 200px; margin-left: -100px; /* metade da largura */ margin-top: -100px; /* metade da…
-
10
votes5
answers62952
viewsQ: How to remove edge of input and textarea from all browsers when clicked?
Just look at the image to get an idea: When clicked this edge with blue shadow becomes visible. I think it is standard of all browser. Some solution?…
-
1
votes2
answers3652
viewsA: How to make the container reach the footer? (even with little content)
@Leandroruel, I made an example that can be seen by clicking HERE. HTML: <body> <div class="container"> <p>Quase nada de conteudo</p> </div> </body> CSS: body,…
-
7
votes5
answers2130
viewsQ: How to add a class to a <li> by clicking on it, leaving only it with this class?
For example: I have more than one ul with their li; If I click on a li of the first ul she has to add a class; If I click on a li of the second ul, she adds that same class. Only that does not…
-
1
votes1
answer65
viewsA: Write to ruby-on-Rails 3.2
Gravatar is very simple, put the line below in your helper, 'app/helpers/application_helper.Rb': def avatar_url(user) if user.url_image.present? user.url_image else gravatar_id =…
-
1
votes1
answer681
viewsA: Menu does not open levels on iPhone or iPad
You have an idea to do this here: HOVER DROP ? I tested it here on Safari, Chrome and Firefox. It worked. Try to add this code: $(function () { $(".sub").on('hover click', function () {…
-
2
votes1
answer297
viewsA: Register a Devise "User" through Seeds.Rb
You have to rotate the command: rake db:seed on the console.
-
1
votes1
answer134
viewsA: How to install Sass Gem on Windows
Which version of Rails is using? Try for the Gemfile: add the line: gem 'sass-rails' then run the command: bundle install…
-
4
votes6
answers53653
viewsA: How to change PATH in Windows
Windows 8 Arraste o ponteiro do Mouse até o canto inferior Direito da tela Clique no ícone Pesquisar e digite Painel de Controle Clique em -> Painel de Controle -> Sistema -> Avançado…
-
0
votes3
answers1686
viewsA: How do I fix the background of a <div> in iOS Safari (iPad)?
@Paulomaciel, let your id like this: #caixa{ background:url(imagem.jpg) no-repeat; height:300px; width:300px; background-position: center center; background-attachment:fixed; } Or try: @media screen…
-
1
votes4
answers2213
viewsA: Randomize the position of the images
1 - Rename images from 1 to 10, for example: 1.jpg, 2.jpg e assim por diante. 2 - Add an id to the element where the images were, for example: id="bannerRandom" var totalCount = 10; function…
-
6
votes4
answers44310
viewsA: Remove page element with javascript
Thus: var el = document.getElementById( 'conteudo' ); el.parentNode.removeChild( el );
javascriptanswered Jefferson Alison 3,804 -
12
votes3
answers1676
viewsQ: How to set a max-width to a div that increases and decreases proportionally?
My div which increases or decreases proportionally is with style: padding-bottom: 75%; Look at this example: Jsfiddle What I want is that the div that grows proportionately lock the size, when you…
-
1
votes6
answers14835
viewsA: Android app development: what are the tools and language to start a project?
An option for development for both Android, iOS and others is the Titanium Appcelerator. Works with MVC structure, most of its code is in javascript and easy to understand.…
-
4
votes8
answers4914
viewsA: Do not allow saving image of a web page
You can disable the right click as follows: $('img').bind('contextmenu', function(e){ return false; }); EXAMPLE Tried some plugin? Has some HERE.…
-
-2
votes4
answers1759
viewsA: How do I make all items in a menu equal in size regardless of quantity?
Add float: left nas li. And with jQuery have the following code: <script> $(document).ready(function() { $('.top-menu li').css("width", ($('.top-menu ul').width() / $('.top-menu ul…
-
3
votes2
answers10525
viewsA: How do I remotely connect to Git
Configure the GIT client to link commits to the correct name ( Author of commits) git config --global user.name "SEU NOME AQUI" git config --global user.email [email protected] To initialize the empty…
-
0
votes3
answers128
viewsA: Nomethoderror in Users#show
As you are learning now, it is good to start so by writing the code in "nail" and understanding. But it has a command called scaffold, it generates a CRUD basic from only one command line. Example:…
-
3
votes3
answers132
viewsA: Problems with table in IE
Try to add this goal: <meta http-equiv="X-UA-Compatible" content="IE=9" /> Tried to use the hacks? Have some here: #element { color:orange; } #element { *color: white; /* IE6+7, doesn't work…
-
4
votes1
answer380
viewsA: My Javascript gives syntax error in Chrome and Safari but does not give error in Firefox?
I found the mistake. On line 401 of my custom.js file I made a condition with the logical operator "Greater or Equal" like this: => the right thing to do: >= But I found it strange that in…
-
4
votes1
answer380
viewsQ: My Javascript gives syntax error in Chrome and Safari but does not give error in Firefox?
These are my files: <script type="text/javascript" src="js/jquery-1.9.1.js"></script> <script type="text/javascript" src="js/jquery-ui.js"></script> <script…
-
0
votes2
answers1212
viewsA: How to take background-color from padding?
Try it this way, buddy: CSS: div { padding:50px; background-image:linear-gradient(to bottom, rgba(240, 255, 40, 1) 0%, rgba(240, 255, 40, 1) 100%), linear-gradient(to bottom, rgba(240, 40, 40, 1)…
-
27
votes6
answers47964
viewsQ: What is JSON? What is it for and how does it work?
I usually come across this JSON, but I don’t know what it’s for and how it works.
-
3
votes4
answers1519
viewsA: How to change the appearance of the site according to the device used, without having to script on the client or server?
Study Media Queries, with it you define the sizes in which there will be modification in the layout, for example: When you reach the minimum width size of 767px change the background color for…
-
3
votes5
answers16498
viewsA: How can we not apply opacity to a child element?
In that case, I would advise using an image in . png with background opacity in the parent element, a 1px image by 1px repeating, is very light, some older browsers do not support this property.…
-
5
votes3
answers2323
viewsQ: How to know if you are resize in width or height?
Is there any way to see if the resize() window is occurring in width or is occurring in height?
-
0
votes4
answers59952
viewsA: Copy files via SSH between two remote servers
scp arquivo usuario@servidor:/home/usuario Doesn’t happen?
-
0
votes3
answers63205
viewsA: Image with 100% width
That depends, you want it to be 100% in the browser or in the element it is inside? It will open 100% inside the parent element, for example: <div style="width: 400px"> <img…