I’m trying to add the Outseta login script so users can log into the app. Outseta is correctly integrated with Xano (video instructions for that here).
I copy the embed login script that Outseta gives me, but receive this error: “[domain] is a required option to initialize the Outseta script.”
weweb’s html element is very different from what you expect.
Your code is totally fine if you put it in the header. It will work only in the published app but it will behave how you would expect.
If you want to use it in the editor as well you need a workflow with a js action. First assign the global variable, then inject the script in the page.
The very minimal example is:
wwLib.getFrontWindow().o_login_options={ /* your object here */}
const document = wwLib.getFrontDocument()
const script = document.createElement('script')
script.setAttribute('data-options','o_login_options')
script.src = 'https://cdn.outseta.com/outseta.min.js'
document.head.appendChild(script)
Thanks @dorilama! The login form is now showing up in the published version, but the login flow doesn’t work. After submitting login credentials, the page reloads or there’s some redirect that ends up at a refreshed sign in screen.
Perhaps the issue is related to the Xano Authentication plugin? In that plugin’s settings, I’ve tried setting the login endpoint to both the default auth/login and the outseta/auth endpoints, neither of which work. The page just reloads and doesn’t redirect to the home page, app.complydash.com.
Note: The Post Login URL setting in Outseta is the app’s homepage.
I haven’t tried uninstalling the plugin, but if I did that I think I’d lose the ability to only allow logged-in users to see protected paged.
@Joyce I saw WeWeb’s roadmap includes an integration with Outseta that’s under review. Do you know if anyone has integrated it already? Outseta’s support team doesn’t know how to integrate with WeWeb, and I’ve hit a wall troubleshooting this.
Hey Karlso - I’m currently trying to solve this exact issue with my WeWeb project. Outseta has been great with support - but I can’t figure out a solution.
I saw your login page (super sharp btw) - how did you get Outseta to work?