Changeset 1184 in ExiteCMS
- Timestamp:
- 12/31/07 13:01:02 (4 years ago)
- Location:
- trunk
- Files:
-
- 4 edited
-
administration/tools/language_pack_English.php (modified) (2 diffs)
-
files/locales/en.main.global.php (modified) (1 diff)
-
includes/comments_include.php (modified) (4 diffs)
-
includes/templates/include.comments.tpl (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/administration/tools/language_pack_English.php
r1182 r1184 2315 2315 $localestrings['c101'] = "No Comments have been Posted."; 2316 2316 $localestrings['c102'] = "Post Comment"; 2317 $localestrings['c103'] = " Name:";2317 $localestrings['c103'] = "Your Name:"; 2318 2318 $localestrings['c104'] = "Message:"; 2319 2319 $localestrings['c105'] = "Please Login to Post a Comment."; … … 2321 2321 $localestrings['c107'] = " Disable smileys in this comment"; 2322 2322 $localestrings['c108'] = "Toggle smileys"; 2323 $localestrings['c110'] = "Incorrect Validation Code"; 2324 $localestrings['c111'] = "The validation code below must be entered, it expires 15 minutes after page generation."; 2325 $localestrings['c112'] = "Validation Code:"; 2326 $localestrings['c113'] = "Enter Validation Code:"; 2323 2327 load_localestrings($localestrings, LP_LOCALE, "main.comments", $step); 2324 2328 -
trunk/files/locales/en.main.global.php
r1182 r1184 3 3 // locale : English 4 4 // locale name : main.global 5 // generated on : Tue Dec 25 2007, 15:30:41CET5 // generated on : Mon Dec 31 2007, 12:03:00 CET 6 6 // translators : ExiteCMS team,WanWizard 7 7 // ---------------------------------------------------------- -
trunk/includes/comments_include.php
r1071 r1184 25 25 26 26 $variables = array(); 27 27 28 28 if ((iMEMBER || $settings['guestposts'] == "1") && isset($_POST['post_comment'])) { 29 30 $result = dbquery("DELETE FROM ".$db_prefix."captcha WHERE captcha_datestamp<'".(time()-900)."'"); 31 29 32 $flood = false; 30 33 if (dbrows(dbquery("SELECT $ccol FROM ".$db_prefix."$cdb WHERE $ccol='$comment_id'"))==0) { … … 38 41 if (isNum($comment_name)) $comment_name=""; 39 42 } 43 44 // captcha check for guest posts 45 $cic = (iGUEST && !check_captcha($_POST['captcha_encode'], $_POST['captcha_code'])) ? "&cic=1" : ""; 46 40 47 $comment_message = trim(stripinput(censorwords($_POST['comment_message']))); 41 48 $comment_smileys = isset($_POST['disable_smileys']) ? "0" : "1"; 42 if ($comment_name != "" && $comment_message != "" ) {49 if ($comment_name != "" && $comment_message != "" && $cic == "") { 43 50 $result = dbquery("SELECT MAX(comment_datestamp) AS last_comment FROM ".$db_prefix."comments WHERE comment_ip='".USER_IP."'"); 44 51 if (!iSUPERADMIN || dbrows($result) > 0) { … … 54 61 if (!$flood) $result = dbquery("INSERT INTO ".$db_prefix."comments (comment_item_id, comment_type, comment_name, comment_message, comment_smileys, comment_datestamp, comment_ip) VALUES ('$comment_id', '$comment_type', '$comment_name', '$comment_message', '$comment_smileys', '".time()."', '".USER_IP."')"); 55 62 } 56 redirect($clink);63 if ($cic != "") redirect($clink.$cic); 57 64 } 58 65 … … 77 84 $variables['comment_id'] = $comment_id; 78 85 $variables['post_link'] = $clink; 86 $variables['cic'] = (isset($_GET['cic']) && !empty($_GET['cic'])) ? $_GET['cic'] : ""; 79 87 80 88 // define the body panel variables -
trunk/includes/templates/include.comments.tpl
r893 r1184 24 24 <td class='tbl2'> 25 25 <b> 26 {if $smarty.const.iMEMBER && $comments[item].user_name |default:false}26 {if $smarty.const.iMEMBER && $comments[item].user_name != ""} 27 27 <a href='{$smarty.const.BASEDIR}profile.php?lookup={$comments[item].comment_name}'>{$comments[item].user_name}</a> 28 28 {else} 29 {$comments[item]. user_name}29 {$comments[item].comment_name} 30 30 {/if} 31 31 </b> … … 59 59 {if $smarty.const.iGUEST} 60 60 <tr> 61 <td> 62 {$locale.c103} 63 </td> 64 </tr> 65 <tr> 66 <td> 67 <input type='text' name='comment_name' maxlength='30' class='textbox' style='width:100%;' /> 61 <td colspan='2' align='center'> 62 {$locale.c103} <input type='text' name='comment_name' maxlength='30' class='textbox' style='width:200px;' /> 63 <span style='color:#CC0000;font-weight:bold;'>*</span> 64 <br /><br /> 68 65 </td> 69 66 </tr> 70 67 {/if} 71 68 <tr> 72 <td align='center'>69 <td colspan='2' align='center'> 73 70 <textarea name='comment_message' rows='6' cols='80' class='textbox' style='width:400px'></textarea><br /> 74 71 <input type='button' value='b' class='button' style='font-weight:bold;width:25px;' onclick="addText('comment_message', '[b]', '[/b]');" /> … … 87 84 </tr> 88 85 <tr> 89 <td align='center'>90 <input type='submit' name='toggle' value='{$locale.c108}' class='button' onclick='javascript:flipDiv("smileys");return false;' /> <br /><br />86 <td colspan=2' align='center'> 87 <input type='submit' name='toggle' value='{$locale.c108}' class='button' onclick='javascript:flipDiv("smileys");return false;' /> 91 88 <input type='checkbox' name='disable_smileys' value='1' />{$locale.c107}<br /><br /> 89 </td> 90 </tr> 91 {if $smarty.const.iGUEST} 92 {if $cic != ""} 93 <tr> 94 <td colspan='2' align='center'> 95 <span style='color:#CC0000;font-weight:bold;'>{$locale.c110}<br /><br /></span> 96 </td> 97 </tr> 98 {/if} 99 <tr> 100 <td colspan='2' class='tbl2'> 101 {$locale.c111} 102 </td> 103 </tr> 104 <tr> 105 <td align='right' width='50%' class='tbl1'> 106 {$locale.c112} 107 </td> 108 <td align='left' width='50%' class='tbl1'> 109 {make_captcha} 110 </td> 111 </tr> 112 <tr> 113 <td align='right' width='50%' class='tbl1'> 114 {$locale.c113} 115 </td> 116 <td align='left' width='50%' class='tbl1'> 117 <input type='text' name='captcha_code' class='textbox' style='vertical-align:middle;width:100px' /> 118 </td> 119 </tr> 120 <tr> 121 <td colspan='2' class='tbl1'> 122 123 </td> 124 </tr> 125 {/if} 126 <tr> 127 <td colspan=2' align='center'> 92 128 <input type='submit' name='post_comment' value='{$locale.c102}' class='button' /> 93 129 </td>
Note: See TracChangeset
for help on using the changeset viewer.
