Skip to content

Instantly share code, notes, and snippets.

@dajare
dajare / expositorsGreekTestament.md
Created May 16, 2015 16:54
Expositor's Greek Testament

[Detailed contents][dc] from Logos:

  • Volume 1: Matthew - John
  • Volume 2: Acts - 1 Corinthians
  • [Volume 3][3]: 2 Corinthians - Colossians
  • [Volume 4][4]: 1 Thessalonians - James
  • [Volume 5][5]: 1 Peter - Revelation
@dajare
dajare / 20141031.md
Created October 23, 2014 12:19
Hans Day

A Day in Honour of
Professor Hans Barstad

  • 31 October 2014
  • 11:15 – 17:00
  • New College, Edinburgh
    EH1 2LX
@dajare
dajare / wolft_frontend_backend_edit.md
Last active August 29, 2015 14:06
Frontend links for page editing in backend

Frontend links for page editing in backend

This "tutorial" is based on a forum thread started by Ormente with responses from Martijn. Consult that thread for further discussion.

It's often useful to be able to go directly to the backend to edit a page while browsing your site. You can make such a link in Wolf by copying this code into a snippet (filter set to -none-):

<?php

// Check there's a user session

@dajare
dajare / upgrade_20140520.md
Created May 20, 2014 07:38
Packages upgraded in Ubuntu 14.04 on 2014.05.20

Upgrade:

  • libreoffice-pdfimport:amd64 (4.2.4rc2-0ubuntu1trusty1, 4.2.4rc2-0ubuntu1trusty2)
  • libreoffice-base-core:amd64 (4.2.4rc2-0ubuntu1trusty1, 4.2.4rc2-0ubuntu1trusty2)
  • ure:amd64 (4.2.4rc2-0ubuntu1trusty1, 4.2.4rc2-0ubuntu1trusty2)
  • libreoffice-writer:amd64 (4.2.4rc2-0ubuntu1trusty1, 4.2.4rc2-0ubuntu1trusty2)
  • libreoffice-impress:amd64 (4.2.4rc2-0ubuntu1trusty1, 4.2.4rc2-0ubuntu1trusty2)
  • uno-libs3:amd64 (4.2.4rc2-0ubuntu1trusty1, 4.2.4rc2-0ubuntu1trusty2)
  • libreoffice-avmedia-backend-gstreamer:amd64 (4.2.4rc2-0ubuntu1trusty1, 4.2.4rc2-0ubuntu1trusty2)
  • libreoffice-base:amd64 (4.2.4rc2-0ubuntu1trusty1, 4.2.4rc2-0ubuntu1trusty2)
@dajare
dajare / tbBreadcrumbs.php
Created September 8, 2013 21:18
Converts the breadcrumbs code from Wolf CMS's default function for use with Bootstrap's breadcrumbs component
<ul class="breadcrumb">
<?php // for use with Twitter Bootstrap breadcrumbs component
$explode = explode("&raquo;</span>", $this->breadcrumbs('&raquo;'));
foreach ($explode as $key => $val) {
$val = preg_replace("/<span[^>]+\>/i", "", $val);
$val = str_replace("</span>", "", $val);
$pattern = '#<a href="(.+)" title="(.+)">#';
@dajare
dajare / smallCapsOnOff.bas
Created August 25, 2013 21:09
LibreOffice macro to start/stop small caps character formatting
sub SmallCapsStart
rem ----------------------------------------------------------------------
rem define variables
dim document as object
dim dispatcher as object
rem ----------------------------------------------------------------------
rem get access to the document
document = ThisComponent.CurrentController.Frame
dispatcher = createUnoService("com.sun.star.frame.DispatchHelper")
@dajare
dajare / dajaregistio002.md
Last active September 12, 2016 08:20
Day and Night

It's all about the Sun

When the earth faces towards the sun, that part of the sun has "daytime". The part of the earth facing away from the sun will have "night".

Sun lights the earth

The earth is shaped like a ball:

Spinning globe

@dajare
dajare / dajaregistio001.md
Created August 19, 2013 09:41
Because I Can

Because

He was not Mr Wentworth, the former curate of Monkford, however suspicious appearances may be, but a Captain Frederick Wentworth, his brother, who being made commander in consequence of the action off St Domingo, and not immediately employed, had come into Somersetshire, in the summer of 1806; and having no parent living, found a home for half a year at Monkford.

That was one long sentence. Don't blame me, though. Blame Jane Austen.

Jane Austen portrait

More

@dajare
dajare / xmlQuery.php
Last active December 18, 2015 05:59
Code for querying XML file
<?php // for Wolf CMS: save in page /xml-query
<p>Result from LexicalIndex.xml residing on Github:</p>
<?php
if (isset($_POST['search'])){
$searchcriteria = $_POST['search'];
if($searchcriteria != NULL) {
// $this->includeSnippet('sitesearch');
$hebSearch = mb_convert_encoding($_POST['search'], 'UTF-8', 'UTF-8');