# Quoting strings with single quotes JS

**URL:** <https://forum.freecodecamp.org/t/quoting-strings-with-single-quotes-js/501250>\
**Category:** Curriculum Help\
**Tags:** javascript\
**Created:** [March 17, 2022, 11:09pm UTC](https://forum.freecodecamp.org/t/quoting-strings-with-single-quotes-js/501250 "2022-03-17T23:09:38Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![JNguyening](https://avatars.discourse-cdn.com/v4/letter/j/e8c25b/32.png) [@JNguyening](https://forum.freecodecamp.org/u/JNguyening)\
**Post date:** [March 17, 2022, 11:09pm UTC](https://forum.freecodecamp.org/t/quoting-strings-with-single-quotes-js/501250/1 "2022-03-17T23:09:38Z")

</div>

Challenge is basic javascript - javascript algorithms and data structures

This is the challenge example

```auto
const myStr = "<a href=\"http://www.example.com\" target=\"_blank\">Link</a>";

```

challenge states to remove the backslashes and code should have 2 single quotes and 4 double quotes. which i did in the example below.

```auto
var myStr = '<a href="http://www.example.com" target="_blank">Link</a>';

```

when i click run test. nothing happens. according to comments on this particular lesson, its correction solution. is there something wrong with the setup?

thank you for the replies.

---

<div class="post-metadata">

**Author:** ![Smeagol](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/smeagol/32/247350_2.png) [@Smeagol](https://forum.freecodecamp.org/u/Smeagol)\
**Post date:** [March 17, 2022, 11:17pm UTC](https://forum.freecodecamp.org/t/quoting-strings-with-single-quotes-js/501250/3 "2022-03-17T23:17:36Z")

</div>

Hi @JNguyening,

Welcome to freeCodeCamp and JS! It seems that you are using a different symbol than its looking for, you are using `‘`, but it expects `'`. A slight difference in characters can cause issues in code unfortunately.

Hope this helps!

---

<div class="post-metadata">

**Author:** ![DanCouper](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/dancouper/32/158608_2.png) [@DanCouper](https://forum.freecodecamp.org/u/DanCouper)\
**Post date:** [March 17, 2022, 11:46pm UTC](https://forum.freecodecamp.org/t/quoting-strings-with-single-quotes-js/501250/4 "2022-03-17T23:46:16Z")

</div>

Which challenge is it?

Also, this is particularly important here: when you enter a code block into a forum post, please precede it with a separate line of three backticks and follow it with a separate line of three backticks to make it easier to read.

As well as making it difficult to rea, of you don’t do this, a. quotation marks will be formatted as actual quotation marks in the post and b. if you type anything that looks like HTML, the forum will try to render that HTML .

You can also use the “preformatted text” tool in the editor (`</>`) to add backticks around text.

 ![Pre-formatted-text](https://global.discourse-cdn.com/freecodecamp/original/3X/1/b/1b18854f1059217f29370444396145cc3a0cd8ae.gif)

See [this post](https://forum.freecodecamp.org/t/forum-code-formatting/25574) to find the backtick on your keyboard.  
**Note:** Backticks (`) are not single quotes (’).

---

<div class="post-metadata">

**Author:** ![JNguyening](https://avatars.discourse-cdn.com/v4/letter/j/e8c25b/32.png) [@JNguyening](https://forum.freecodecamp.org/u/JNguyening)\
**Post date:** [March 18, 2022, 12:30am UTC](https://forum.freecodecamp.org/t/quoting-strings-with-single-quotes-js/501250/5 "2022-03-18T00:30:56Z")

</div>

thank for the warm welcome. im grateful to be a part of this community. i’ve learned so much since i’ve joined! yes it does look like it but i am using ( ’ ).

---

<div class="post-metadata">

**Author:** ![JNguyening](https://avatars.discourse-cdn.com/v4/letter/j/e8c25b/32.png) [@JNguyening](https://forum.freecodecamp.org/u/JNguyening)\
**Post date:** [March 18, 2022, 12:32am UTC](https://forum.freecodecamp.org/t/quoting-strings-with-single-quotes-js/501250/6 "2022-03-18T00:32:35Z")

</div>

ths is the challenge link.

> **[freeCodeCamp.org](https://www.freecodecamp.org/learn/javascript-algorithms-and-data-structures/basic-javascript/quoting-strings-with-single-quotes)**
>
> Learn to Code — For Free

---

<div class="post-metadata">

**Author:** ![JNguyening](https://avatars.discourse-cdn.com/v4/letter/j/e8c25b/32.png) [@JNguyening](https://forum.freecodecamp.org/u/JNguyening)\
**Post date:** [March 18, 2022, 12:44am UTC](https://forum.freecodecamp.org/t/quoting-strings-with-single-quotes-js/501250/7 "2022-03-18T00:44:18Z")

</div>

I am so sorry! I had a filter active that prevented popups. That’s why I couldn’t get anything to work! I’m sincerely sorry I wasted your time.

---

<div class="post-metadata">

**Author:** ![JNguyening](https://avatars.discourse-cdn.com/v4/letter/j/e8c25b/32.png) [@JNguyening](https://forum.freecodecamp.org/u/JNguyening)\
**Post date:** [March 18, 2022, 12:44am UTC](https://forum.freecodecamp.org/t/quoting-strings-with-single-quotes-js/501250/8 "2022-03-18T00:44:51Z")

</div>

I am so sorry! I had a filter active that prevented popups. That’s why I couldn’t get anything to work! I’m sincerely sorry I wasted your time!

---

<div class="post-metadata">

**Author:** ![DanCouper](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/dancouper/32/158608_2.png) [@DanCouper](https://forum.freecodecamp.org/u/DanCouper)\
**Post date:** [March 18, 2022, 12:51am UTC](https://forum.freecodecamp.org/t/quoting-strings-with-single-quotes-js/501250/9 "2022-03-18T00:51:40Z")

</div>

At least it’s an easy fix, and it wasn’t your code that was the issue! 🙂

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/freecodecamp/original/3X/e/1/e1c433102e34b46dfaa3e15d13ab9a514b127078.svg) [@system](https://forum.freecodecamp.org/u/system)\
**Post date:** [September 16, 2022, 12:52pm UTC](https://forum.freecodecamp.org/t/quoting-strings-with-single-quotes-js/501250/10 "2022-09-16T12:52:10Z")

</div>

Closed on September 16, 2022, 12:52pm UTC

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.
