Questions tagged [jquery]

Denotes questions related to the use of jQuery library in Magento.

Filter by
Sorted by
Tagged with
1
vote
1answer
1k views

Use slide animation for opening tabs or accordions

I'm trying to update the product tabs/accordions to animate when I select them. I've removed the tab styling and adjusted them so they are accordions that open up and down on the page. I'd like to ...
1
vote
1answer
3k views

JQuery how to remove tr in table which are display none in CSS [closed]

how to remove tr in a table which is display:none in CSS
1
vote
1answer
1k views

How to remove jQuery conflict in magento 2

I am getting a conflict of jQuery and due to this some feature of Magento 2 not working . How can I resolve this issue ?
1
vote
1answer
2k views

jQuery UI breaks when clicking on draggable element: “Cannot read property 'defaultView' of undefined”

I'm using Ultimo theme and created a child theme. I created a custom module that uses jQuery UI draggable. When the page loads it's all fine but when I click on an element that should be able to be ...
1
vote
1answer
2k views

magento 2 : Load latest version jquery in custom module

I want to load the latest version (v3.2.1) jquery in my Magento 2 custom module. Actually, I want to use materializes in luma theme but for that jquery version must be 3.2.1. I tried to replace the ...
1
vote
1answer
316 views

magento2 : so many jquery & require.js error when activating ssl

Magento2: so many jquery & require.js error when activating SSL. On Backend & Frontend Both. Is there any common problem? Error screenshot: Front End Error screenshot: BackEnd
1
vote
1answer
6k views

Magento 2 properly update core jquery lib

I keep seeing this warning in my console (firefox dev-console) JQMIGRATE: jQuery.browser is deprecated jquery-migrate.js:41:4 console.trace(): jquery-migrate.js:43 migrateWarn ---.com/static/...
1
vote
1answer
152 views

What stopObserving() function is used for - Magento 1.9

I want to know what the js function stopObserving() is used for.
1
vote
2answers
2k views

Validation callback in magento2

var dataForm = jQuery('#form'); dataForm.mage('validation'); function submitForm(){ if (dataForm.valid()){ dataForm.submit(); } } Everything is working well what i ...
1
vote
2answers
605 views

jquery min file not loading in the homepage in Magento 1.9 installation

Until yesterday this website has been working properly. Strangely now when this url http://solankitextileagency.com is loaded, I'm getting this error A script on this page may be busy, or it may ...
1
vote
1answer
3k views

how to add custom validation to product options field?

I'm trying to add custom validation to the product option, I'm following the tutorial and here it says to add custom validation element to the attribute data-validate like data-validate="{required:...
1
vote
2answers
5k views

Remove Conflict between JQuery and Prototype.js in magento 1.9.1

I have included all the js library in page.xml of my magento. <action method="addJs"><script>lib/jquery/jquery-1.10.2.min.js</script></action> <action method="...
1
vote
1answer
309 views

How to use Chosen in magento

I need to use Chosen in magento instead of "select " for multi select.I didn't find any thing about it. How should I add jquery for it. I am trying to solve Following issue
1
vote
1answer
595 views

Magento form validation

When using jquery .change on an input the event will only be fired when the input loses focus In my case, I need to make a call to the service (check if value is valid or empty) as soon as the input ...
1
vote
1answer
3k views

Magento2 $ is not a function when using flexslider

I just migrated from Magento 1.x to Magento 2. I setup Magento successfully, understood and used RequireJS as well. I was adding flexslider on my home page and got the error: $ is not a function ...
1
vote
1answer
684 views

Remove jQuery from Checkout pages

I want to remove jQuery from my checkout pages we arent using it there and the checkout button doesn't work because of conflict. Shouldn't it be something in local.xml like this? <...
1
vote
1answer
578 views

Magento JS Framework

Does Magento use any JS frame work such as Node.JS? if not is it possible for us to include? We would like to know bottom of this before we proceed on Magento. I did few research about it but couldn't ...
1
vote
1answer
1k views

