Questions tagged as 'javascript'

2
answers

ul is not defined at HTMLDocument [closed]

I'm using the code below, but getting an error function readyDom(callback) { if (/^(interactive|complete)$/i.test(document.readyState)) { callback(); } else { document.addEventListener("DOMContentLoaded", callback);...
asked by 17.12.2016 / 02:47
1
answer

Oncick table in td transform the text into an input text and when clicking off change the value

Hello, I wanted to know how I can do to change the value of a td as follows: <table class="tb"> <tr><td>Valor 1</td><td>Valor 2</td></tr> <tr><td>Valor 3</td><td>Valor 4</td&...
asked by 24.10.2015 / 11:48
1
answer

Why include html5.js file

I see that some sites include a file called html5.js, for what purpose do they include this? Something like this: <!--[if lt IE 9]><script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script> <![endif]...
asked by 21.10.2015 / 15:33
2
answers

PHP and Javascript - Show alert without refreshing the page

I have a button on my page that sends e-mail with some information filled out. However, if two of the fields are empty, the browser gives an alert warning (indicated in the code below in ALL). <?php if(isset($_POST['btnEnvia'])){ $unida...
asked by 28.10.2015 / 17:35
1
answer

How to hide blocks for a route while going to a subroutine

I'm using Ember 2 and things are complicated for those who have no Ember experience. I have the following routes consultas\ consultas\reserva And on my router.js it's like this this.route('consultas', function() { th...
asked by 28.10.2015 / 15:37
1
answer

Problem with ui-sref

I'm having trouble doing a POST using ui-sref. I need to call a controller by passing an ID where it will return me the data recorded in the database. It works fine when I use the route, but when I use ui.route I'm having a problem. With ngRo...
asked by 26.10.2015 / 18:22
1
answer

Upload JSON via AngularJS

Well, I'm trying to load a json object to display its information on the screen. The code I'm using is as follows: (function() { var app = angular.module('tela', []); app.controller('TelaController', ['$http', function($http){ var use...
asked by 16.10.2015 / 20:02
1
answer

HTML manipulation with PHP / JS

How to get content from a page with JavaScript ? With the content obtained through JavaScript (or PHP), how to manipulate it in both languages, in order to read the values, just like we do in JavaScript when we are manipulating DOM elements....
asked by 17.10.2015 / 03:22
1
answer

Is it possible to add a php code in a .js file? [duplicate]

Well my question is if you can add a code If not, how can I do it to be possible. Thank you     
asked by 27.02.2016 / 15:05
1
answer

How to disable and enable the .click () function of a span when I click on another span using on () off ()

I have two spans that work like buttons, clicking on them will appear an input to put an email and if you click again it hides those inputs. I was able to do the following: Click on span1 - > It appears input1 and disables span2, and if...
asked by 26.02.2016 / 17:18