This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
post_date = post_date.gsub('Today', Time.now.strftime('%d.%m.%Y')) | |
post_date = post_date.gsub('Yesterday', 1.day.ago.strftime('%d.%m.%Y')) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
I have this HTML fragment from a vBulleting board: | |
<div id="post_message_5344600"> | |
<div style="margin: 5px 20px 20px;"> | |
<div style="margin-bottom: 2px;" class="smallfont">Quote:</div> | |
<table width="100%" cellspacing="0" cellpadding="8" border="0"> | |
<tbody><tr> | |
<td style="border: 1px inset;" class="alt2"> | |
<div> | |
Quote from <strong>Ahnungslos</strong> | |
<a rel="nofollow" href="showthread.php? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div id="post_message_5344600"> | |
<div style="margin: 5px 20px 20px;"> | |
<div style="margin-bottom: 2px;" class="smallfont">Quote:</div> | |
<table width="100%" cellspacing="0" cellpadding="8" border="0"> | |
<tbody><tr> | |
<td style="border: 1px inset;" class="alt2"> | |
<div> | |
Quote from <strong>Ahnungslos</strong> | |
<a rel="nofollow" href="showthread.php?p=5344371#post5344371">Show post</a> | |
</div> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Sitemap.xml Generator is a Jekyll plugin that generates a sitemap.xml file by | |
# traversing all of the available posts and pages. | |
# pke: modified to use site.config['sitemap']['url'] instead of MY_URL | |
# | |
# How To Use: | |
# 1.) Copy source file into your _plugins folder within your Jekyll project. | |
# 2.) Change MY_URL to reflect your domain name. | |
# 3.) Change SITEMAP_FILE_NAME if you want your sitemap to be called something | |
# other than sitemap.xml. | |
# 4.) Change the PAGES_INCLUDE_POSTS list to include any pages that are looping |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ENV['RC_ARCHS'] = '' if RUBY_PLATFORM =~ /darwin/ | |
# :stopdoc: | |
require 'mkmf' | |
ROOT = File.expand_path(File.join(File.dirname(__FILE__), '..', '..')) | |
specified_curl = ARGV[0] =~ /^--with-curl/ ? ARGV[0].split("=")[1] : nil | |
LIBDIR = specified_curl ? "#{specified_curl}/lib": Config::CONFIG['libdir'] | |
INCLUDEDIR = specified_curl ? "#{specified_curl}/include" : Config::CONFIG['includedir'] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
template<class T = HGDIOBJ> | |
class COldObject { | |
public: | |
typedef T (WINAPI* restore)(HDC hdc, T old); | |
COldObject(HDC dc, T old, restore func = SelectObject) : dc(dc), old(old), func(func) {} | |
~COldObject() { | |
func(dc, (T)old); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Server.controllers :installer, :parent => :licenses do | |
before do | |
puts params.inspect | |
@license = License.get(params[:license_id]) | |
halt 404, "License not found" unless @license | |
end | |
get :index, :with => :token do | |
halt 404, "File not found" if @license.installer.token != params[:token] | |
# installer.path is something like c:/installers/install.exe |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-@title = 'License Slots' | |
.block | |
.secondary-navigation | |
ul.wat-cf | |
li.first==link_to pat(:list), url(:licenses, :index) | |
li==link_to pat(:new), url(:licenses, :new) | |
li==link_to pat(:edit), url(:licenses, :edit, :id => @license.id) | |
li.active==link_to pat(:slots), url(:licenses, :slots, :id => @license.id) | |
.content | |
.secondary-navigation |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CreationCollisionOption = Windows.Storage.CreationCollisionOption | |
describe 'Zip component', -> | |
it 'should handle OpenDocument containers', -> | |
spec.async -> | |
uri = "resource/test1.odt".toAppPackageUri() | |
stream = Windows.Storage.Streams.RandomAccessStreamReference.createFromUri(uri) | |
runtime.zip.ZipArchive.createFromStreamReferenceAsync(stream) | |
.then (archive) -> | |
expect(archive.files.length).toEqual 17 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ApplicationView = Windows.UI.ViewManagement.ApplicationView | |
ApplicationViewState = Windows.UI.ViewManagement.ApplicationViewState | |
ApplicationLanguages = Windows.Globalization.ApplicationLanguages | |
CURRENT_RATE_LIMIT = MAX_RATE_LIMIT = 60 | |
RATE_LIMIT_TICK = 2000 | |
RATE_LIMITED_MESSAGE_QUEUE = new Queue() | |
logger = window.console |
OlderNewer