Revision 1457
Added by Dietmar over 13 years ago
add.php | ||
---|---|---|
1 |
<?php |
|
2 |
/** |
|
3 |
* |
|
4 |
* @category modules |
|
5 |
* @package news |
|
6 |
* @author WebsiteBaker Project |
|
7 |
* @copyright 2004-2009, Ryan Djurovich |
|
8 |
* @copyright 2009-2011, Website Baker Org. e.V. |
|
9 |
* @link http://www.websitebaker2.org/ |
|
10 |
* @license http://www.gnu.org/licenses/gpl.html |
|
11 |
* @platform WebsiteBaker 2.8.x |
|
12 |
* @requirements PHP 5.2.2 and higher |
|
13 |
* @version $Id$ |
|
14 |
* @filesource $HeadURL$ |
|
15 |
* @lastmodified $Date$ |
|
16 |
* |
|
17 |
*/ |
|
18 |
|
|
19 |
// Must include code to stop this file being access directly |
|
20 |
if(defined('WB_PATH') == false) { exit("Cannot access this file directly"); } |
|
21 |
|
|
22 |
$header = '<table cellpadding=\"0\" cellspacing=\"0\" class=\"loop-header\">'."\n"; |
|
23 |
$post_loop = '<tr class=\"post-top\"> |
|
24 |
<td class=\"post-title\"><a href=\"[LINK]\">[TITLE]</a></td> |
|
25 |
<td class=\"post-date\">[PUBLISHED_DATE], [PUBLISHED_TIME]</td> |
|
26 |
</tr> |
|
27 |
<tr> |
|
28 |
<td class=\"post-short\" colspan=\"2\"> |
|
29 |
[SHORT] |
|
30 |
<span style=\"visibility:[SHOW_READ_MORE];\"><a href=\"[LINK]\">[TEXT_READ_MORE]</a></span> |
|
31 |
</td> |
|
32 |
</tr>'; |
|
33 |
$footer = '</table> |
|
34 |
<table cellpadding="0" cellspacing="0" class="page-header" style="display: [DISPLAY_PREVIOUS_NEXT_LINKS]"> |
|
35 |
<tr> |
|
36 |
<td class="page-left">[PREVIOUS_PAGE_LINK]</td> |
|
37 |
<td class="page-center">[OF]</td> |
|
38 |
<td class="page-right">[NEXT_PAGE_LINK]</td> |
|
39 |
</tr> |
|
40 |
</table>'; |
|
41 |
$post_header = addslashes('<table cellpadding="0" cellspacing="0" class="post-header"> |
|
42 |
<tr> |
|
43 |
<td><h1>[TITLE]</h1></td> |
|
44 |
<td rowspan="3" style="display: [DISPLAY_IMAGE]">[GROUP_IMAGE]</td> |
|
45 |
</tr> |
|
46 |
<tr> |
|
47 |
<td class="public-info"><b>[TEXT_POSTED_BY] [DISPLAY_NAME] ([USERNAME]) [TEXT_ON] [PUBLISHED_DATE]</b></td> |
|
48 |
</tr> |
|
49 |
<tr style="display: [DISPLAY_GROUP]"> |
|
50 |
<td class="group-page"><a href="[BACK]">[PAGE_TITLE]</a> >> <a href="[BACK]?g=[GROUP_ID]">[GROUP_TITLE]</a></td> |
|
51 |
</tr> |
|
52 |
</table>'); |
|
53 |
$post_footer = '<p>[TEXT_LAST_CHANGED]: [MODI_DATE] [TEXT_AT] [MODI_TIME]</p> |
|
54 |
<a href=\"[BACK]\">[TEXT_BACK]</a>'; |
|
55 |
$comments_header = addslashes('<br /><br /> |
|
56 |
<h2>[TEXT_COMMENTS]</h2> |
|
57 |
<table cellpadding="2" cellspacing="0" class="comment-header">'); |
|
58 |
$comments_loop = addslashes('<tr> |
|
59 |
<td class="comment_title">[TITLE]</td> |
|
60 |
<td class="comment_info">[TEXT_BY] [DISPLAY_NAME] [TEXT_ON] [DATE] [TEXT_AT] [TIME]</td> |
|
61 |
</tr> |
|
62 |
<tr> |
|
63 |
<td colspan="2" class="comment-text">[COMMENT]</td> |
|
64 |
</tr>'); |
|
65 |
$comments_footer = '</table> |
|
66 |
<br /><a href=\"[ADD_COMMENT_URL]\">[TEXT_ADD_COMMENT]</a>'; |
|
67 |
$comments_page = '<h1>[TEXT_COMMENT]</h1> |
|
68 |
<h2>[POST_TITLE]</h2> |
|
69 |
<br />'; |
|
70 |
$commenting = 'none'; |
|
71 |
$use_captcha = true; |
|
72 |
|
|
73 |
$database->query("INSERT INTO ".TABLE_PREFIX."mod_news_settings (section_id,page_id,header,post_loop,footer,post_header,post_footer,comments_header,comments_loop,comments_footer,comments_page,commenting,use_captcha) VALUES ('$section_id','$page_id','$header','$post_loop','$footer','$post_header','$post_footer','$comments_header','$comments_loop','$comments_footer','$comments_page','$commenting','$use_captcha')"); |
|
74 |
|
|
75 |
?> |
|
1 |
<?php |
|
2 |
/** |
|
3 |
* |
|
4 |
* @category modules |
|
5 |
* @package news |
|
6 |
* @author WebsiteBaker Project |
|
7 |
* @copyright 2004-2009, Ryan Djurovich |
|
8 |
* @copyright 2009-2011, Website Baker Org. e.V. |
|
9 |
* @link http://www.websitebaker2.org/ |
|
10 |
* @license http://www.gnu.org/licenses/gpl.html |
|
11 |
* @platform WebsiteBaker 2.8.x |
|
12 |
* @requirements PHP 5.2.2 and higher |
|
13 |
* @version $Id$ |
|
14 |
* @filesource $HeadURL$ |
|
15 |
* @lastmodified $Date$ |
|
16 |
* |
|
17 |
*/ |
|
18 |
|
|
19 |
// Must include code to stop this file being access directly |
|
20 |
if(defined('WB_PATH') == false) { exit("Cannot access this file directly"); } |
|
21 |
|
|
22 |
$header = '<table cellpadding=\"0\" cellspacing=\"0\" class=\"loop-header\">'."\n"; |
|
23 |
$post_loop = '<tr class=\"post-top\"> |
|
24 |
<td class=\"post-title\"><a href=\"[LINK]\">[TITLE]</a></td> |
|
25 |
<td class=\"post-date\">[PUBLISHED_DATE], [PUBLISHED_TIME]</td> |
|
26 |
</tr> |
|
27 |
<tr> |
|
28 |
<td class=\"post-short\" colspan=\"2\"> |
|
29 |
[SHORT] |
|
30 |
<span style=\"visibility:[SHOW_READ_MORE];\"><a href=\"[LINK]\">[TEXT_READ_MORE]</a></span> |
|
31 |
</td> |
|
32 |
</tr>'; |
|
33 |
$footer = '</table> |
|
34 |
<table cellpadding="0" cellspacing="0" class="page-header" style="display: [DISPLAY_PREVIOUS_NEXT_LINKS]"> |
|
35 |
<tr> |
|
36 |
<td class="page-left">[PREVIOUS_PAGE_LINK]</td> |
|
37 |
<td class="page-center">[OF]</td> |
|
38 |
<td class="page-right">[NEXT_PAGE_LINK]</td> |
|
39 |
</tr> |
|
40 |
</table>'; |
|
41 |
$post_header = addslashes('<table cellpadding="0" cellspacing="0" class="post-header"> |
|
42 |
<tr> |
|
43 |
<td><h1>[TITLE]</h1></td> |
|
44 |
<td rowspan="3" style="display: [DISPLAY_IMAGE]">[GROUP_IMAGE]</td> |
|
45 |
</tr> |
|
46 |
<tr> |
|
47 |
<td class="public-info"><b>[TEXT_POSTED_BY] [DISPLAY_NAME] ([USERNAME]) [TEXT_ON] [PUBLISHED_DATE]</b></td> |
|
48 |
</tr> |
|
49 |
<tr style="display: [DISPLAY_GROUP]"> |
|
50 |
<td class="group-page"><a href="[BACK]">[PAGE_TITLE]</a> >> <a href="[BACK]?g=[GROUP_ID]">[GROUP_TITLE]</a></td> |
|
51 |
</tr> |
|
52 |
</table>'); |
|
53 |
$post_footer = '<p>[TEXT_LAST_CHANGED]: [MODI_DATE] [TEXT_AT] [MODI_TIME]</p> |
|
54 |
<a href=\"[BACK]\">[TEXT_BACK]</a>'; |
|
55 |
$comments_header = addslashes('<br /><br /> |
|
56 |
<h2>[TEXT_COMMENTS]</h2> |
|
57 |
<table cellpadding="2" cellspacing="0" class="comment-header">'); |
|
58 |
$comments_loop = addslashes('<tr> |
|
59 |
<td class="comment_title">[TITLE]</td> |
|
60 |
<td class="comment_info">[TEXT_BY] [DISPLAY_NAME] [TEXT_ON] [DATE] [TEXT_AT] [TIME]</td> |
|
61 |
</tr> |
|
62 |
<tr> |
|
63 |
<td colspan="2" class="comment-text">[COMMENT]</td> |
|
64 |
</tr>'); |
|
65 |
$comments_footer = '</table> |
|
66 |
<br /><a href=\"[ADD_COMMENT_URL]\">[TEXT_ADD_COMMENT]</a>'; |
|
67 |
$comments_page = '<h1>[TEXT_COMMENT]</h1> |
|
68 |
<h2>[POST_TITLE]</h2> |
|
69 |
<br />'; |
|
70 |
$commenting = 'none'; |
|
71 |
$use_captcha = true; |
|
72 |
|
|
73 |
$database->query("INSERT INTO ".TABLE_PREFIX."mod_news_settings (section_id,page_id,header,post_loop,footer,post_header,post_footer,comments_header,comments_loop,comments_footer,comments_page,commenting,use_captcha) VALUES ('$section_id','$page_id','$header','$post_loop','$footer','$post_header','$post_footer','$comments_header','$comments_loop','$comments_footer','$comments_page','$commenting','$use_captcha')"); |
|
76 | 74 |
Also available in: Unified diff
Preparing 2.8.2 stable, last tests