foreach (postRequestElement('sel') as $id => $sel) {
// Load module data
// @TODO This can be moved into mysql-function.php, see checkModulePermissions() function
- $result = sqlQueryEscaped("SELECT `id`, `module`, `title`, `locked`, `hidden`, `admin_only`, `mem_only` FROM `{?_MYSQL_PREFIX?}_mod_reg` WHERE `id`=%s LIMIT 1",
+ $result = sqlQueryEscaped('SELECT
+ `id`,
+ `module`,
+ `title`,
+ `locked`,
+ `admin_only`,
+ `mem_only`
+FROM
+ `{?_MYSQL_PREFIX?}_mod_reg`
+WHERE
+ `id`=%s
+LIMIT 1',
array(bigintval($id)), __FILE__, __LINE__);
// Load data
// Prepare array for the template
$content['locked'] = addSelectionBox('yn', $content['locked'] , 'locked', $id);
- $content['hidden'] = addSelectionBox('yn', $content['hidden'] , 'hidden', $id);
$content['admin_only'] = addSelectionBox('yn', $content['admin_only'], 'admin' , $id);
$content['mem_only'] = addSelectionBox('yn', $content['mem_only'] , 'member', $id);
SET
`title`='%s',
`locked`='%s',
- `hidden`='%s',
`admin_only`='%s',
`mem_only`='%s'
WHERE
array(
postRequestElement('title', $id),
postRequestElement('locked', $id),
- postRequestElement('hidden', $id),
postRequestElement('admin', $id),
postRequestElement('member', $id),
$id
if (!ifPostContainsSelections()) {
// Load module data (We do not need to check if there's at least one...)
$result = sqlQuery('SELECT
- `id`, `module`, `locked`, `hidden`, `admin_only`, `title`, `mem_only`
+ `id`,
+ `module`,
+ `locked`,
+ `admin_only`,
+ `title`,
+ `mem_only`
FROM
`{?_MYSQL_PREFIX?}_mod_reg`
ORDER BY