0

I have a link which has navigateToBusiness("check & ' ""). Due to this double quote, script is not getting called. The value passed check & ' " is dynamic.

Please help. Thanks in advance.

2 Answers 2

1

You can escape special characters with a leading \

navigateToBusiness("check & \' \"")
Sign up to request clarification or add additional context in comments.

1 Comment

Thank for your response Andy. As the passed value is dynamic (from java), I tried name.replace("\"","\\\"").replace("'", "\'"). But still it generated as check & ' ". Do you have any idea? if so, please help.
0

You may need to escape the quote,

Read more here: Escape quotes in JavaScript

Hopefuly this helps

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.