Skip to content

Instantly share code, notes, and snippets.

@smaida
smaida / Delete Account
Created September 27, 2011 02:49
ExpressionEngine Delete Member Account Function
public function cancel_account()
{
$this->member_id = $this->EE->TMPL->fetch_param('member_id');
$this->return = $this->EE->TMPL->fetch_param('return', 'site_index');
$this->EE->lang->loadfile('login');
/* -------------------------------------
/* No sneakiness - we'll do this in case the site administrator
@smaida
smaida / ExpressionEngine .htaccess
Created September 19, 2011 02:06
Standard .htaccess file used for ExpressionEngine installations
<IfModule mod_rewrite.c>
# Enable Rewrite Engine
# ------------------------------
RewriteEngine On
RewriteBase /
# Redirect index.php Requests
# ------------------------------
@smaida
smaida / Extending Tag Module
Created September 18, 2011 13:11
Extending the Solspace Tag Module (ExpressionEngine)
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
/**
*
* @package VC_energy_tomorrow
* @subpackage ThirdParty
* @category Modules
* @author Shawn Maida | Alex Glover
* @link http://www.eecoder.com
*/
@smaida
smaida / Channel Entry Tags
Created September 18, 2011 03:23
Parse Tags to Solspace Tag Module (Used when parsing entries with the ExpressionEngine Channel Entries API)
// Module code
// I(is_file(PATH_THIRD.'tag/mod.tag'.EXT) && count($tags) > 0)
{
require_once PATH_THIRD.'tag/mod.tag'.EXT;
$TAG = new Tag();
$TAG->channel_id = $this->channel_id;
$TAG->site_id = $this->site_id;
$TAG->entry_id = $this->EE->api_channel_entries->entry_id;