psy Posted August 5, 2016 Share Posted August 5, 2016 Wasn't sure where to post this so chose this forum as not sure whether it's unique to my scenario, a bug, something I've done wrong or a suggestion for a PW change. Scenario is: - TLD has a website built with another CMS with it's own .htaccess - ProcessWire section is in a sub directory - 99% of everything works fine except for Lost Password module - using FrontEnd user module and had similar problems with the Login form but managed to resolve by changing the form action to the current page url in the page template What happens: - using FE User module, when I click the Lost Password button and enter a valid username, the form returns FALSE and just re-displays the Lost Password form - using FE User module, when I enter an invalid username (eg user email), the page displays the message that an email will be sent - no email is ever received as the username does not exist in Users - took a step back and just used the Lost Password in the normal PW admin - entered valid username and message was displayed but no email ever received - sometimes (didn't catch the exact scenario), the page redirected to the TLD/other CMS home page What I've noticed is that in the code for LostPassword module (and others), instead of the form action returning to the current page it's hard coded as ('./?forgot') or in other FieldtypeForm modules just ('./') That's OK if PW is installed in the root dir and the home page has the code necessary to handle the responses. Changing $config->urls->root or PW .htaccess doesn't have any effect (maybe because root .htaccess governs other CMS?) Anyhoo, my question is: Would it not be better instead of hardcoding the form action as './' to use $config->urls->root , $pages->get(1)->url or even $page->url? Using: PW 3.0+ Link to comment Share on other sites More sharing options...
LostKobrakai Posted August 5, 2016 Share Posted August 5, 2016 "./" is the current page. "/" would the the root page. 1 Link to comment Share on other sites More sharing options...
psy Posted August 6, 2016 Author Share Posted August 6, 2016 Thanks for the clarifying Link to comment Share on other sites More sharing options...
Recommended Posts