Skip to content

Instantly share code, notes, and snippets.

View bjornbjorn's full-sized avatar

Bjørn Børresen bjornbjorn

View GitHub Profile
@chinmaygarde
chinmaygarde / FlutterEmbedderGLFW.cc
Last active November 23, 2023 16:26
Flutter Embedder API Example (GLFW with OpenGL)
#include <assert.h>
#include <chrono>
#include <embedder.h>
#include <glfw3.h>
#include <iostream>
static_assert(FLUTTER_ENGINE_VERSION == 1, "");
static const size_t kInitialWindowWidth = 800;
@rsanchez
rsanchez / gist:9549396
Last active August 29, 2015 13:57
Deep + Resource Router
<?php
use rsanchez\Deep\Deep;
use rsanchez\Deep\App\Entries;
$config['resource_router'] = array(
'json' => function($router) {
Deep::bootEloquent(ee());
$entries = Entries::channel('blog')->limit(10)->get();
@iainurquhart
iainurquhart / gist:8481777
Created January 17, 2014 21:18
example of image widget using P&T assets, you'll need to update the ACT id for outputting the image thumb, relevant to your install.
<table class="mainTable entry_widget_notop" border="0" cellspacing="0" cellpadding="0" data-index="0">
<tbody>
<tr>
<td style="width: 100px;">
<?php if($options['image_id']):?>
<img src="/?ACT=40&file_id=<?=$options['image_id']?>&size=100x100&hash=1361909881">
<?php endif ?>
<p><a href="#" class="thumbnail_trigger">Add File</a></p>
<title>{title}{site_name}</title>
<meta name='keywords' content='{meta_keywords}' />
<meta name='description' content='{meta_description}' />
<link rel='canonical' href='{canonical_url}' />
<meta property="og:url" content="{canonical_url}"/>
<meta property="og:title" content="{entry_title}"/>
<meta property="og:description" content="{extra:desc}"/>
<meta property="og:image" content="{extra:image}"/>
@airways
airways / mod.extendedchannel.php
Created October 28, 2011 15:52
ExpressionEngine: Extending a core or third party module or plugin
<?php
class ExtendedChannel {
public __construct()
{
$this->EE = &get_instance();
}
public function extended_entries()
{