My Recent Pastes (61 and counting)
Pastes by Joon Park (61 and counting)
Below are the 15 most recent pasties by Joon Park.
October 09, 2007
8:50AM EDT
by Joon Park
View more (20 lines)
Copyright (c) 2007 Olav Bjorkoy (http://bjorkoy.com) Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights
October 07, 2007
4:37PM EDT
by Joon Park
View more (87 lines)
/** * Generate the themed output. * * All requests for theme hooks must go through this function. It examines * the request and routes it to the appropriate theme function. The theme
October 05, 2007
11:49AM EDT
by Joon Park
View more (190 lines)
warning: Cannot modify header information - headers already sent by (output started at /Users/joon/Sites/projects/drupal/includes/database.mysqli.inc:156) in /Users/joon/Sites/projects/drupal/includes/common.inc on line 141. user warning: Table 'drupalhead.node' doesn't exist query: CREATE TEMPORARY TABLE missing_nids Engine=HEAP SELECT n.nid, n.changed, n.uid FROM node n LEFT JOIN node_comment_statistics c ON n.nid = c.nid WHERE c.comment_count IS NULL in /Users/joon/Sites/projects/drupal/modules/comment/comment.install on line 9. user warning: Table 'drupalhead.missing_nids' doesn't exist query: INSERT INTO node_comment_statistics (nid, last_comment_timestamp, last_comment_name, last_comment_uid, comment_count) SELECT n.nid, n.changed, NULL, n.uid, 0 FROM missing_nids n in /Users/joon/Sites/projects/drupal/modules/comment/comment.install on line 10. user warning: Table 'drupalhead.node_type' doesn't exist query: SELECT nt.type, nt.* FROM node_type nt ORDER BY nt.type ASC in /Users/joon/Sites/projects/drupal/modules/node/node.module on line 479. user warning: Table 'drupalhead.cache_block' doesn't exist query: DELETE FROM cache_block WHERE expire != 0 AND expire < 1191599250 in /Users/joon/Sites/projects/drupal/includes/cache.inc on line 163.
October 05, 2007
11:22AM EDT
by Joon Park
View more (9 lines)
<?php
function yourTheme_node($node, $teaser = 0, $page = 0) {
$output = phptemplate_node($node, $teaser, $page);
if ($teaser && $node->sticky && empty($node->preview)) {
drupal_set_content('New_Region', $output);
September 30, 2007
11:02PM EDT
by Joon Park
View more (55 lines)
/** * Determine the current section. The default associations are at the very top of this file. * * @see _section_data() */
September 30, 2007
2:03PM EDT
by Joon Park
View more (106 lines)
<?php /** * To force a section for debugging, set it here! NULL to disable. */
September 26, 2007
10:22AM EDT
by Joon Park
View more (79 lines)
/** * Returns a themed representation of all stylesheets that should be attached to the page. * It loads the CSS in order, with 'core' CSS first, then 'module' CSS, then 'theme' CSS files. * This ensures proper cascading of styles for easy overriding in modules and themes. *
September 24, 2007
12:34PM EDT
by Joon Park
View more (9 lines)
function theme_system_elements($form) {
foreach (element_children($form) as $element) {
if (isset($form[$element]['#size'])) {
$form[$element]['#size'] = '100';
September 24, 2007
12:32PM EDT
by Joon Park
View more (9 lines)
function theme_system_elements($form) {
foreach (element_children($form) as $element) {
if (isset($form[$element][#size])) {
$form[$element][#size] = '100';
September 21, 2007
8:45PM EDT
by Joon Park
View more (15 lines)
switch ($hook) {
case 'node':
$vars['lesson_number'] = '';
foreach($vars['node']->taxonomy as $key => $keycontent) {
if ($keycontent->vid != 1) {
September 21, 2007
8:44PM EDT
by Joon Park
View more (14 lines)
switch ($hook) {
case 'node':
foreach($vars['node']->taxonomy as $key => $keycontent) {
if ($keycontent->vid != 1) {
unset($vars['taxonomy']['taxonomy_term_'. $key]);
September 21, 2007
6:17PM EDT
by Joon Park
View more (302 lines)
/**
* Implementation of hook_widget().
*/
function optionwidgets_widget($op, &$node, $field, &$items) {
switch ($op) {
September 10, 2007
9:56AM EDT
by Joon Park
View more (30 lines)
<?php // from aggregator_menu() $items['aggregator/sources/%aggregator_feed'] = array(
September 06, 2007
12:41PM EDT
by Joon Park
View more (25 lines)
/**
* Implementation of hook_theme()
*/
function search_theme() {
return array(
September 05, 2007
10:42PM EDT
by Joon Park
View more (13 lines)
function _phptemplate_variables($vars, $hook) {
static $node_types = aray();
if ($hook == 'node') {
$node_types[] = $vars['node']->type;
