tagging as ATutor 1.5.4-release
[atutor.git] / include / html / code_picker.inc.php
1 <?php
2 /****************************************************************/
3 /* ATutor                                                                                                               */
4 /****************************************************************/
5 /* Copyright (c) 2002-2006 by Greg Gay & Joel Kronenberg        */
6 /* Adaptive Technology Resource Centre / University of Toronto  */
7 /* http://atutor.ca                                                                                             */
8 /*                                                              */
9 /* This program is free software. You can redistribute it and/or*/
10 /* modify it under the terms of the GNU General Public License  */
11 /* as published by the Free Software Foundation.                                */
12 /****************************************************************/
13 if (!defined('AT_INCLUDE_PATH')) { exit; }
14
15 ?>
16 <table border="0" cellspacing="0" cellpadding="0" width="100%">
17 <tr>
18         <td colspan="2"><small><?php echo _AT('click_code'); ?></small></td>
19 </tr>
20 <tr>
21         <td align="right"><small><b><?php echo _AT('emoticons'); ?>:</b></small></td>
22         <td><small><?php
23                 echo '<a href="javascript:smilie(\':)\')" title=":)">'.smile_replace(':)').'</a> ';
24                 echo '<a href="javascript:smilie(\';)\')" title=";)">'.smile_replace(';)').'</a> ';
25                 echo '<a href="javascript:smilie(\':(\')" title=":(">'.smile_replace(':(').'</a> ';
26                 echo '<a href="javascript:smilie(\'::ohwell::\')" title=":\\">'.smile_replace('::ohwell::').'</a> ';
27
28                 echo '<a href="javascript:smilie(\':P\')" title=":P">'.smile_replace(':P').'</a> ';
29                 echo '<a href="javascript:smilie(\'::angry::\')" title="::angry::">'.smile_replace('::angry::').'</a> ';
30
31                 echo '<a href="javascript:smilie(\'::evil::\')" title="::evil::">'.smile_replace('::evil::').'</a> ';
32                 echo '<a href="javascript:smilie(\'::lol::\')" title="::lol::">'.smile_replace('::lol::').'</a> ';
33                 echo '<a href="javascript:smilie(\'::confused::\')" title="::confused::">'.smile_replace('::confused::').'</a> ';
34                 echo '<a href="javascript:smilie(\'::crazy::\')" title="::crazy::">'.smile_replace('::crazy::').'</a> ';
35
36                 echo '<a href="javascript:smilie(\'::tired::\')" title="::tired::">'.smile_replace('::tired::').'</a> ';
37                 echo '<a href="javascript:smilie(\'::muah::\')" title="::muah::">'.smile_replace('::muah::').'</a>';
38         ?></small></td>
39 </tr>
40 <tr>
41         <td align="right"><small><b><?php echo _AT('codes'); ?>:</b></small></td>
42         <td><small><a href="javascript:smilie('[b] [/b]')" title="[b] [/b]"><?php echo _AT('bold'); ?></a>,
43         <a href="javascript:smilie('[i] [/i]')" title="[i] [/i]"><?php echo _AT('italic'); ?></a>,
44         <a href="javascript:smilie('[u] [/u]')" title="[u] [/u]"><?php echo _AT('underline'); ?></a>,
45         <a href="javascript:smilie('[center] [/center]')" title="[center] [/center]"><?php echo _AT('center'); ?></a>,
46         <a href="javascript:smilie('[quote] [/quote]')" title="[quote] [/quote]"><?php echo _AT('quote'); ?></a>,
47         <a href="javascript:smilie('http://')" title="http://"><?php echo _AT('link'); ?></a>,
48         <a href="javascript:smilie('[image|alt text][/image]')" title="[image|alt text][/image]"><?php echo _AT('image'); ?></a><?php
49         if (isset($current_tab)) {
50                 echo ', <a href="javascript:smilie(\' [?][/?]\')" title="[?][/?]">',_AT('add_term'), '</a>';
51                 echo '<a href="javascript:smilie(\' [code][/code]\')" title="[code][/code]" onclick="document.form.formatting.html.checked=true;">',_AT('add_code'), '</a>';
52         } ?></small></td>
53 </tr>
54 <tr>
55         <td align="right"><small><b><?php echo _AT('colors'); ?>:</b></small></td>
56         <td><table border="0" cellspacing="2" cellpadding="0" summary="">
57         <tr>
58                 <td bgcolor="blue"><a href="javascript:smilie('[blue] [/blue]')" title="[blue] [/blue]"><img src="<?php echo $_base_path; ?>images/clr.gif" alt="<?php echo _AT('blue'); ?>" height="15" width="15" border="0" /></a></td>
59                 <td bgcolor="red"><a href="javascript:smilie('[red] [/red]')" title="[red] [/red]"><img src="<?php echo $_base_path; ?>images/clr.gif" alt="<?php echo _AT('red'); ?>" height="15" width="15" border="0" /></a></td>
60                 <td bgcolor="green"><a href="javascript:smilie('[green] [/green]')" title="[green] [/green]"><img src="<?php echo $_base_path; ?>images/clr.gif" alt="<?php echo _AT('green'); ?>" height="15" width="15" border="0" /></a></td>
61                 <td bgcolor="orange"><a href="javascript:smilie('[orange] [/orange]')" title="[orange] [/orange]"><img src="<?php echo $_base_path; ?>images/clr.gif" alt="<?php echo _AT('orange'); ?>" height="15" width="15" border="0" /></a></td>
62                 <td bgcolor="purple"><a href="javascript:smilie('[purple] [/purple]')" title="[purple] [/purple]"><img src="<?php echo $_base_path; ?>images/clr.gif" alt="<?php echo _AT('purple'); ?>" height="15" width="15" border="0" /></a></td>
63                 <td bgcolor="gray"><a href="javascript:smilie('[gray] [/gray]')" title="[gray] [/gray]"><img src="<?php echo $_base_path; ?>images/clr.gif" alt="<?php echo _AT('gray'); ?>" height="15" width="15" border="0" /></a></td>
64         </tr>
65         </table></td>
66 </tr>
67 </table>
68         <script type="text/javascript">
69         //<!--
70         function smilie(thesmilie) {
71                 // inserts smilie text
72                 document.form.body.value += thesmilie+" ";
73                 document.form.body.focus();
74         }
75
76         //-->
77         </script>