This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php if( ! empty($feed)): ?> | |
<?php foreach ($feed as $row):?> | |
<?php if ($row->content_category == 'news') { ?> | |
<li class="news"> | |
<a class="title" href="<?php echo site_url('news') . '/' . $row->content_id . '/' . $row->content_url; ?>"><h2><?php echo $row->content_title; ?></h2></a> | |
<p class="created">News from <a href="<?php echo creator($row->content_parent, 'url'); ?>"><?php echo creator($row->content_parent, 'title'); ?></a></p> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function mywild($userid = '', $offset = 0) | |
{ | |
/* find favourites for this user */ | |
$rels = $this->db->select('rel_parent')->where('rel_child', $userid)->where('rel_type', 'favourite')->from('content_relationships')->get(); | |
print_r($rels); | |
if ($rels->num_rows() > 0) { | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT * | |
FROM `content` | |
WHERE (content_finish >= '2011-05-17 23:00:00' OR content_finish IS NULL) | |
AND `content_status` = 'published' | |
AND `content_parent` IN ('17', '38', '54', '10', '34', '66', '68', '67', '76', '77', '75', '79', '86', '79', '18') | |
ORDER BY `content_updated` desc |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$sql = "SELECT * | |
FROM `content` | |
WHERE (content_finish >= " . $now . " OR content_finish IS NULL) | |
AND `content_status` = 'published' | |
AND `content_parent` IN (" . $content_ids . ") | |
ORDER BY `content_updated` desc"; | |
$this->db->query($sql); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$rels = $this->db->select('rel_parent')->where('rel_child', $userid)->where('rel_type', 'favourite')->from('content_relationships')->get(); | |
foreach ($rels->result_array() as $row) | |
{ | |
$content_ids[] = $row['rel_parent']; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$rels = $this->db->select('rel_parent')->where('rel_child', $userid)->where('rel_type', 'favourite')->from('content_relationships')->get(); | |
$content_ids = ''; | |
$i = 0; | |
foreach ($rels->result_array() as $row) | |
{ | |
if($rels->num_rows() === $i) | |
{ | |
$content_ids .= $row['rel_parent']; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$data = array( | |
'first_name' => $this->form_validation->error('first_name'), | |
'last_name' => $this->form_validation->error('last_name'), | |
'country' => $this->form_validation->error('country'), | |
'region' => $this->form_validation->error('region'), | |
'email' => $this->form_validation->error('email'), | |
'email_confirm' => $this->form_validation->error('email_confirm'), | |
'dob_day' => $this->form_validation->error('dob_day'), | |
'dob_month' => $this->form_validation->error('dob_month'), |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$less-column-width: 68px; | |
$less-gutter-width: 24px; | |
@function column-width($columns) { | |
@return ($less-column-width * $columns) + ($less-gutter-width * ($columns - 1)); | |
} | |
@function grid-padding-px($columns) { | |
@if $columns == 10 { | |
@return 48px; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$mailto = (isset($mailto)) ? $mailto : '@@ DEFAULT EMAIL HERE @@'; | |
$warningMail = '@@ EMAIL TO SEND WARNING TO IN CASE OF A SMALL BACKUP FILE @@'; | |
include MODX_CORE_PATH.'/config/'.MODX_CONFIG_KEY.'.inc.php'; | |
$host = $database_server; // database host | |
$dbuser = $database_user; // database user name | |
$dbpswd = $database_password; // database password | |
$mysqldb = $dbase; // name of database |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php die('This file is not really here!'); | |
/** | |
* ------------- DO NOT UPLOAD THIS FILE TO LIVE SERVER --------------------- | |
* | |
* Implements code completion for CodeIgniter in phpStorm | |
* phpStorm indexes all class constructs, so if this file is in the project it will be loaded. | |
* ------------------------------------------------------------------- | |
* Drop the following file into a CI project in phpStorm | |
* You can put it in the project root and phpStorm will load it. |
OlderNewer