Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add yandex as search engine #35

Merged
merged 3 commits into from
Feb 6, 2013
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions README.rdoc
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ Via gem:
* <code>:ping_yahoo</code> -- <code>false</code>, needs <code>:yahoo_app_id</code> * <code>:ping_yahoo</code> -- <code>false</code>, needs <code>:yahoo_app_id</code>
* <code>:ping_bing</code> -- <code>false</code> * <code>:ping_bing</code> -- <code>false</code>
* <code>:ping_ask</code> -- <code>false</code> * <code>:ping_ask</code> -- <code>false</code>
* <code>:ping_yandex</code> -- <code>false</code>
* <code>:partial_update</code> -- <code>false</code> * <code>:partial_update</code> -- <code>false</code>


=== Change Frequency, Priority and Last Modified === Change Frequency, Priority and Last Modified
Expand Down
7 changes: 6 additions & 1 deletion lib/big_sitemap.rb
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ class BigSitemap
:ping_google => true, :ping_google => true,
:ping_yahoo => false, # needs :yahoo_app_id :ping_yahoo => false, # needs :yahoo_app_id
:ping_bing => false, :ping_bing => false,
:ping_ask => false :ping_ask => false,
:ping_yandex => false
} }


# TODO: Deprecate # TODO: Deprecate
Expand Down Expand Up @@ -229,6 +230,10 @@ def ping_search_engines
if @options[:ping_ask] if @options[:ping_ask]
Net::HTTP.get('submissions.ask.com', "/ping?sitemap=#{sitemap_uri}") Net::HTTP.get('submissions.ask.com', "/ping?sitemap=#{sitemap_uri}")
end end

if @options[:ping_yandex]
Net::HTTP.get('webmaster.yandex.ru', "/wmconsole/sitemap_list.xml?host=#{sitemap_uri}")
end
end end


# TODO: Deprecate # TODO: Deprecate
Expand Down