Register for InstructureCon25 • Passes include access to all sessions, the expo hall, entertainment and networking events, meals, and extraterrestrial encounters.
Found this content helpful? Log in or sign up to leave a like!
We serve up our content to schools all around the nation. I like having buttons on the home page of each course, with a button that takes you directly to the first assignment. It's a simple way to get started.
However, when I try to add a relative link it autocorrects the link back to the full URL.
I need the button to be relative because there are 100s of schools using their own courses within our canvas instance. If it is hard coded in with the URL then it takes the user back to my blueprint course, when where I want them is in their own course.
For instance, the blue print course link might be https://sneakonthelot.instructure.com/courses/129
The user link for the same page might be https://sneakonthelot.instructure.com/courses/318
I need the button to have a link that just adds /pages/syllabus to the link. So I add the following code to the button.
<p><a class="blue-button" title="Assignment 1" href="/pages/syllabus">Let's Get Started!</a></p>
Problem is, when I save it, Canvas autocorrects the relative link to the full address:
https://sneakonthelot.instructure.com/pages/syllabus
This cuts out the course ID that the user needs and takes them to a page that doesn't exist.
So what address to I put on this button to take the user to a page within their respective courses?
Solved! Go to Solution.
Hi @DDFletch ...
I'm not sure that I'm completely following what you are asking, but I wonder if you are using the options within the RCE (Rich Content Editor) to make a hyperlink on text that just points to the Syllabus page? Would that work for your needs? Check out this Guide:
How do I create hyperlinks to course or group cont... - Instructure Community (canvaslms.com)
About half-way down the Guide that I linked to above, there is a section on "Insert Course Navigation Link", and you can see that there is an option to link to the course "Syllabus" page of the course you're in.
What are your thoughts about using that instead of what you've been trying?
Hi @DDFletch ...
I'm not sure that I'm completely following what you are asking, but I wonder if you are using the options within the RCE (Rich Content Editor) to make a hyperlink on text that just points to the Syllabus page? Would that work for your needs? Check out this Guide:
How do I create hyperlinks to course or group cont... - Instructure Community (canvaslms.com)
About half-way down the Guide that I linked to above, there is a section on "Insert Course Navigation Link", and you can see that there is an option to link to the course "Syllabus" page of the course you're in.
What are your thoughts about using that instead of what you've been trying?
I tried this before, but what that does is add a direct link to the actual URL of that page. Normally that would work fine. My problem is that I have 50 different schools, all using separate courses of my blueprint course. So when I make a link in the blueprint course with a full URL, all 50 schools now have buttons that link back to my blueprint course, not their page in their course. I need a relative link that takes them to the same page within their own individual course.
Okay, I see what it's doing now. You're right, that way of linking does work. it's all the data-api stuff that is added to the link that makes is relative to users in other courses.
Thank you!!!!
@DDFletch ...
I am glad that you were able to figure that out. Yes, the link that it creates is not specific to your blueprint course. It would update accordingly based on when the content is copied out to every other course. Thanks for providing the update!
The reason it wasn't correcting was that the teacher had edited that page and my blueprint sync wasn't able to correct it.
To interact with Panda Bot in the Instructure Community, you need to sign up or log in:
Sign In