Questions tagged as 'javascript'

1
answer

How to invert mouse click events?

I was struck by a recent question, where the% s of the left mouse button could in a specific case turn out to be right , and vice versa. p> Code var menulist = document.oncontextmenu; var menu = function(ev) { if (ev.button == 0 || e...
asked by 03.04.2017 / 11:56
1
answer

What alternative mode could be used to block the click effect on an HTML element?

Based on an example put by Sergio - How prevent a click on a link / anchor or element with event tied Example of my authorship var ancora = document.getElementsByClassName('baixar'); for (var i in ancora) { document.captureE...
asked by 02.04.2017 / 21:44
1
answer

When selecting a value from a select, a div appears

Colleagues. I'm trying to get the user to select a value from the select, a corresponding div appears to the value that was selected. Eg: The values of select are:    3, 4, 5, 6, 7, 8 and 12 If the user selects the value 5, a div will...
asked by 20.01.2017 / 20:41
2
answers

How to display item that was added to the shopping cart with javascript?

Hello everyone, here is a way to modify a following script: when I run the code below, I have a system where I click on the + on the right side, which adds up the value below, everything works fine ... I would like to know if it would be possibl...
asked by 21.01.2017 / 03:13
1
answer

Display datepicker according to selection

Good afternoon, I'm breaking my head to display the date as per the user's selection. Example: select 01 - the "From / To" select 02 - Only "To" select 03 - Only "From" select 04 - No dates appear I've created an array, with the dataInitia...
asked by 09.01.2017 / 15:35
1
answer

jQuery Mobile does not allow internal links

I'm creating HTML 5 application sketch to run on mobile device. In my project, I needed to use different versions of jQuery for the events to work: <script src="js/jquery-1.11.3.min.js"></script> <script src="js/jquery.mo...
asked by 11.01.2017 / 16:48
1
answer

call action method in the controller through a view script

I have an action inside my controller, to download an XML file, with the following signature.   public ActionResult Export (int id) {}, I do not understand in my page I have a button that calls a download script in the view, I need this scrip...
asked by 11.01.2017 / 13:49
1
answer

Search text function

What is the correct way to search for text on the page? I'm developing a "single" page in HTML and would like a search field when typing find text, similar to what happens today with CTRL+F , I'd like to manipulate the field foun...
asked by 10.01.2017 / 13:56
1
answer

Validation via Javascript does not work

Person, beauty? So, I have an alert div (that of the bootstrap) with the display none and visibility hidden I'm catching it by id, both in css and javascript, but it does not work. It changes the properties of the CSS but still sends the data to...
asked by 07.01.2017 / 01:38
1
answer

How to use the contents of a javascript variable in another js file?

I'm creating my first application with nodejs and I have a question in javascript. In the code below I'm reading a sensor and saving in the variable value every 30 seconds, I wonder if I can use this variable and its value in another js file?...
asked by 06.01.2017 / 19:17