Skip to content

Instantly share code, notes, and snippets.

View kawahara's full-sized avatar

Shogo Kawahara (bucyou) kawahara

  • freee
  • Kyoto, Japan
  • 10:45 (UTC +09:00)
View GitHub Profile
<?php
class opDoctrineConnectionOpenPNE extends Doctrine_Connection_Mysql
{
protected function unsetDbh()
{
if (!$this->transaction->getTransactionLevel())
{
$this->dbh = null;
diff --git a/lib/config/sfOpenPNEApplicationConfiguration.class.php b/lib/config/sfOpenPNEApplicationConfiguration.class.php
index aabc8bd..43b3699 100644
--- a/lib/config/sfOpenPNEApplicationConfiguration.class.php
+++ b/lib/config/sfOpenPNEApplicationConfiguration.class.php
@@ -19,6 +19,9 @@ abstract class sfOpenPNEApplicationConfiguration extends sfApplicationConfigurat
{
static protected $zendLoaded = false;
+ protected $globEnablePluginList = array();
+ protected $globEnablePluginControllerList = array();
<?php
class MyPDOStatement extends PDOStatement
{
protected $pdo;
protected function __construct(PDO $pdo)
{
$this->pdo = $pdo;
}
public function retrieveGadgetsByTypesName($typesName)
{
$file = sfConfig::get('sf_app_cache_dir').'/config/'.sfInflector::underscore($typesName)."_gadgets.php";
if (is_readable($file))
{
return include($file);
}
$types = $this->getTypes($typesName);
diff --git a/lib/model/doctrine/GadgetTable.class.php b/lib/model/doctrine/GadgetTable.class.php
index 33ba22c..1659906 100644
--- a/lib/model/doctrine/GadgetTable.class.php
+++ b/lib/model/doctrine/GadgetTable.class.php
@@ -10,25 +10,28 @@
class GadgetTable extends opAccessControlDoctrineTable
{
- protected $results;
+ protected
<?xml version="1.0" encoding="UTF-8"?>
<Module>
<ModulePrefs title="Activity Test" description="Activityのテスト">
<Link rel="event.addapp" href="http://debian/oauth/t.php" method="POST" />
<Link rel="event.removeapp" href="http://debian/oauth/t.php" method="POST" />
<Require feature="opensocial-0.8" />
<Require feature="dynamic-height" />
</ModulePrefs>
<Content type="html"><![CDATA[
Hello!<br />
<?php
include_once 'lib/OAuth.php';
class OAuthSignatureMethod_RSA_SHA1_opOpenSocialPlugin extends OAuthSignatureMethod_RSA_SHA1
{
protected function fetch_private_cert(&$request) {
}
protected function fetch_public_cert(&$request) {
<?php
// サンプルです 実際の利用には適しません。
include_once 'lib/OAuth.php';
define('CONSUMER_KEY', '#CONSUMER_KEY#');
define('CONSUMER_SECRET', '#CONSUMER_SECRET#');
define('BASE_URL', '#BASE_URL#');
diff --git a/config/doctrine/schema.yml b/config/doctrine/schema.yml
index 4ee403a..7696e66 100644
--- a/config/doctrine/schema.yml
+++ b/config/doctrine/schema.yml
@@ -15,7 +15,7 @@ Op2Entry:
columns:
id: { type: integer(4), primary: true, autoincrement: true }
op2_member_id: { type: integer(4), notnull: true }
- number: { type: intger(4) }
+ number: { type: integer(4) }
<?php
include_once './oauth/OAuth.php';
// change these consts
define('CONSUMER_KEY', '#CONSUMER_KEY#');
define('CONSUMER_SECRET', '#CONSUMER_SECRET#');
define('BASE_URL', '#SNS_URL#');