Posts by dsantoro • 883 points
50 posts
-
1
votes1
answer99
viewsQ: Django 1.11. Serving robots.txt, sitemap, etc.
I need to know how to serve these files that usually go to the root of the project. I’m making a route for each of them in the.py urls file but it doesn’t seem the right way. What’s the right way?…
-
1
votes3
answers189
viewsA: Is there any way to write a function on the screen other than by onclick?
There are several listeners that can be used, follow some examples and forms of application with pure Javascript: document.addEventListener('click', suaFuncao(), true); // No Clique…
-
1
votes1
answer32
viewsQ: Calculations with Less css
I have the following mixin: .mixin-loop (@i) when (@i > 0) { .navigation .dropdown > li:nth-child(@{i}) { .vendor(animation, new-menu 200ms ease-in-out forwards); } } This . vendor being only…
-
1
votes1
answer57
viewsQ: Variable returning null only in Firefox
I have the following piece of code: var cta = document.querySelector('.cta'); In Chrome/Opera it returns the element correctly, only in Firefox it is returned me the error : TypeError: cta is null…
-
10
votes1
answer7371
viewsA: Round up values jQuery
You can use Ceil function(); Math.ceil(1.4) Returns 2; Source
-
0
votes1
answer27
viewsQ: Regex, if the variable contains a particular Character
I have a link for exexplo: <a href="#sessao">Sessão</a> And another link : <a href="https://...">Link Externo</a> I would like to know how, I believe by regular expression, a…
-
2
votes2
answers54
viewsQ: jQuery each - Clarification
I need every x seconds a li my menu is hidden and I have this code: $('.area-menu .close').click(function(){ delayed(); }); function delayed() { var liMenu = $('.area-menu li').not('.marginless');…
-
0
votes0
answers91
viewsQ: clip-path with Firefox problems
I’m using the clip-path technique to make a polygon in a certain area of the site: .cliped { -webkit-clip-path: polygon(0% 0%, 100% 0%, 100% 100%, 0% 75%); -ms-clip-path: polygon(0% 0%, 100% 0%,…
-
1
votes1
answer129
viewsA: CSS 3 Serrated Skew in Chrome
I used my head well and I got the code: -webkit-backface-visibility: hidden; that solved my problem.
-
0
votes2
answers2930
viewsA: Center caption of a figcaption image
Simply assign a display block to i: figcaption p i { display: block; text-align: center }
-
1
votes1
answer129
viewsQ: CSS 3 Serrated Skew in Chrome
When using the Transform: skew(value) property in Webkit browsers it displays a certain serration where it gets angled: -webkit-transform: skew(20deg); -moz-transform: skew(20deg); -ms-transform:…
-
1
votes1
answer227
viewsQ: Transition-delay css 3
I have a Hover effect that assigns a display: block in an element. I wish there was a delay of 2 or 3 seconds before the element that receives the block appears. I know about this Transition-delay…
-
2
votes1
answer43
viewsQ: Function similar to strip_tags
Is there any type of strip_tags that I pass by parameter the elements that I DO NOT allow? Suppose I have a string "blabkabla<span>bla<span><p>blablabla<p>". I want for…
-
1
votes1
answer141
viewsA: Centered slider
The browser uses default values of margin, padding, etc... if not set. What you can do there is simply take your #slider ul and zero margin and padding: #slider ul { list-style: none; padding: 0;…
-
2
votes1
answer141
viewsQ: Enable Javascript within a Fancybox
I need to make a slideToggle in the window of a Fancybox. The normal method of catching the (elemento).click(functiom(){...}) I know it doesn’t work. I just know that we should use the .on() jQuery…
-
0
votes2
answers1011
viewsA: Align vertically to center footer items
Use display: table-cell and vertical-align: middle
-
1
votes1
answer391
viewsA: Problem with include.php positioning
The CSS you posted does not say whether the box has relative or absolute position or any other. Z-index only works if a position is declared. And if it is position: absolute should be relative to…
-
0
votes4
answers3635
viewsA: How to center a div with variable size and position Absolute?
Variable how? Responsive? You are or should be using a "container" in the entire content to centralize the information. If you’re using the container and the site is responsive, set a width value…
-
2
votes2
answers886
viewsQ: Share Facebook
The facebook documentation is kind of flawed. What parameters should I pass to share a product and its photo on facebook coming from a site? I create the path of the page: $url =…
-
1
votes2
answers1169
viewsQ: Fiscal Printer
I need to print a normal HTML page but using a tax printer (I don’t know if this is the correct term but it’s those smaller printers that we see in markets). There is an "emulator" to do these…
-
2
votes1
answer157
viewsA: What is the best logic to implement sub-menu with mouse events
I don’t quite understand your question but I like to do this with css only. Your problem is that the menu cannot lose focus or the submenu will disappear. I suggest you "paste" your block with your…
-
3
votes1
answer1673
viewsQ: jQuery function must be executed only on mobile
I think the title is self-explanatory. I need a particular function in jQuery to "activate" only when I’m at a resolution less than 1024px.
-
-3
votes3
answers78
viewsQ: Wordpress content
Is there the possibility of Wordpress bringing information from the bank without being in the form of Posts? In case I want to make a site "conventional" as I would register and pull this…
-
0
votes1
answer68
viewsQ: Wordpress menus
I have to make a site, those with a page only with automatic scroll, but in Wordpress. What is the function that I can use that does this? I mean, just the ones that carry the menu items.
-
3
votes4
answers787
viewsQ: CSS transparency
I know that if you use opacity on a div, all the elements inside it will also be opaque. And I also know that I can use RGBA to make an element with a background color transparent, but how do I…
-
0
votes1
answer2967
viewsQ: Break line into links
I’m developing a mobile site and I’m having a problem, when I have a very large link (no spaces or '-' hyphens), it doesn’t "break" and leaks the layout. There’s a way to fix it?
-
2
votes2
answers340
viewsA: Apply jQuery effect to the current HTML element?
It would be something like this: $( ".titulo" ).mouseover ( function() { $(this).prev(".overlayContent").css("display", "none"); } ); $( ".titulo" ).mouseout ( function() {…
-
2
votes2
answers83
viewsQ: Rotate CSS3 and Tables
I am using tabular data in a table and some information with 90 degrees (standing) in the cells. However css does not behave as expected and leaves large spaces as if the text is normal…
-
2
votes2
answers118
viewsQ: Versions of Jquery
Is it just me or is someone else having that problem? I use the Zurb Foundation to create my responsive websites and ALL fade sliders give problem. Both the plugins and the ones I do at hand. And…
-
1
votes1
answer282
viewsQ: font-face Internet Explorer
I’m having a problem loading into my sources in IE. It takes about 1 minute to load. Someone else goes through or has already gone through this? @font-face { font-family: 'yanone_regular'; src:…
-
3
votes1
answer407
viewsQ: Test Jquery classes
I know that to test if an element has a class we use hasClass(), but my question is as follows. I have an element with a class and assign a second class to it with classToggle(). Is there a way to…
-
5
votes3
answers138
viewsQ: Does every DIV have a relative position?
I heard from a development professional that: "All div is relative even without you define position:relative" That is correct?…
-
0
votes1
answer125
viewsQ: Iframes and Fancybox
I’m looking to open one iframe Google Maps in a Fancybox via fancybox.iframe. But it makes the following mistake: No 'Access-Control-Allow-Origin' header is present on the requested resource. I know…
-
3
votes2
answers286
viewsA: Toggle in a div next to (or below)
$('#elemento-de-clicar').click(function(){ $('#elemento-alvo').slideToggle(); });
-
1
votes3
answers977
viewsA: How to make Divs with same height and 100% height
You can take the height of the browser via jQuery or Javascript and declare a CSS for these divs with that height. Example with jQuery: var altura = $(window).height(); $('.alvo').css('height',…
-
0
votes2
answers2098
viewsQ: Browse the entire DOM with jQuery
How to go through the whole DOM and find a certain element in jQuery? Yes, by clicking on li of classe="home", open the div of classe="submenu". <body class="home"> <!-- Header -->…
-
0
votes2
answers149
viewsQ: Function jQuery to hide elements
I have a window that opens when clicking on an element, blz. But how can I do to, when clicking OUTSIDE of that window, it closes?
-
1
votes1
answer818
viewsQ: Redirect with click jQuery/Javascript
I have a home page where when clicking on a menu item, redirect to another page and a click in a given service in a "accordion/accordion". I have something like this: var index =…
-
3
votes5
answers17141
viewsA: Ignore CSS on a particular page snippet
If you want to "ignore" the legacy of CSS you would be losing the sense of cascade. What is advisable to do and rewrite css for your specific element and if inheritance persists you add ! Important,…
-
1
votes4
answers143
viewsA: Get date-img value
Call the tooltip inside where you call the function of Hover and in place of the 'IMAGE HERE put the variable that has the value of the data img. That should solve.
-
2
votes3
answers201
viewsQ: Internet Explorer Mode Patterns
Is there any way to "force" Internet Explorer and render a website in "Standards" mode? Could you give me some reading on this subject?
internet-explorerasked dsantoro 883 -
0
votes4
answers1502
viewsA: Divs floats in a container with height auto
I particularly solve this with a float:left in the parent element. But the correct thing is to use the clearfix that friend Diego Lopes Lima commented.
-
1
votes4
answers8606
viewsA: popup open only 1 time after being closed, even after reloading page
Usually you apply a Fancybox with the banner and arrow a Cookie in the browser. Then check: IF this Cookie still exists it no longer displays the Popup. After it expires (you set the number of…
-
3
votes3
answers88
viewsA: How to always leave 20px margin at the bottom of the page?
If the problem is with position absolute, use a bottom: 20px. On the other hand margin-bottom in body resolves.
-
0
votes4
answers477
viewsA: Height of one div based on another div
Save the value of the div #publicidade in a variable: var tamanho = $('#publicidade').height(); Then assign this value to the div #result777 : $('#result777').css('height' , tamanho);…
-
-2
votes5
answers1352
viewsA: Previous "Else" without "if" error
Two common mistakes in new programmers consist of: Lack of attention and not giving value to good practices. Note that you have declared the variable as "delsta" and use it as "delta". no if(a = 0)…
-
1
votes2
answers946
viewsQ: Query the return of an Ajax
I have a field select and need to query and load the result dynamically with Ajax. I currently have the following code (which does not appear to work or to be incomplete): $('#formProd…
-
1
votes2
answers255
viewsQ: Multiple clicks
I have the following code snippet: var Tannerie = { init : function(){ $('#prev').mouseover(Tannerie.prevClick); $('#next').mouseover(Tannerie.nextClick); }, prevClick : function(){ $(this).click();…
-
0
votes1
answer73
viewsQ: Jquery jCarrousel Lite
I’m using the plugin of JCarousel Lite and it worked well on a certain page. Now I’m applying on another project msm page only that instead of working, it puts widht: 0px height: 0px; in all…
-
0
votes4
answers15127
viewsQ: Uncaught Syntaxerror: Unexpected end of input
My code is generating error and what I researched would be syntax error but I can’t find it here and Sublime Text 2 has no broker. Could you help me? Follow the code: var Padrao = { /** * Init */…
javascriptasked dsantoro 883