Hosting LTI provider on different domain
See original GitHub issueI’m attempting to get a development version of a basic LTI instance working with a live production Moodle instance. I’m hosting the tool locally and am attempting to update the grade book of the Moodle instance but am running into a CORS issue where I’m being blocked by the Moodle instance for making a cross-site request.
I have the LTI connecting and loading an HTML page with a button that fires off this function:
function SendGrade () {
const Http = new XMLHttpRequest();
const url='https://www.myMoodleURL/grade?ltik=' + ltik;
Http.open("POST", url);
Http.send();
}
This request is getting denied for being cross-site since it’s originating from my localhost.
I’m hoping there is a way around this that I’m just missing.
Any help of how I can make my requests into my Moodle instance from a separately hosted domain would be much appreciated.
Issue Analytics
- State:
- Created 3 years ago
- Reactions:1
- Comments:23 (11 by maintainers)
Top Results From Across the Web
Learning Tools Interoperability (LTI) - Blackboard Help
On the Administrator Panel, under Integrations, select LTI Tool Providers. · Select Register LTI 1.1 Provider. · Type the Provider Domain, such as...
Read more >Basic Overview of How LTI works - 1EdTech
The basic workflow for using LTI starts when the Instructor or LMS administrator gains access to an externally-hosted learning tool.
Read more >Publish as LTI tool - MoodleDocs
The 'Publish as LTI tool' enrolment plugin, together with the LTI authentication plugin, allows remote users on a different site (known as an ......
Read more >Configuring Canvas to support multiple domains
Add multiple domains to Approved Domains · Login to LTI Pro application · Click Manage, then click Configure. · Click Edit Credentials used...
Read more >Getting Started With LTI - Anthology Dev Docs
That application is defined by its fully-qualified domain name (FQDN). An application can have many FQDNs, but two applications cannot share the same...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Thanks @Cvmcosta
Earlier today I figured out that there was some caching in the db so we have been dropping the db between tests to ensure we were getting a fresh session/cookie set.
I’m beginning to think it’s an issue with the version of Moodle or permissions that are different in production.
If you have some time I think a hangout would be helpful. Can you email me at mike at sdcs.io and we can plan a time to jump on a screen share.
Thank you for the super fast response. I’ll give it a shot right now.