Skip to content

Instantly share code, notes, and snippets.

@hissy
Last active August 29, 2015 14:04
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hissy/8f02df97e55e6678de4b to your computer and use it in GitHub Desktop.
Save hissy/8f02df97e55e6678de4b to your computer and use it in GitHub Desktop.
an example of 5.7 compatible package controller (just trial)
<?php
namespace Concrete\Package\SocialShareLite;
use Package;
use BlockType;
class Controller extends Package {
protected $pkgHandle = 'social_share_lite';
protected $appVersionRequired = '5.6.9';
protected $pkgVersion = '1.1';
public function getPackageDescription() {
return t("Add social sharing buttons");
}
public function getPackageName() {
return t("Social Share Lite");
}
public function install() {
$pkg = parent::install();
BlockType::installBlockTypeFromPackage('social_share_lite',$pkg);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment