Revision 942
Added by doc over 15 years ago
uninstall.php | ||
---|---|---|
72 | 72 |
|
73 | 73 |
/** |
74 | 74 |
* Check if the template is still in use by a page ... |
75 |
* |
|
76 |
* @version 0.2.0 |
|
77 |
* @build 5 |
|
78 |
* @author aldus |
|
79 |
* @since 0.1.0 |
|
80 |
* @lastchange 2008-10-23 |
|
81 |
* |
|
82 | 75 |
*/ |
83 | 76 |
$info = $database->query("SELECT page_id, page_title FROM ".TABLE_PREFIX."pages WHERE template='".$file."' order by page_title"); |
84 | 77 |
|
85 | 78 |
if ($info->numRows() > 0) { |
86 |
|
|
87 | 79 |
/** |
88 | 80 |
* Template is still in use, so we're collecting the page-titles |
89 |
* |
|
90 |
* @version 0.2.0 |
|
91 |
* @build 5 |
|
92 |
* @since 0.1.1 |
|
93 |
* @lastchange 2008-10-23 |
|
94 |
* |
|
95 |
* 0.2.0 Codechanges for Websitebaker to use it without the Black-Hawk-Engine |
|
96 |
* |
|
97 |
* 0.1.1 add this page <if we found only one> / these pages |
|
98 |
* |
|
99 |
* @notice All listed pages got linked to "settings.php" so the user can easy change |
|
100 |
* the template-settings. Modifications could be made in "page_template_str". |
|
101 |
* For additional informations you will have to modify the query, the page_template_str |
|
102 |
* and the page_info array. |
|
103 |
* |
|
104 |
* @todo 1 - Additional informations about the pages (modified, modified_by, visibility, etc) |
|
105 |
* |
|
106 |
* 2 - What happends about pages, the user is not allowed to edit? |
|
107 |
* Marked "red"? |
|
108 |
* |
|
109 |
* 3 - Multiple language support here ... |
|
110 | 81 |
*/ |
111 | 82 |
|
112 | 83 |
/** |
113 | 84 |
* The base-message template-string for the top of the message |
114 |
* |
|
115 |
* 0.1.2 this page/ these pages |
|
116 |
* |
|
117 | 85 |
*/ |
118 | 86 |
if (!array_key_exists("CANNOT_UNINSTALL_IN_USE_TMPL", $MESSAGE['GENERIC'])) { |
119 | 87 |
$add = $info->numRows() == 1 ? "this page" : "these pages"; |
Also available in: Unified diff
fixed wrong index in language array and removed some comment lines