Questions tagged as 'javascript'

1
answer

Invert value of y on canvas

I wonder if there is a way to invert the y-axis of canvas so that the point (0,0) is actually the point (0.500) .... That is, if I play the value 20 in the Y, instead of starting from the top down, start from the bottom up ..... func...
asked by 01.06.2015 / 18:55
3
answers

Assign CSS value to HTML via JavaScript

I created this FIDDLE to see if what I was doing was right or wrong. Apparently it's wrong: My goal here is to JavaScript assign CSS values to an HTML element, in this case the value top . Based on the response from this pr...
asked by 01.06.2015 / 16:37
1
answer

Problems with Drag and Drop in pure JavaScript

I'm having problems with my Drag and Drop function in JavaScript, the operation of drag and drop is perfect, but when I change some images, they do the wrong exchange. For example: I have the images x, y and z, and when I change z and y, the exc...
asked by 30.05.2015 / 20:35
1
answer

Disable a button in ASP.NET MVC

I'm developing an application that manages course enrollments, I'm still apprentice in ASP.NET MVC, and I have the following question: In my course screen there is an "enroll" button for the courses listed on this screen. I would like to know...
asked by 02.06.2015 / 20:26
2
answers

Popular DropDownList with JSON

- Controller - [WebMethod] public ActionResult GetSellers() { List<Seller> sellers = db.Sellers.ToList(); return Json(sellers, JsonRequestBehavior.AllowGet); } - View - @Html.DropDownList("SellerId", null, "-- Select --...
asked by 31.05.2015 / 17:38
2
answers

Validating two date fields

I need to verify that the user has entered the date in two date fields. <input type="text" name="data1"/> <input type="text" name="data2"/> How to solve this? If I put required in the field, it only works in chrome. But what abo...
asked by 06.05.2015 / 20:48
1
answer

Error with angularJS with $ http.get

I'm trying to get some data via WS (Web Service), but when I ask to return in my app it gives this error:    In 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'null' is therefore not allowed access. But...
asked by 05.05.2015 / 20:06
3
answers

if / else condition to mark / uncheck checkbox

I would like to know what a condition to uncheck all my ckeckbox . function marcarDesmarcarTodos() { for (i = 0; i <= 500; i++) { document.getElementById('seleciona_ativarDesativar_'+i).checked = true; } } I tried i...
asked by 08.05.2015 / 16:02
1
answer

Add inputs according to the value of a field

I would like to know how to create input fields according to the value I add in a field. Ex: I have a field of type number that has a minimum value of 1 the maximum value of 4 and the default value is 1: <input type="number" min="1" max=...
asked by 19.04.2015 / 16:05
1
answer

Validation in several input file with JS

I have a JS code for validation of form attachments and I'm trying to call the function once for all fields with the same class="" The problem is that it only works with the first view the same field in the others views does not go throug...
asked by 20.04.2015 / 16:13