code stringlengths 12 2.05k | label_name stringclasses 5
values | label int64 0 4 |
|---|---|---|
function MAX_adRenderImageBeacon($logUrl, $beaconId = 'beacon', $userAgent = null)
{
if (!isset($userAgent) && isset($_SERVER['HTTP_USER_AGENT'])) {
$userAgent = $_SERVER['HTTP_USER_AGENT'];
}
$beaconId .= '_{random}';
// Add beacon image for logging
if (isset($userAgent) && preg_match("#Moz... | Base | 1 |
public function __destruct()
{
if ($this->Mailer == 'smtp') { //close any open SMTP connection nicely
$this->smtpClose();
}
} | Compound | 4 |
protected function getBodyTagAttributes()
{
$formEngineParameters = [];
$parameters = parent::getBodyTagAttributes();
$formEngineParameters['fieldChangeFunc'] = $this->parameters['fieldChangeFunc'];
$formEngineParameters['fieldChangeFuncHash'] = GeneralUtility::hmac(serialize($t... | Class | 2 |
public function deleteByName(){
$item_id = I("item_id/d");
$env_id = I("env_id/d");
$var_name = I("var_name");
$login_user = $this->checkLogin();
$uid = $login_user['uid'] ;
if(!$this->checkItemEdit($uid , $item_id)){
$this->sendError(10303);
... | Compound | 4 |
fwrite(STDERR, sprintf("%2d %s ==> %s\n", $i + 1, $test, var_export($result, true))); | Class | 2 |
protected function GetOrderedRefs($refList, $type, $order, $count = 0, $skip = 0)
{
if (!$refList)
return;
if (empty($type) || empty($order))
return null;
$args = array();
$args[] = '--sort=' . $order;
$args[] = '--format="%(refname)"';
if ($count > 0) {
if ($skip > 0) {
$args[] = '--count=... | Base | 1 |
protected function fixupImportedAttributes($modelName, X2Model &$model) {
if ($modelName === 'Contacts' || $modelName === 'X2Leads')
$this->fixupImportedContactName ($model);
if ($modelName === 'Actions' && isset($model->associationType))
$this->reconstructImportedActionAsso... | Base | 1 |
public function onRouteStartup(Enlight_Controller_EventArgs $args)
{
$request = $args->getRequest();
if (strpos($request->getPathInfo(), '/backend') === 0
|| strpos($request->getPathInfo(), '/api/') === 0
) {
return;
}
$shop = $this->getShopByReq... | Base | 1 |
$evs = $this->event->find('all', "id=" . $edate->event_id . $featuresql);
foreach ($evs as $key=>$event) {
if ($condense) {
$eventid = $event->id;
$multiday_event = array_filter($events, create_function('$event', 'global $eventid; retur... | Base | 1 |
public static function unsetTransactionPart(Db $zdb, Login $login, $trans_id, $contrib_id)
{
try {
//first, we check if contribution is part of transaction
$c = new Contribution($zdb, $login, (int)$contrib_id);
if ($c->isTransactionPartOf($trans_id)) {
... | Base | 1 |
public static function navtojson() {
return json_encode(self::navhierarchy());
}
| Base | 1 |
$sloc = expCore::makeLocation('navigation', null, $section->id);
// remove any manage permissions for this page and it's children
// $db->delete('userpermission', "module='navigationController' AND internal=".$section->id);
// $db->delete('grouppermission', "module='na... | Class | 2 |
function manage () {
expHistory::set('viewable', $this->params);
$vendor = new vendor();
$vendors = $vendor->find('all');
if(!empty($this->params['vendor'])) {
$purchase_orders = $this->purchase_order->find('all', 'vendor_id=' . $this->params['vendor']);
} else {
$purchase_orders = $this->purchas... | Base | 1 |
foreach ($page as $pageperm) {
if (!empty($pageperm['manage'])) return true;
}
| Base | 1 |
list($workgroup, $user) = explode('\\', $user);
} else {
$workgroup = null;
}
$this->state->init($workgroup, $user, $this->server->getPassword());
} | Base | 1 |
public function show()
{
$task = $this->getTask();
$subtask = $this->getSubtask();
$this->response->html($this->template->render('subtask_converter/show', array(
'subtask' => $subtask,
'task' => $task,
)));
} | Base | 1 |
public function meta_box_subject() {
$placeholder = __( 'What is your conversation about?', 'supportflow' );
echo '<h4>' . __( 'Subject', 'supportflow' ) . '</h4>';
echo '<input type="text" id="subject" name="post_title" class="sf_autosave" placeholder="' . $placeholder . '" value="' . get_the_title() . '" auto... | Base | 1 |
printf('<p>%s<br><strong>%s</strong> %s</p>',$row->post_title,$row->meta_key,$row->meta_value);
}
} | Base | 1 |
public static function isPublic($s) {
if ($s == null) {
return false;
}
while ($s->public && $s->parent > 0) {
$s = new section($s->parent);
}
$lineage = (($s->public) ? 1 : 0);
return $lineage;
}
| Base | 1 |
public function autocomplete() {
return;
global $db;
$model = $this->params['model'];
$mod = new $model();
$srchcol = explode(",",$this->params['searchoncol']);
/*for ($i=0; $i<count($srchcol); $i++) {
if ($i>=1) $sql .= " OR ";
$sql .= $srchc... | Base | 1 |
public function getQueryOrderby()
{
return $this->name;
} | Base | 1 |
$stmt->bindValue(":$field", $domain, SQLITE3_TEXT);
if($bindcomment) {
$stmt->bindValue(":comment", $comment, SQLITE3_TEXT);
}
if($stmt->execute() && $stmt->reset())
$num++;
else
{
$stmt->close();
if($returnnum)
return $num;
else
{
if($num === 1)
$plural = "";
else
$... | Class | 2 |
foreach ($val as $k => $v) {
unset($process[$key][$k]);
$stripTags = \in_array($k, $whiteList) ? false : $stripTagsConf;
if (\is_string($k)) {
$filteredKey = self::filterValue($k, $regex, $stripTags);
} else {
... | Base | 1 |
protected function filter($files) {
foreach ($files as $i => $file) {
if (!empty($file['hidden']) || !$this->default->mimeAccepted($file['mime'])) {
unset($files[$i]);
}
}
return array_merge($files, array());
} | Base | 1 |
public static function editor($mode = 'light'){
$editor = Options::v('use_editor');
if($editor == 'on'){
$GLOBALS['editor'] = true;
}else{
$GLOBALS['editor'] = false;
}
if ($mode == 'light') {
$GLOBALS['editor_mode'] = 'light';
... | Base | 1 |
function edit_section() {
global $db, $user;
$parent = new section($this->params['parent']);
if (empty($parent->id)) $parent->id = 0;
assign_to_template(array(
'haveStandalone' => ($db->countObjects('section', 'parent=-1') && $parent->id >= 0),
'paren... | Class | 2 |
public static function canImportData() {
return true;
}
| Base | 1 |
return $fa->nameGlyph($icons, 'icon-');
}
} else {
return array();
}
}
| Class | 2 |
public static function filesByMedia($media, $offset=0, $limit=-1, $wid=NULL, $text="", $orderby="date_added DESC, name ASC")
{
global $DB;
global $website;
if(empty($wid))
$wid = $website->id;
if($limit < 1)
$limit = 2147483647;
if(!empty($text))
$text = ' AND name... | Base | 1 |
foreach($image->expTag as $tag) {
if (isset($used_tags[$tag->id])) {
$used_tags[$tag->id]->count++;
} else {
$exptag = new expTag($tag->id);
$used_tags[$tag->id] = $exptag;
$used_tags[$tag->id]->c... | Base | 1 |
public function actionGetItems(){
$sql = 'SELECT id, name as value FROM x2_opportunities WHERE name LIKE :qterm ORDER BY name ASC';
$command = Yii::app()->db->createCommand($sql);
$qterm = $_GET['term'].'%';
$command->bindParam(":qterm", $qterm, PDO::PARAM_STR);
$result = $co... | Class | 2 |
public function __viewIndex()
{
$this->setPageType('table');
$this->setTitle(__('%1$s – %2$s', array(__('Pages'), __('Symphony'))));
$nesting = Symphony::Configuration()->get('pages_table_nest_children', 'symphony') == 'yes';
if ($nesting && isset($_GET['parent']) && is_n... | Base | 1 |
public function activate_address()
{
global $db, $user;
$object = new stdClass();
$object->id = $this->params['id'];
$db->setUniqueFlag($object, 'addresses', $this->params['is_what'], "user_id=" . $user->id);
flash("message", gt("Successfully updated address."));
... | Base | 1 |
public function __construct(string $appName,
IRequest $request,
ITimeFactory $timeFactory,
IInitialState $initialState,
BookingService $bookingService,
AppointmentConfigService $appointmentConfigService,
... | Class | 2 |
function comments_list($params)
{
if (!user_can_access('module.comments.index')) {
return;
}
if (!isset($params['content_id'])) {
if (isset($params['rel_id']) and isset($params['rel_type'])) {
$data = array(
'rel_id' => $para... | Base | 1 |
public function confirm()
{
$task = $this->getTask();
$subtask = $this->getSubtask();
$this->response->html($this->template->render('subtask/remove', array(
'subtask' => $subtask,
'task' => $task,
)));
} | Base | 1 |
public static function all()
{
global $DB;
global $website;
$DB->query('SELECT *
FROM nv_webuser_groups
WHERE website = '.protect($website->id));
return $DB->result();
}
| Base | 1 |
public function remove()
{
$this->checkCSRFParam();
$project = $this->getProject();
$swimlane_id = $this->request->getIntegerParam('swimlane_id');
if ($this->swimlaneModel->remove($project['id'], $swimlane_id)) {
$this->flash->success(t('Swimlane removed successfully... | Base | 1 |
public function configure() {
$this->config['defaultbanner'] = array();
if (!empty($this->config['defaultbanner_id'])) {
$this->config['defaultbanner'][] = new expFile($this->config['defaultbanner_id']);
}
parent::configure();
$banners = $this->banner->find('all', nul... | Base | 1 |
public function safePath($filename = 'data.csv'){
return implode(DIRECTORY_SEPARATOR, array(
Yii::app()->basePath,
'data',
$filename
));
} | Class | 2 |
private function getTaskLink()
{
$link = $this->taskLinkModel->getById($this->request->getIntegerParam('link_id'));
if (empty($link)) {
throw new PageNotFoundException();
}
return $link;
} | Base | 1 |
public function testRenderWithTrustedHeaderDisabled()
{
Request::setTrustedHeaderName(Request::HEADER_CLIENT_IP, '');
$strategy = new InlineFragmentRenderer($this->getKernelExpectingRequest(Request::create('/')));
$this->assertSame('foo', $strategy->render('/', Request::create('/'))->ge... | Class | 2 |
public static function name($id) {
$id = sprintf('%d', $id);
if(isset($id)){
$cat = Db::result("SELECT `name` FROM `cat`
WHERE `id` = '{$id}' LIMIT 1");
//print_r($cat);
if(isset($cat['error'])){
return '';
... | Base | 1 |
function PMA_getErrorReportForm()
{
$html = "";
$html .= '<form action="error_report.php" method="post" name="report_frm"'
. ' id="report_frm" class="ajax">'
. '<fieldset style="padding-top:0px">';
$html .= '<p>' . __(
'phpMyAdmin has encountered an error. We have collected ... | Base | 1 |
public function toolbar() {
// global $user;
$menu = array();
$dirs = array(
BASE.'framework/modules/administration/menus',
BASE.'themes/'.DISPLAY_THEME.'/modules/administration/menus'
);
foreach ($dirs as $dir) {
if (is_readable($dir)) {
$dh = opendir($dir);
while (... | Base | 1 |
public function actionGetItems(){
$sql = 'SELECT id, name as value FROM x2_docs WHERE name LIKE :qterm ORDER BY name ASC';
$command = Yii::app()->db->createCommand($sql);
$qterm = '%'.$_GET['term'].'%';
$command->bindParam(":qterm", $qterm, PDO::PARAM_STR);
$result = $command->queryAll();
echo CJSON::encod... | Base | 1 |
public static function client()
{
if (is_null(self::$client)) new CertificateAuthenticate();
return self::$client;
} | Base | 1 |
public static function rss() {
switch (SMART_URL) {
case true:
# code...
$inFold = (Options::v('permalink_use_index_php') == "on")? "/index.php":"";
$url = Site::$url.$inFold."/rss".GX_URL_PREFIX;
break;
default... | Base | 1 |
function build_daterange_sql($timestamp, $endtimestamp=null, $field='date', $multiday=false) {
if (empty($endtimestamp)) {
$date_sql = "((".$field." >= " . expDateTime::startOfDayTimestamp($timestamp) . " AND ".$field." <= " . expDateTime::endOfDayTimestamp($timestamp) . ")";
} else {... | Class | 2 |
protected function setUp()
{
parent::setUp();
$mongoClass = version_compare(phpversion('mongo'), '1.3.0', '<') ? 'Mongo' : 'MongoClient';
$this->mongo = $this->getMockBuilder($mongoClass)
->disableOriginalConstructor()
->getMock();
$this->options = arra... | Base | 1 |
$q = self::query($sql);
}
return true;
}
| Base | 1 |
function db_seq_nextval($seqname)
{
global $DatabaseType;
if ($DatabaseType == 'mysqli')
$seq = "fn_" . strtolower($seqname) . "()";
return $seq;
} | Base | 1 |
public function editTitle() {
global $user;
$file = new expFile($this->params['id']);
if ($user->id==$file->poster || $user->isAdmin()) {
$file->title = $this->params['newValue'];
$file->save();
$ar = new expAjaxReply(200, gt('Your title was updated succes... | Class | 2 |
public function read($sessionId)
{
$dbData = $this->getCollection()->findOne(array(
$this->options['id_field'] => $sessionId,
$this->options['expiry_field'] => array('$gte' => new \MongoDate()),
));
return null === $dbData ? '' : $dbData[$this->options['data_fiel... | Base | 1 |
function load_gallery($auc_id)
{
$UPLOADED_PICTURES = array();
if (is_dir(UPLOAD_PATH . $auc_id)) {
if ($dir = opendir(UPLOAD_PATH . $auc_id)) {
while ($file = @readdir($dir)) {
if ($file != '.' && $file != '..' && strpos($file, 'thumb-') === false) {
$UPL... | Base | 1 |
foreach($fields as $field)
{
if(substr($key, 0, strlen($field.'-'))==$field.'-')
{
$this->dictionary[substr($key, strlen($field.'-'))][$field] = $value;
}
}
| Base | 1 |
public function searchAdmin(){
$criteria = new CDbCriteria;
return $this->searchBase($criteria);
} | Base | 1 |
public function checkForReassign($operator)
{
$operator_name = ($this->locale == get_home_locale())
? $operator['vclocalename']
: $operator['vccommonname'];
$is_operator_correct = $this->nextAgent == $operator['operatorid']
|| $this->agentId == $operator['ope... | Base | 1 |
public function __construct()
{
parent::__construct();
$this->middleware(
static function ($request, $next) {
app('view')->share('title', (string)trans('firefly.transactions'));
app('view')->share('mainTitleIcon', 'fa-exchange');
retu... | Compound | 4 |
function GoodAuthDigestTestController($serverPort) {
$args = array('Authorization' => 'Digest username="admin", ' .
'realm="Restricted area", nonce="564a12611dae8", ' .
'uri="/test_auth_digest.php", cnonce="MjIyMTg1", nc=00000001, ' .
'qop="auth", response="e544aaed06917adea3e5c74dd49f0e32", ' .
'opaq... | Class | 2 |
$section = new section(intval($page));
if ($section) {
// self::deleteLevel($section->id);
$section->delete();
}
}
}
| Class | 2 |
protected function itemLock($hashes, $autoUnlock = true)
{
if (!elFinder::$commonTempPath) {
return;
}
if (!is_array($hashes)) {
$hashes = array($hashes);
}
foreach ($hashes as $hash) {
$lock = elFinder::$commonTempPath . DIRECTORY_SEPA... | Base | 1 |
public function update()
{
$project = $this->getProject();
$tag_id = $this->request->getIntegerParam('tag_id');
$tag = $this->tagModel->getById($tag_id);
$values = $this->request->getValues();
list($valid, $errors) = $this->tagValidator->validateModification($values);
... | Base | 1 |
function updateObject($object, $table, $where=null, $identifier='id', $is_revisioned=false) {
if ($is_revisioned) {
$object->revision_id++;
//if ($table=="text") eDebug($object);
$res = $this->insertObject($object, $table);
//if ($table=="text") eDebug($objec... | Base | 1 |
function fopen($filename, $mode)
{
if (\yiiunit\framework\base\SecurityTest::$fopen !== null) {
return \yiiunit\framework\base\SecurityTest::$fopen;
}
return \fopen($filename, $mode);
} | Class | 2 |
public function write($template = '')
{
if (!empty($this->script_files)) {
$this->set_env('request_token', $this->app->get_request_token());
}
$commands = $this->get_js_commands($framed);
// if all js commands go to parent window we can ignore all
// script ... | Compound | 4 |
$contents = ['form' => tep_draw_form('rates', 'tax_rates.php', 'page=' . $_GET['page'] . '&action=insert')]; | Base | 1 |
$contents[] = ['class' => 'text-center', 'text' => tep_draw_bootstrap_button(IMAGE_DELETE, 'fas fa-trash', null, 'primary', null, 'btn-danger xxx text-white mr-2') . tep_draw_bootstrap_button(IMAGE_CANCEL, 'fas fa-times', tep_href_link('specials.php', 'page=' . $_GET['page'] . '&sID=' . $sInfo->specials_id), null... | Base | 1 |
public function contactInformationSave(Request $request) {
session_append_array('checkout_v2', [
'first_name'=> $request->get('first_name'),
'last_name'=> $request->get('last_name'),
'email'=> $request->get('email'),
'phone'=> $request->get('phone')
]... | Base | 1 |
public function __construct() {
global $GLOBALS, $data;
self::$editors =& $GLOBALS;
self::$data =& $data;
self::$url = Options::v('siteurl');
self::$domain = Options::v('sitedomain');
self::$name = Options::v('sitename');
self::$key = Options::v('siteke... | Base | 1 |
$p = $vars['paging']-(ceil($maxpage/2)-1);
$limit = $curr+ceil($maxpage/2)-1;
// echo "more maxpage";
}else{
$p = $vars['paging']-(ceil($maxpage/2)-1);
$limit = $curr + floor($maxpage/2);
... | Base | 1 |
public function save()
{
$project = $this->getProject();
$values = $this->request->getValues();
list($valid, $errors) = $this->categoryValidator->validateCreation($values);
if ($valid) {
if ($this->categoryModel->create($values) !== false) {
$this->f... | Base | 1 |
public function Recipient($to) {
$this->error = null; // so no confusion is caused
if(!$this->connected()) {
$this->error = array(
"error" => "Called Recipient() without being connected");
return false;
}
fputs($this->smtp_conn,"RCPT TO:<" . $to . ">" . $this->CRLF);
$... | Class | 2 |
public function withPort($port)
{
$port = $this->filterPort($this->scheme, $this->host, $port);
if ($this->port === $port) {
return $this;
}
$new = clone $this;
$new->port = $port;
return $new;
} | Base | 1 |
function __construct()
{
# code...
self::$smtphost = Options::get('smtphost');
self::$smtpuser = Options::get('smtpuser');
self::$smtppass = Options::get('smtppass');
self::$smtpssl = Options::get('smtpssl');
self::$siteemail = Options::get('siteema... | Base | 1 |
public function save()
{
if(!empty($this->id))
return $this->update();
else
return $this->insert();
}
| Base | 1 |
function move_standalone() {
expSession::clearAllUsersSessionCache('navigation');
assign_to_template(array(
'parent' => $this->params['parent'],
));
}
| Base | 1 |
protected function getSubtask()
{
$subtask = $this->subtaskModel->getById($this->request->getIntegerParam('subtask_id'));
if (empty($subtask)) {
throw new PageNotFoundException();
}
return $subtask;
} | Base | 1 |
static public function customerHasTickets($_cid = 0) {
if ($_cid != 0) {
$result_stmt = Database::prepare("
SELECT `id` FROM `" . TABLE_PANEL_TICKETS . "` WHERE `customerid` = :cid"
);
Database::pexecute($result_stmt, array('cid' => $_cid));
$tickets = array();
while ($row = $result_stmt->fetch(... | Class | 2 |
public function save()
{
$project = $this->getProject();
$values = $this->request->getValues();
list($valid, $errors) = $this->categoryValidator->validateCreation($values);
if ($valid) {
if ($this->categoryModel->create($values) !== false) {
$this->f... | Base | 1 |
public function approve_toggle() {
global $history;
if (empty($this->params['id'])) return;
/* The global constants can be overriden by passing appropriate params */
//sure wish I could do this once in the constructor. sadly $this->params[] isn't set yet
$r... | Base | 1 |
$src = substr($ref->source, strlen($prefix)) . $section->id;
if (call_user_func(array($ref->module, 'hasContent'))) {
$oloc = expCore::makeLocation($ref->module, $ref->source);
$nloc = expCore::makeLocation($ref->module, $src);
if ($ref->module... | Base | 1 |
public function remove()
{
$this->checkCSRFParam();
$project = $this->getProject();
$filter = $this->customFilterModel->getById($this->request->getIntegerParam('filter_id'));
$this->checkPermission($project, $filter);
if ($this->customFilterModel->remove($filter['id']))... | Class | 2 |
public function breadcrumb() {
global $sectionObj;
expHistory::set('viewable', $this->params);
$id = $sectionObj->id;
$current = null;
// Show not only the location of a page in the hierarchy but also the location of a standalone page
$current = new secti... | Base | 1 |
public static function setTransactionPart(Db $zdb, $trans_id, $contrib_id)
{
try {
$update = $zdb->update(self::TABLE);
$update->set(
array(Transaction::PK => $trans_id)
)->where(self::PK . ' = ' . $contrib_id);
$zdb->execute($update);
... | Base | 1 |
public function delete() {
global $db;
/* The global constants can be overriden by passing appropriate params */
//sure wish I could do this once in the constructor. sadly $this->params[] isn't set yet
// $require_login = empty($this->params['require_login']) ? COMMENTS_REQUIRE_LO... | Base | 1 |
function update_option_master() {
global $db;
$id = empty($this->params['id']) ? null : $this->params['id'];
$opt = new option_master($id);
$oldtitle = $opt->title;
$opt->update($this->params);
// if the title of the master changed we should... | Base | 1 |
public function read($source) {
$source = $this->escapePath($source);
// close the single quote, open a double quote where we put the single quote...
$source = str_replace('\'', '\'"\'"\'', $source);
// since returned stream is closed by the caller we need to create a new instance
// since we can't re-use th... | Base | 1 |
$dplArg = $this->wgRequest->getVal( $arg, '' );
if ( $dplArg == '' ) {
$input = preg_replace( '/\{%' . $arg . ':(.*)%\}/U', '\1', $input );
$input = str_replace( '{%' . $arg . '%}', '', $input );
} else {
$input = preg_replace( '/\{%' . $arg . ':.*%\}/U ', $dplArg, $input );
$input = str_repla... | Class | 2 |
$resultItem['qtip'] = $item->getDescription() ? $item->getDescription() : ' ';
$result[] = $resultItem;
}
return $this->adminJson($result);
} | Base | 1 |
public function enqueue_scripts() {
global $geo_mashup_options, $pagenow, $post;
// The location editor works only on posts
if ( empty( $post ) )
return null;
$load_location_editor = (
is_admin() and
preg_match( '/(post|page)(-new|).php/', $pagenow ) and
in_array( $post->post_type, $... | Class | 2 |
function fm_get_size($file)
{
static $iswin;
static $isdarwin;
if (!isset($iswin)) {
$iswin = (strtoupper(substr(PHP_OS, 0, 3)) == 'WIN');
}
if (!isset($isdarwin)) {
$isdarwin = (strtoupper(substr(PHP_OS, 0)) == "DARWIN");
}
static $exec_works;
if (!isset($exec_works)) ... | Base | 1 |
public static function go($input, $path, $allowed='', $uniq=false, $size='', $width = '', $height = ''){
$filename = Typo::cleanX($_FILES[$input]['name']);
$filename = str_replace(' ', '_', $filename);
if(isset($_FILES[$input]) && $_FILES[$input]['error'] == 0){
if($uniq == true)... | Compound | 4 |
$this->paths[substr($key, strlen('path-'))] = $value;
}
| Base | 1 |
public function getList($location, $features, $etag, $mediatypes) {
$featuresArray = explode(';', $features);
$mediaTypesArray = explode(';', $mediatypes);
try {
return $this->getFilesAndAlbums($location, $featuresArray, $etag, $mediaTypesArray);
} catch (\Exception $exception) {
return $this->jsonError(... | Base | 1 |
public function remove()
{
$project = $this->getProject();
$this->checkCSRFParam();
$column_id = $this->request->getIntegerParam('column_id');
if ($this->columnModel->remove($column_id)) {
$this->flash->success(t('Column removed successfully.'));
} else {
... | Base | 1 |
public static function ajax ($vars="", $val='') {
if( isset($vars) && $vars != "" ) {
$file = GX_PATH.'/inc/lib/Control/Ajax/'.$vars.'-ajax.control.php';
if (file_exists($file)) {
include($file);
}else {
self::error('404');
... | Base | 1 |
function edit_externalalias() {
$section = isset($this->params['id']) ? $this->section->find($this->params['id']) : new section($this->params);
if ($section->parent == -1) {
notfoundController::handle_not_found();
exit;
} // doesn't work for standalone pages
... | Base | 1 |
public function confirm()
{
$task = $this->getTask();
$comment = $this->getComment();
$this->response->html($this->template->render('comment/remove', array(
'comment' => $comment,
'task' => $task,
'title' => t('Remove a comment')
)));
} | Class | 2 |
$method = $this->request->get('_method', $this->query->get('_method', 'POST'));
if (\is_string($method)) {
$this->method = strtoupper($method);
}
}
}
} | Base | 1 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.