Jump to content

Ajax call to core Controller Prestashop 1.6


techhead

Recommended Posts

Hi,

 

I'm just wondering if someone can let me know the correct way to call a core controller using Ajax in Prestashop 1.6.

 

I tried the following:

 

var query = $.ajax({
type: 'POST',
url: baseDir + 'override/controllers/front/StoresController',
data: 'method=getStates&country='+country,
dataType: 'json',
success: function(json){
console.log('Success');
}
})

 

I get a 403 error when that code runs.

 

Any help is appreciated. Thanks. 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...