Loading jQuery in Magento [duplicate]

I'm trying to implement an owl-carousel in my Magento webshop. I've loaded the .js file and the stylesheet. Jquery is (I believe) loaded from the template. When I use to code to activate the carousel ...
1
vote
1answer
189 views

how to use post method to contoller and phtml for button event in magento 2

I have a button in phtml file some.phtml <button class="example-button-1 example-button-3 :active" type="button" id="acceptnow" ><span>Active</span></button> I want to ...
1
vote
1answer
203 views

How to remove default contact form validation in Magento2.2.5?

I want to remove default contact form validation and add my jquery validation in contact form in Magrnto2.2.5? Any help would be appreciated.
1
vote
1answer
157 views

Use of non-amd jquery plugins with requirejs without modifying them?

I recently searched a lot on use of non-amd jquery code with requirejs but couldn't find a proper way to do it. To be more specific, I want to use pana-accordion.js found at below mentioned url. ...
1
vote
2answers
130 views

Inline call of jQuery tabs doesn't work

Here's my problem. I have a tabs block which load perfectly when I put this script in phtml require([ 'jquery', 'jquery/ui' ], function($) { $("...
1
vote
1answer
272 views

RequireJs and Custom JS file blur

this is my simple requirejs-config.js file var config = { deps: ['js/custom'] }; and this is my custom.js file define([ "jquery", "domReady!" ], function($) { "use ...
1
vote
2answers
185 views

Add js to Widget

Hello looking for some help I have created some Widget , and need to add in it JavaScript for fetch instagram photos I have a library and a script, but this script doesnt work. I have added it in ...
1
vote
1answer
612 views

Magento 2 - Is there a way to change element “data-mage-init” without overriding a template?

For example I want to change some options of minicart dialog initialization. So I need to change minicart template (override this template in custom theme/module). Is there a way to change minicart ...
1
vote
1answer
2k views

How to get simple product id using custom js in Magento2?

If I have a configurable product and I select color red, then how can I get the alert- id of that virtual product that has been selected? I would need to do this each time when a new color is ...
1
vote
1answer
1k views

Magento2 : how to use phtml jquery functions and vars from another phtml jquery script

I have created a new page containing several blocks : Simplified Block 1 phtml : <form id="form" class="form " name="form"> <div class="inputselect"> <select class="...
1
vote
1answer
12k views

Popup modal: To display Success message in popup model in magento 2

I have created form in popup modal and it works successfully. After submitted a form it shows an alert. But I need success message instead of alert, in Popup itself after submitted a form. Please ...
1
vote
1answer
1k views

How to add a JQuery library in Magento 1.9

I was needing to add a Jquery library in magento 1.9, to use on one of my phtml pages, to insert masks in my fields, like cpf, cnpj and etc ... I have done a lot of research and I have noticed that ...
1
vote
2answers
3k views

Magento 2 : Add to cart button change to go to cart after adding product

How to do the following - Clicking on "Add to Cart" button adds the product to cart then Button Changes to "Go to Cart" and clicking on that redirect to Shopping Cart Please help me in doing this ...
1
vote
2answers
770 views

Customer “Sign In” button not working anymore

I have run into a problem where the Customer "Sign In" button stopped working after a few uses. Everything else so far about the store seems to be working as expected. I am using a clean install of ...
1
vote
1answer
2k views

Adding to cart breaks fotorama on page reload

Fotorama works normally until I click add to basket. After the page reloads this then shows collapsed (as per the image) and logs a couple of errors to console. fotorama.js:99 Uncaught Fotorama ...
1
vote
1answer
444 views

Magento 2 Custom Js does not work

I have add a custom.js file under my_child theme folder web/js/custom.js here is code define([ "jquery" ], function($) { "use strict"; $('#shipping').find('.step-title').click(...
1
vote
2answers
1k views

How to add number of input fields on change another input field value?

I have 3 rows and 3 columns in the table. Quantity field is input field. I want to add new input fields in another column when anyone changes input field value. Now, I am using below code: <td ...
1
vote
2answers
2k views

Magento 2 tabs - change programmatically

I'm wondering how to exactly change tab (core mage/tabs widget) programmatically. Docs say that I can use both activate and enable functions for that: http://devdocs.magento.com/guides/v2.0/javascript-...
1
vote
1answer
125 views

Handling Exception - jQuery

I have some buttons that onclick on them work with two Ajax requests that add and remove products, but this is not of extreme importance in this matter. My problem is this: if the buy button is ...
1
vote
1answer
436 views

Display an array of Jquery data in HTML

I make a request in ajax at the click of the button passing as parameter the id of a certain product to the controller. This controller directs the product id to a helper that adds the same to the ...
1
vote
1answer
65 views

Manipulating variables in jQuery to be displayed in html code

I make a request in Ajax at the click of the button passing the id of a product to a controller and it passes to the helper. In the helper, through this id of the product, I add it to the cart, but ...
1
vote
1answer
338 views

Google Map with Drop down functionality not working

I Make a file of Google Map in which there are a drop-down functionality but first i created this file in html it's working perfectly but when i tried in CMS page or phtml page the map not shown. As ...
1
vote
3answers
249 views

inserting an image in owl slider in magento [closed]

I want to insert an image in following code jQuery(document).ready(function() { jQuery("#owl-test-feature").owlCarousel({ navigation : true, slideSpeed : 400, paginationSpeed : 400, items : 5, ...
1
vote
2answers
967 views

External js for magento 2 backend not loaded

I create the external js for magento 2 backend like this: Namespace/Module/view/adminhtml/requirejs-config.js: var config = { map: { '*': { regionsForm: 'Namespace_Module/js/...
1
vote
1answer
5k views

Function in not defined in custom jquery when using href=javascript

I am trying to setup slider. When i connect jquery library just as <script src="></script> and connect slider code just as <script></script> with no require([ 'jquery', '...
1
vote
1answer
689 views

Magento 2 - how to use jquery for attribute input fields which has special characters

I have three product attributes named gross_weight,stone_weight & net_weight. While entering stone_weight the net_weight should be calculated using jquery. But jquery is not recognizing input ...
1
vote
1answer
54 views

Change link jquery from local to web

This is link jquery in my local ../pub/static/frontend/../../en_US/jquery/jquery.min.js and I want change to https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js Anyone help me?
1
vote
1answer
529 views

Magento 2: colorbox jquery not working

I am working on magento 2 and i want to open popup in my product detail page. But i have found problem with jquery issue and its not come every time. Here is my requirejs-config.js var config = { ...
1
vote
1answer
830 views

requirejs load js but not work - magento 2

app/code/Vendor/Module/view/frontend/requirejs-config.js var config = { map: { '*': { 'gworks/jquery':'Vendor_Module/js/jquery.min' }, } }; In ...
1
vote
1answer
545 views

Ajax request from checkout page js file to controller

I want to make Ajax request to the controller from checkout page. The code I have in github and in my previous post were I did not specify that I want to make the ajax request from js file placed on ...
1
vote
1answer
348 views

Trying to make layered navigation accordion style (with divs)

Trying to make this work but seems not having any effect... What am I doing wrong? With help from @Shyam I got the following working solution: <div id="narrow-by-list"> <?php $_filters =...
1
vote
1answer
77 views

Error after removing jQuery elevate [duplicate]

I removed the jQuery elevate script from my site using this in the local.xml: <catalog_product_view translate="label"> <reference name="head"> <action method="removeItem"&...
1
vote
2answers
625 views

How to stop Javascript alert box from popping up on each page load?

I've been trying to create a popup for the Currency Selector on Magento. With some help I finally got this to working but it pops up on each page load. Maybe someone knowledgeable in javascript can ...

1
3 4
5
6 7
15