Skip to content

Instantly share code, notes, and snippets.

Aleksandar Kostadinov akostadinov

Block or report user

Report or block akostadinov

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@akostadinov
akostadinov / _http_continue.txt
Last active Mar 28, 2018 — forked from trevorrowe/client.rb
Ruby Net::HTTP Expect-100 continue PUT bug
View _http_continue.txt
# Start the sample server. This server alternates between responding with 100-continue and
# resopnding with a 403 Forbidden. The client **should** be able to handle both responses.
$ ruby server.rb
# In another terminal window, run the client code twice. The first invocation will succeed.
# The second invocation will fail the client with an error.
$ ruby client.rb
$ ruby client.rb
@akostadinov
akostadinov / add_child_ns_nokogiri_bug.rb
Last active Jun 9, 2016 — forked from gioele/add_child_ns.rb
Nokogiri `add_child` does not copy namespaces
View add_child_ns_nokogiri_bug.rb
#!/usr/bin/env ruby
# see https://github.com/sparklemotion/nokogiri/issues/1200
require 'nokogiri'
src =<<EOD
<wrapper xmlns="ns">
<record xml:id="r1" xmlns:extra="extra">
<field>aaa</field>
View fb2ical.php
<?php
/*
original code by cogitom: https://gist.github.com/997980/
phibo23: https://gist.github.com/2808256/
This script reads future events (plus several days into the past) from Facebook pages
and creates a subscribable iCalendar
Improvements upon the original version:
- avoid setting DTEND field if facebook event lacks an end time
You can’t perform that action at this time.