# Wikipedia search--yet another CORS problem

**URL:** <https://forum.freecodecamp.org/t/wikipedia-search-yet-another-cors-problem/167059>\
**Category:** General\
**Created:** [January 5, 2018, 11:50pm UTC](https://forum.freecodecamp.org/t/wikipedia-search-yet-another-cors-problem/167059 "2018-01-05T23:50:01Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![bdfoz](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/bdfoz/32/74246_2.png) [@bdfoz](https://forum.freecodecamp.org/u/bdfoz)\
**Post date:** [January 5, 2018, 11:50pm UTC](https://forum.freecodecamp.org/t/wikipedia-search-yet-another-cors-problem/167059/1 "2018-01-05T23:50:01Z")

</div>

```auto
if(e.which == 13) {
        var search_text = ($("#search_box").val());
        $.ajax({
          url: "https://en.wikipedia.org/w/api.php",
          type: "GET",
          data: {action: "opensearch",search:search_text, format:"jsonp"},
          success: function(data){
            console.log(JSON.stringify(data));
          }
        });

```

Getting the typical “No ‘Access-Control-Allow-Origin’ header is present on the requested resource.” error. Any suggestions on resolving it? Have read and searched a lot. Now i’m asking.

I whole-heartedly believe this should be a topic addressed more closely in the FCC curriculum. This single error has been the biggest difficulty in all of my intermediate projects so far.

---

<div class="post-metadata">

**Author:** ![bdfoz](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/bdfoz/32/74246_2.png) [@bdfoz](https://forum.freecodecamp.org/u/bdfoz)\
**Post date:** [January 6, 2018, 1:03am UTC](https://forum.freecodecamp.org/t/wikipedia-search-yet-another-cors-problem/167059/2 "2018-01-06T01:03:07Z")

</div>

If you come across this question:

Answer here: [Access-Control-Allow-Origin Error](https://forum.freecodecamp.org/t/access-control-allow-origin-error/53605)

Answer here: [https://www.mediawiki.org/wiki/Manual:CORS](https://www.mediawiki.org/wiki/Manual:CORS)

---

<div class="post-metadata">

**Author:** ![ILM](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/ilm/32/363239_2.png) [@ILM](https://forum.freecodecamp.org/u/ILM)\
**Post date:** [January 17, 2021, 8:31pm UTC](https://forum.freecodecamp.org/t/wikipedia-search-yet-another-cors-problem/167059/3 "2021-01-17T20:31:28Z")

</div>

Closed on January 17, 2021, 8:31pm UTC


