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

v-bind href in <a> tag doesn't work with complicated setup #9613

Closed
WangHansen opened this issue Mar 4, 2019 · 2 comments
Closed

v-bind href in <a> tag doesn't work with complicated setup #9613

WangHansen opened this issue Mar 4, 2019 · 2 comments

Comments

@WangHansen
Copy link

Version

2.6.8

Reproduction link

https://jsfiddle.net/khydf31a/

Steps to reproduce

Put the href with subject and content for <a> tag in a data and use :href instead

What is expected?

For tag to open email client with prefilled content and title, v-bind:href should return the same result as just using href

What is actually happening?

When using v-bind, content of email is ignored


Same issue with sms:?&body=something

@WangHansen
Copy link
Author

maybe because #6828

@Justineo
Copy link
Member

Justineo commented Mar 4, 2019

HTML encoding is only required if you literal values in HTML directly. You don't have to encode the value in JavaScript. Make the following changes and it should work.

- mailto:?subject=test subject&amp;body=test content
+ mailto:?subject=test subject&body=test content

@Justineo Justineo closed this as completed Mar 4, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants