- Replace some mysql_query by pwg_query function.

- Add home button after upgrade.php.
- Add utf8 charset for access denied message.
- Replace some #content by .content in css files.
- Fix menubar blocks borders with IE.

git-svn-id: http://piwigo.org/svn/trunk@2884 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
patdenice 2008-11-19 15:44:04 +00:00
parent 5ed2bf0458
commit 509cfc5547
12 changed files with 21 additions and 13 deletions

View file

@ -124,10 +124,10 @@ UPDATE '.PREFIX_TABLE.'plugins
SET state="inactive" SET state="inactive"
WHERE id IN ("' . implode('","', $plugins) . '") WHERE id IN ("' . implode('","', $plugins) . '")
;'; ;';
mysql_query($query); pwg_query($query);
array_push($page['infos'], array_push($page['infos'],
l10n('deactivated plugins').'<br /><br /><i>'.implode(', ', $plugins).'</i><br />'); l10n('deactivated plugins').'<p><i>'.implode(', ', $plugins).'</i></p>');
} }
} }
@ -159,7 +159,7 @@ ON u.'.$conf['user_fields']['id'].'=ui.user_id
WHERE '.$conf['user_fields']['username'].'="'.$username.'" WHERE '.$conf['user_fields']['username'].'="'.$username.'"
;'; ;';
} }
$row = mysql_fetch_assoc(mysql_query($query)); $row = mysql_fetch_assoc(pwg_query($query));
if (!isset($conf['pass_convert'])) if (!isset($conf['pass_convert']))
{ {

View file

@ -104,6 +104,10 @@ textarea { margin-left: 20px; }
<li>{$info}</li> <li>{$info}</li>
{/foreach} {/foreach}
</ul> </ul>
<form action="index.php" method="post">
<p><input type="submit" name="submit" value="{'home'|@translate}"/></p>
</form>
{/if} {/if}
</div> {* content *} </div> {* content *}

View file

@ -588,6 +588,7 @@ function access_denied()
set_status_header(401); set_status_header(401);
if ( isset($user) and !is_a_guest() ) if ( isset($user) and !is_a_guest() )
{ {
echo '<meta http-equiv="Content-Type" content="text/html; charset=utf-8">';
echo '<div style="text-align:center;">'.l10n('access_forbiden').'<br />'; echo '<div style="text-align:center;">'.l10n('access_forbiden').'<br />';
echo '<a href="'.get_root_url().'identification.php">'.l10n('identification').'</a>&nbsp;'; echo '<a href="'.get_root_url().'identification.php">'.l10n('identification').'</a>&nbsp;';
echo '<a href="'.make_index_url().'">'.l10n('home').'</a></div>'; echo '<a href="'.make_index_url().'">'.l10n('home').'</a></div>';

View file

@ -146,7 +146,7 @@ INSERT INTO '.SESSIONS_TABLE.'
(id,data,expiration) (id,data,expiration)
VALUES(\''.get_remote_addr_session_hash().$session_id.'\',\''.$data.'\',now()) VALUES(\''.get_remote_addr_session_hash().$session_id.'\',\''.$data.'\',now())
;'; ;';
mysql_query($query); pwg_query($query);
return true; return true;
} }

View file

@ -71,7 +71,7 @@ function execute_sqlfile($filepath, $replaced, $replacing)
$query = $matches[1].' '.$install_charset_collate.';'; $query = $matches[1].' '.$install_charset_collate.';';
} }
} }
mysql_query($query); pwg_query($query);
} }
$query = ''; $query = '';
} }

View file

@ -42,7 +42,7 @@ $query = '
SELECT prefix_thumbnail, mail_webmaster SELECT prefix_thumbnail, mail_webmaster
FROM '.PREFIX_TABLE.'config FROM '.PREFIX_TABLE.'config
;'; ;';
$save = mysql_fetch_array(mysql_query($query)); $save = mysql_fetch_array(pwg_query($query));
$queries = array( $queries = array(
" "

View file

@ -64,7 +64,7 @@ DELETE
\'authorize_remembering\' \'authorize_remembering\'
) )
;'; ;';
mysql_query($query); pwg_query($query);
$queries = array( $queries = array(

View file

@ -157,7 +157,7 @@ LIMIT 0, 1
SELECT * FROM '.IMAGE_TAG_TABLE.' SELECT * FROM '.IMAGE_TAG_TABLE.'
WHERE image_id = ' . $row['id'] .' WHERE image_id = ' . $row['id'] .'
;'; ;';
$tag_count = mysql_num_rows(mysql_query($query)); $tag_count = mysql_num_rows(pwg_query($query));
$template->assign('thumbnail', $template->assign('thumbnail',
array( array(
'IMAGE' => get_thumbnail_url($row), 'IMAGE' => get_thumbnail_url($row),

View file

@ -268,7 +268,7 @@ TABLE.tagLetterContent {
#theNotificationPage DL, #theNotificationPage DL,
#thePopuphelpPage DL { margin: 0 25px 25px; } #thePopuphelpPage DL { margin: 0 25px 25px; }
#content #comments UL.thumbnailCategories LI { width:99%; } .content #comments UL.thumbnailCategories LI { width:99%; }
/* jQuery datepicker */ /* jQuery datepicker */
IMG.ui-datepicker-trigger { IMG.ui-datepicker-trigger {
cursor : pointer; cursor : pointer;

Binary file not shown.

After

Width:  |  Height:  |  Size: 85 B

View file

@ -109,6 +109,9 @@ BODY {
#menubar LI { #menubar LI {
padding-left: 12px; padding-left: 12px;
} }
#menubar LI UL {
background: transparent url(images/transparent.gif);
}
#menubar A, .menuInfoCat { #menubar A, .menuInfoCat {
font-size: 13px; font-size: 13px;
} }
@ -128,7 +131,7 @@ BODY {
#menubar #mbIdentification form { #menubar #mbIdentification form {
background:transparent url(images/menuId_sides.gif) repeat-y scroll left bottom; background:transparent url(images/menuId_sides.gif) repeat-y scroll left bottom;
} }
#menubar #mbIdentification .actions, #menubar li ul, #menubar #mbIdentification form p { #menubar #mbIdentification .actions, #menubar #mbIdentification form p {
background:transparent none repeat-y scroll left bottom; background:transparent none repeat-y scroll left bottom;
} }
#menubar #mbIdentification p { #menubar #mbIdentification p {
@ -161,7 +164,7 @@ BODY {
padding: 0 8px 0 16px; padding: 0 8px 0 16px;
} }
#content { .content {
background:#222 url(images/fillet.gif) repeat-x scroll left top; background:#222 url(images/fillet.gif) repeat-x scroll left top;
min-height:466px; min-height:466px;
} }

View file

@ -80,7 +80,7 @@ function get_tables()
$query = ' $query = '
SHOW TABLES SHOW TABLES
;'; ;';
$result = mysql_query($query); $result = pwg_query($query);
while ($row = mysql_fetch_row($result)) while ($row = mysql_fetch_row($result))
{ {
@ -107,7 +107,7 @@ function get_columns_of($tables)
$query = ' $query = '
DESC '.$table.' DESC '.$table.'
;'; ;';
$result = mysql_query($query); $result = pwg_query($query);
$columns_of[$table] = array(); $columns_of[$table] = array();