0

copyright character in Yahoo REST api

Dear all

I am using the Yahoo REST API for web search. I need to exclude the copyrighted contents from search results. For this purpose I modify the value of “query” parameter as follows

‘query=beautiful flowers -© -copyright -"All rights reserved"’ .

When I use API for searching, it returns error. When I remove © character, it works properly. I assume that the problem with © character.
Is there any way to eliminate the results having the © character.

Thanks
Albert

by
3 Replies
  • QUOTE (albertjacod @ May 6 2009, 12:41 AM) <{POST_SNAPBACK}>
    Dear all

    I am using the Yahoo REST API for web search. I need to exclude the copyrighted contents from search results. For this purpose I modify the value of “query” parameter as follows

    ‘query=beautiful flowers -© -copyright -"All rights reserved"’ .

    When I use API for searching, it returns error. When I remove © character, it works properly. I assume that the problem with © character.
    Is there any way to eliminate the results having the © character.

    Thanks
    Albert

    Use &copy; instead of © .. just like with URL's spaces are changed to %20..
    You should create a script that can convert special chars to the correct html format.
    Also use UTF-8 ;)
    0
  • QUOTE (Die G @ May 6 2009, 11:31 AM) <{POST_SNAPBACK}>
    Use &copy; instead of © .. just like with URL's spaces are changed to %20..
    You should create a script that can convert special chars to the correct html format.
    Also use UTF-8 ;)Albert
    0
  • You should probably encode the string before using it in the rest request. Specific to the copyright symbol, have you tried %A9? I believe %A9 is the url encoded value of that symbol.

    - Jon

    QUOTE (albertjacod @ May 7 2009, 09:31 PM) <{POST_SNAPBACK}>
    Thanks for reply.

    I used the same (&copy; instead of ©).

    ( ‘query=beautiful flowers -copyright -&copy; -"all rights reserved"’)
    And
    ( ‘query=beautiful flowers -copyright -“&copy;” -"all rights reserved"’)

    And also spaces are replaced with %20.

    But it could not eliminate the results having ©.
    Have any other idea?
    Is it possible in Yahoo REST API to eliminate the results having the character ©?
    Thanks
    Albert
    0

Recent Posts

in General Discussion at YDN