Skip to content

Commit e4b8289

Browse files
author
dksimpson
committed
Fix code block tags
1 parent a10ac62 commit e4b8289

File tree

7 files changed

+24
-24
lines changed

7 files changed

+24
-24
lines changed

articles/cognitive-services/Bing-News-Search/csharp.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ manager: nitinme
88
ms.service: cognitive-services
99
ms.subservice: bing-news-search
1010
ms.topic: quickstart
11-
ms.date: 05/19/2020
11+
ms.date: 05/22/2020
1212
ms.author: aahi
1313
ms.custom: seodec2018
1414
---
@@ -25,7 +25,7 @@ The full code to this sample can be found on [GitHub](https://github.com/Azure-S
2525

2626
* Any edition of [Visual Studio 2017 or later](https://www.visualstudio.com/downloads/).
2727
* The [Json.NET](https://www.newtonsoft.com/json) framework, available as a NuGet package.
28-
* If you're using Linux/MacOS, this application can be run using [Mono](https://www.mono-project.com/).
28+
* If you're using Linux/MacOS, you can run this application by using [Mono](https://www.mono-project.com/).
2929

3030
[!INCLUDE [cognitive-services-bing-news-search-signup-requirements](../../../includes/cognitive-services-bing-news-search-signup-requirements.md)]
3131

@@ -51,7 +51,7 @@ The full code to this sample can be found on [GitHub](https://github.com/Azure-S
5151

5252
## Create a struct to format the Bing News Search response
5353

54-
Define a `SearchResult` struct to contain the image search results and JSON header information.
54+
Define a `SearchResult` struct to contain the news search results and JSON header information.
5555

5656
```csharp
5757
struct SearchResult
@@ -63,7 +63,7 @@ struct SearchResult
6363

6464
## Create and handle a news search request
6565

66-
1. Create a method named `BingNewsSearch()` to perform the call to the API, and set the return type to the `SearchResult` struct created previously.
66+
1. Create a method named `BingNewsSearch()` to call the API, and set the return type to the `SearchResult` struct created previously.
6767

6868
Add code to this method in the steps that follow.
6969

@@ -108,12 +108,12 @@ struct SearchResult
108108

109109
In the main method, call `BingNewsSearch()` and store the returned response. Then, deserialize the JSON into an object where you can view the values of the response.
110110

111-
```csharp
112-
SearchResult result = BingNewsSearch(searchTerm);
113-
//deserialize the JSON response
114-
dynamic jsonObj = Newtonsoft.Json.JsonConvert.DeserializeObject(result.jsonResult);
115-
Console.WriteLine(jsonObj["value"][0])
116-
```
111+
```csharp
112+
SearchResult result = BingNewsSearch(searchTerm);
113+
//deserialize the JSON response
114+
dynamic jsonObj = Newtonsoft.Json.JsonConvert.DeserializeObject(result.jsonResult);
115+
Console.WriteLine(jsonObj["value"][0])
116+
```
117117

118118
## Example JSON response
119119

articles/cognitive-services/Bing-News-Search/go.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ manager: nitinme
99
ms.service: cognitive-services
1010
ms.subservice: bing-visual-search
1111
ms.topic: quickstart
12-
ms.date: 05/19/2020
12+
ms.date: 05/22/2020
1313
ms.author: aahi
1414
---
1515

@@ -25,7 +25,7 @@ This quickstart uses the Go language to call the Bing News Search API. The resul
2525

2626
## Create a project and import libraries
2727

28-
Create a new Go project in your IDE or editor. Then, import `net/http` for requests, `ioutil` to read the response, `encoding/json` to handle the JSON text of results, and the go-spew library to parse the JSON results.
28+
Create a new Go project in your IDE or editor. Then, import `net/http` for requests, `ioutil` to read the response, `encoding/json` to handle the JSON text of results, and the `go-spew` library to parse the JSON results.
2929

3030
```go
3131
package main
@@ -116,9 +116,9 @@ req.Header.Add("Ocp-Apim-Subscription-Key", token)
116116

117117
```
118118

119-
## Get request
119+
## GET request
120120

121-
Create the client and send the Get request.
121+
Create the client and send the GET request.
122122

123123
```go
124124
// Instantiate a client.

articles/cognitive-services/Bing-News-Search/java.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ manager: nitinme
99
ms.service: cognitive-services
1010
ms.subservice: bing-news-search
1111
ms.topic: quickstart
12-
ms.date: 05/19/2020
12+
ms.date: 05/22/2020
1313
ms.author: aahi
1414
ms.custom: seodec2018
1515
---
@@ -45,7 +45,7 @@ The source code for this sample is available [on GitHub](https://github.com/Azur
4545
import com.google.gson.JsonParser;
4646
```
4747

48-
2. Create a new class, with variables for the API endpoint, your subscription key, and search term. You can use the global endpoint in the following code, or use the [custom subdomain](../../cognitive-services/cognitive-services-custom-subdomains.md) endpoint displayed in the Azure portal for your resource.
48+
2. Create a new class. Add variables for the API endpoint, your subscription key, and search term. You can use the global endpoint in the following code, or use the [custom subdomain](../../cognitive-services/cognitive-services-custom-subdomains.md) endpoint displayed in the Azure portal for your resource.
4949

5050
```java
5151
public static SearchResults SearchNews (String searchQuery) throws Exception {
@@ -111,7 +111,7 @@ The source code for this sample is available [on GitHub](https://github.com/Azur
111111

112112
3. In the main method of your application, call the search method and display the results.
113113

114-
```csharp
114+
```java
115115
public static void main (String[] args) {
116116
System.out.println("Searching the Web for: " + searchTerm);
117117
SearchResults result = SearchNews(searchTerm);

articles/cognitive-services/Bing-News-Search/nodejs.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,13 @@ manager: nitinme
88
ms.service: cognitive-services
99
ms.subservice: bing-news-search
1010
ms.topic: quickstart
11-
ms.date: 05/19/2020
11+
ms.date: 05/22/2020
1212
ms.author: aahi
1313
ms.custom: seodec2018
1414
---
1515
# Quickstart: Perform a news search using Node.js and the Bing News Search REST API
1616

17-
Use this quickstart to make your first call to the Bing Image Search API. This simple JavaScript application sends a search query to the API and displays the JSON response.
17+
Use this quickstart to make your first call to the Bing News Search API. This simple JavaScript application sends a search query to the API and displays the JSON response.
1818

1919
Although this application is written in JavaScript and runs in Node.js, the API is a RESTful Web service compatible with most programming languages.
2020

@@ -36,7 +36,7 @@ The source code for this sample is available on [GitHub](https://github.com/Azur
3636
let https = require('https');
3737
```
3838

39-
2. Create variables for the API endpoint, image API search path, your subscription key, and search term. You can use the global endpoint in the following code, or use the [custom subdomain](../../cognitive-services/cognitive-services-custom-subdomains.md) endpoint displayed in the Azure portal for your resource.
39+
2. Create variables for the API endpoint, news API search path, your subscription key, and search term. You can use the global endpoint in the following code, or use the [custom subdomain](../../cognitive-services/cognitive-services-custom-subdomains.md) endpoint displayed in the Azure portal for your resource.
4040

4141
```javascript
4242
let subscriptionKey = 'enter key here';
@@ -57,7 +57,7 @@ The source code for this sample is available on [GitHub](https://github.com/Azur
5757
let response_handler = function (response) {
5858
let body = '';
5959
};
60-
```
60+
```
6161

6262
3. Store the body of the response when the `data` flag is called.
6363

articles/cognitive-services/Bing-News-Search/php.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ manager: nitinme
99
ms.service: cognitive-services
1010
ms.subservice: bing-news-search
1111
ms.topic: quickstart
12-
ms.date: 05/19/2020
12+
ms.date: 05/22/2020
1313
ms.author: aahi
1414
ms.custom: seodec2018
1515
---

articles/cognitive-services/Bing-News-Search/python.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ manager: nitinme
99
ms.service: cognitive-services
1010
ms.subservice: bing-news-search
1111
ms.topic: quickstart
12-
ms.date: 05/19/2020
12+
ms.date: 05/22/2020
1313
ms.author: aahi
1414
ms.custom: seodec2018
1515
---

articles/cognitive-services/Bing-News-Search/ruby.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ manager: nitinme
99
ms.service: cognitive-services
1010
ms.subservice: bing-news-search
1111
ms.topic: quickstart
12-
ms.date: 05/19/2020
12+
ms.date: 05/22/2020
1313
ms.author: aahi
1414
ms.custom: seodec2018
1515
---

0 commit comments

Comments
 (0)