Jump to content

Recommended Posts

Posted

I'm having problems with retrieving attributes for Variants. 

This hook seems to not triggering for me: 

$this->addHook("/find-padloper_product_attributes/", $this, 'hookFindPadloperProductAttributesOptions');

When trying to find attributes it returns a 404.

I'm using multilingual fields. 

 

  • Like 1
Posted (edited)

Hi @Spinbox,

Please confirm if your ProcessWire is running off a sub-directory.

I have tested on a ML site where Dutch is the main language and English the 'other' language and the hook works fine. What language are you searching in?  Maybe it doesn't matter but just want to be sure.

Thanks.

Edited by kongondo
Posted

Hi @kongondo, no I am not running of a sub-directory.

I haven't changed anything, so I assume it uses the default language (in my case Dutch).

I'm not sure it has anything to do with language. Isn't it just looking for the default language values?

Posted

Hi @Spinbox,

Thanks for the login details. You have a 5 errors that are showing during the Ajax call. These are coming from your templates and func files. I think they are interfering with the response. I'll fix this on your site and test again.

Posted

Nothing wrong with ready.php

I think this is what is happening: Padloper is using virtual URL hooks. It means it needs to handle the 404s in the backend for the requested URL. On your site, something is preventing this from happening meaning ProcessWire returns 404s for those virtual URLs. I don't know what that 'thing' is on your site ...yet?.

  • Like 1
Posted

Thank you @kongondo,

You got me on the right path and I have found the issue. My homepage template has url segments enabled. Once I disable this, the url works.

Not sure if this contributes to the problem but I use TemplateEngineFactory.

To keep url segments I used a regex to allow anything but paths that start with find-padloper in the template settings.

regex:^(?!find-padloper).*$

 

  • Like 1
  • 1 month later...
Posted

Hey @kongondo and @Spinbox. Did you get the add to cart feature etc working with URL segments on on the homepage? I too have an instance, where the homepage has URL segments enabled and when enabled the padloper/add/ segments aren't processed correctly. When disabled, of course addToCart and the url segments are handled correctly.

The thing is, I'd ideally like URL segments enabled as they convert LoginRegister's get url params to url segments.

Posted

I've worked around this by running LoginRegister's processes on another template, so all good for me now ??

  • Like 2

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
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...