added HttpResponseRedirect to views.py and assigned in to oscnRedirec…#80
Merged
jwhitlock merged 3 commits intocodefortulsa:masterfrom Jul 24, 2020
Merged
added HttpResponseRedirect to views.py and assigned in to oscnRedirec…#80jwhitlock merged 3 commits intocodefortulsa:masterfrom
jwhitlock merged 3 commits intocodefortulsa:masterfrom
Conversation
…t function, getting a different type of error, please check if I've done it correctly
jwhitlock
requested changes
Jul 23, 2020
Member
jwhitlock
left a comment
There was a problem hiding this comment.
Thanks for the PR @Serhazor.
The issue is that a full URL was needed, but a relative URL was used. The solution is not to make the relative URL work with a redirect, but to change the URL. See my suggested changes, and please revert the changes to urls.py and views.py.
website/templates/index.html
Outdated
| <div class="col-sm-6"> | ||
| <h4>2. What if I still can't find my case number?</h4> | ||
| <p>Check with your public defender or search your name online at <a href=“www.oscn.net/dockets/search.aspx”>www.oscn.net/dockets/search.aspx </a> </p> </div> <div class="col-sm-6"> | ||
| <p>Check with your public defender or search your name online at <a href="http://{{oscnRedirect}}">www.oscn.net/dockets/search.aspx </a> |
Member
There was a problem hiding this comment.
Here's how to make the URL an absolute URL:
Suggested change
| <p>Check with your public defender or search your name online at <a href="http://{{oscnRedirect}}">www.oscn.net/dockets/search.aspx </a> | |
| <p>Check with your public defender or search your name online at <a href="https://www.oscn.net/dockets/search.aspx">www.oscn.net/dockets/search.aspx</a> |
| </p> | ||
| </div> | ||
|
|
||
| <div class="col-sm-6"> |
Member
There was a problem hiding this comment.
👍 good job reformatting this section
website/urls.py
Outdated
Comment on lines
8
to
11
|
|
||
|
|
||
|
|
||
|
|
Member
There was a problem hiding this comment.
Please remove these extra lines
website/views.py
Outdated
|
|
||
| from alerts.models import Alert | ||
|
|
||
| def oscnRedirect(request): |
Member
There was a problem hiding this comment.
The changes to this file is not needed to fix the issue.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
…t function, getting a different type of error, please check if I've done it correctly