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

URL field type only works with http protocol, https breaks #9397

Open
kale1d0code opened this issue Dec 17, 2021 · 2 comments
Open

URL field type only works with http protocol, https breaks #9397

kale1d0code opened this issue Dec 17, 2021 · 2 comments
Labels
Priority:Moderate Issues & PRs that are minor; broken styling, cosmetic, warnings - there are practical workarounds Type: Bug Bugs within the core SuiteCRM codebase

Comments

@kale1d0code
Copy link

Issue

When creating URLs for the URL field type and adding https:// to the front of the URL you want to save,
SuiteCRM prefixes the link with http://https:\ which is wrong

Expected Behavior

URL links are generated with https:// prefix

Actual Behavior

suitecrm generates links prefixed with http://https:\ which make no sense to web browsers

Possible Fix

remove logic that inserts http protocol or add ability to pick protocol

Steps to Reproduce

  1. create URL field
  2. add url to this field including https protocol
  3. click through link in detailview or report

Context

Your Environment

  • SuiteCRM Version used: 7.11.22
  • Browser name and version (e.g. Chrome Version 51.0.2704.63 (64-bit)):
  • Environment name and version (e.g. MySQL, PHP 7):
  • Operating System and version (e.g Ubuntu 16.04):
@tsmgeek
Copy link
Contributor

tsmgeek commented Dec 18, 2021

https://github.com/salesagility/SuiteCRM/blob/7.11.x/include/Smarty/plugins/modifier.to_url.php

Ive tested the code block that converts the string to url and it should not happen.
If you have properly prefixed your url with 'https://' then nothing should change, but if it does not see the start correctly then it prefixes it.
Can you supply url that causes the issue?

We should probably default to https for urls anyway.

@pgorod
Copy link
Contributor

pgorod commented Dec 20, 2021

We should probably default to https for urls anyway.

👍

@johnM2401 johnM2401 added the Status:Requires Updates Issues & PRs which requires input or update from the author label Dec 20, 2021
@Mac-Rae Mac-Rae added Priority:Moderate Issues & PRs that are minor; broken styling, cosmetic, warnings - there are practical workarounds Type: Bug Bugs within the core SuiteCRM codebase and removed Status:Requires Updates Issues & PRs which requires input or update from the author labels Jan 18, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Priority:Moderate Issues & PRs that are minor; broken styling, cosmetic, warnings - there are practical workarounds Type: Bug Bugs within the core SuiteCRM codebase
Projects
None yet
Development

No branches or pull requests

5 participants