This file contains hidden or 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
| <!-- for The DP --> | |
| <script src="https://www.thedp.com/b/img.js" type="text/javascript"></script> | |
| <!-- for 34th Street --> | |
| <script src="https://www.34st.com/b/img.js" type="text/javascript"></script> | |
| <!-- for UTB --> | |
| <script src="https://www.underthebutton.com/b/img.js" type="text/javascript"></script> |
This file contains hidden or 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
| (* I use the Gray flag to note messages that that may need to be responded | |
| or at least messages that have been forwarded to Todoist. Put your inbox address | |
| in and your archive mailbox (it's probably just "Archive") and you're good to go. | |
| Then you can create a smart mailbox for archived, Gray flagged messages to see what | |
| needs to be responded to after completing the task *) | |
| tell application "Mail" | |
| set inboxAddress to "" | |
| set archiveMailbox to "" |
This file contains hidden or 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
| document.write('hello world!'); |
This file contains hidden or 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() { | |
| alert('I just ran!'); | |
| }); |
This file contains hidden or 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
| <script type="text/javascript"> | |
| (function($) { | |
| $(function() { | |
| alert('I just ran!'); | |
| }); | |
| })(jQuery); | |
| </script> |
This file contains hidden or 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 | |
| // start the output buffer | |
| ob_start(); | |
| // dump the more complex var | |
| var_dump($some_var); | |
| // get the buffer contents and clear it so it doesn't output anything | |
| $output = ob_get_contents(); |
This file contains hidden or 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 | |
| // Get the debug output of $some_var | |
| $output = var_export($some_var, true); | |
| // Log it as an info log. More levels: http://www.php-fig.org/psr/psr-3/#5-psr-log-loglevel | |
| Craft::Log($output, LogLevel::INFO); |
This file contains hidden or 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 | |
| /** | |
| * Run commands | |
| * | |
| * Drop this file into: | |
| * /path/to/plugins/craftimport/consolecommands/CraftImportCommand.php | |
| * | |
| * Easily run the import command from the crontab: | |
| * | |
| * sudo -u www-data php /path/to/craft/app/etc/console/yiic craftimport import |
This file contains hidden or 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 | |
| public function getSubjects() | |
| { | |
| $criteria = new \CDbCriteria(); | |
| $criteria->condition = 'ims_groups_subjects.group_uid = :gid'; | |
| $criteria->params = array(':gid' => $this->getAttribute('group_uid')); | |
| $criteria->join = 'left join ims_groups_subjects on ims_groups_subjects.subject_uid = t.subject_uid ' ; | |
| $criteria->order = "ims_subjects.subject"; | |
| return CollabCentre_SubjectRecord::model()->findAll($criteria); |
This file contains hidden or 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 | |
| $str1 = 'этёам фюйзчыт'; | |
| $str2 = 'تكبّد العالمية'; | |
| $str3 = '手真リひ通西加ワ'; | |
| echo str_replace(' ', '_', strtolower($str1)).'<br />'; | |
| echo str_replace(' ', '_', strtolower($str2)).'<br />'; | |
| echo str_replace(' ', '_', strtolower($str3)); |
NewerOlder