Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fetching a page that contains form based search results #16

Open
MaximKovrigovichROI opened this issue Apr 6, 2020 · 0 comments
Open

Comments

@MaximKovrigovichROI
Copy link

Hello
my page contains a list of search results taken from submitted form data provided by
https://contao.org/en/extension-list/view/efg.20020019.en.html
at the web site all pages work fine,

we need to consume the page and all linked filtered search results by api so I tried approaches like
/api/page?url=/alias.html
/api?url=/alias.html
/api/module?id=21
all lead to an error
`Call to a member function row() on null

Symfony\Component\Debug\Exception
FatalThrowableError
in system/modules/efg/modules/ModuleFormdataListing.php (line 1155)
$objData = $objDataStmt->execute($varKeyword);
/** * Prepare URL */
$strUrl = $this->generateFrontendUrl($objPage->row());
if ($strUrl == '/' || $strUrl == '//') {
$strUrl = '';
}
the key place here is that there is aglobal $objPage;` expected to be populated somehow, I assume by the bundle probably

P.S. I also checked a few normal pages (contain a set of image/text sections) and no issues found, api works as expected

is it possible somehow get the search results by api?
thank you!

used version: dev-master

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant