Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #48079

Re: Having a hard time to 'get' bing api search results

Path csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!newsfeed.xs4all.nl!newsfeed1.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail
Return-Path <lists@studiosola.com>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.011
X-Spam-Evidence '*H*': 0.98; '*S*': 0.00; 'column': 0.07; 'json': 0.07; 'received:64.202.165': 0.07; "subject:' ": 0.07; 'string': 0.09; 'ascii': 0.09; 'url:blog': 0.10; 'api': 0.11; 'cc:addr :python-list': 0.11; 'from:addr:lists': 0.16; 'subject:search': 0.16; 'thoughts?': 0.16; 'wrote:': 0.18; 'all,': 0.19; 'trying': 0.19; 'thu,': 0.19; 'url:view': 0.20; 'email addr:gmail.com&gt;': 0.22; 'cc:addr:python.org': 0.22; 'cc:2**0': 0.24; "i've": 0.25; 'query': 0.26; 'header:In-Reply-To:1': 0.27; 'correct': 0.29; "doesn't": 0.30; 'specified': 0.30; "i'm": 0.30; 'url:mailman': 0.30; 'code': 0.31; 'getting': 0.31; '13,': 0.31; 'option.': 0.31; 'search.': 0.31; 'url:05': 0.31; 'file': 0.32; 'url:python': 0.33; 'subject:time': 0.33; "i'd": 0.34; 'problem.': 0.35; 'executing': 0.36; 'received:64.202': 0.36; 'url:listinfo': 0.36; 'shows': 0.36; 'possible': 0.36; 'url:org': 0.36; 'should': 0.36; 'wrong': 0.37; 'skip:& 10': 0.38; 'pm,': 0.38; 'url:2012': 0.39; 'url:mail': 0.40; 'enclosed': 0.60; 'browser': 0.61; 'matter': 0.61; 'header:Message-Id:1': 0.63; 'to:addr:gmail.com': 0.65; 'charset:windows-1252': 0.65; 'subject:get': 0.81; '2013,': 0.91; 'subject:results': 0.91; 'url:latest': 0.91; '2013': 0.98
Content-Type multipart/alternative; boundary="Apple-Mail=_1157764F-AA99-405D-AFBC-62D5CB36197F"
Mime-Version 1.0 (Mac OS X Mail 6.2 \(1499\))
Subject Re: Having a hard time to 'get' bing api search results
From Kevin LaTona <lists@studiosola.com>
In-Reply-To <CAJ=2b06XgZjYs=vDayBTKTJsASeqJZkXiVQfvucqwBsrQAkGnw@mail.gmail.com>
Date Thu, 13 Jun 2013 15:27:05 -0700
References <CAJ=2b05Vooh1V3ZOijtS0Y4AwKLSQdbiRhOKkqwzKi_dJ_3m6w@mail.gmail.com> <CAJ=2b06XgZjYs=vDayBTKTJsASeqJZkXiVQfvucqwBsrQAkGnw@mail.gmail.com>
To Yves S. Garret <yoursurrogategod@gmail.com>
X-Mailer Apple Mail (2.1499)
X-Mailman-Approved-At Fri, 14 Jun 2013 10:20:30 +0200
Cc "python-list@python.org" <python-list@python.org>
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.15
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <http://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <http://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.3263.1371198031.3114.python-list@python.org> (permalink)
Lines 128
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1371198031 news.xs4all.nl 15915 [2001:888:2000:d::a6]:52102
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:48079

Show key headers only | View raw


[Multipart message — attachments visible in raw view] - view raw


>>Queries should be URL encoded; query string should be enclosed in %27 (apostrophe).

I was looking at the wrong column on the ascii chart,… so your %27 was correct

If you are getting in via a browser than it's url lib thing.

You might want to look at Requst lib as a possible option.

http://docs.python-requests.org/en/latest/


-Kevin



On Jun 13, 2013, at 2:31 PM, Yves S. Garret <yoursurrogategod@gmail.com> wrote:

> This is the format that I've been following:
> http://gavinmhackeling.com/blog/2012/05/using-the-bing-search-api-in-python/
> 
> If I execute the specified query from a browser, the JSON file
> shows up without a problem.  Now, I'd like to do that programmatically.
> 
> 
> On Thu, Jun 13, 2013 at 4:57 PM, Yves S. Garret <yoursurrogategod@gmail.com> wrote:
> Hello all,
> 
> This is my dilemma, I'm trying to get the generated JSON file using the bing api 
> search.
> 
> This is the code that I'm executing from inside the shell:
> http://bin.cakephp.org/view/460660617
> 
> The port doesn't matter to me.  Thoughts?
> 
> -- 
> http://mail.python.org/mailman/listinfo/python-list

Back to comp.lang.python | Previous | Next | Find similar | Unroll thread


Thread

Re: Having a hard time to 'get' bing api search results Kevin LaTona <lists@studiosola.com> - 2013-06-13 15:27 -0700

csiph-web