code refactor. centralized js for functions.
This commit is contained in:
parent
b742d8606d
commit
6113e8ed05
@ -44,13 +44,13 @@ db::c()->query('UPDATE `users` SET `enter_game` = 0 WHERE `enter_game` = 1 AND `
|
|||||||
<body>
|
<body>
|
||||||
<table class="frametable">
|
<table class="frametable">
|
||||||
<tr style="height: 25px;">
|
<tr style="height: 25px;">
|
||||||
<td class="frametd"><iframe id="header<?= mt_rand() ?>" class="FRAME" src="top_menu.php" scrolling="no" frameborder="0" name="frameheader"></iframe></td>
|
<td class="frametd"><iframe id="header<?= mt_rand() ?>" class="FRAME" src="top_menu.php" scrolling="no" frameborder="0" name="headframe"></iframe></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr style="height: 75%;">
|
<tr style="height: 75%;">
|
||||||
<td class="frametd"><iframe id="main<?= mt_rand() ?>" class="FRAME" src="main.php?top=<?= mt_rand() ?>" frameborder="0" name="framemain"></iframe></td>
|
<td class="frametd"><iframe id="main<?= mt_rand() ?>" class="FRAME" src="main.php?top=<?= mt_rand() ?>" frameborder="0" name="gameframe"></iframe></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td class="frametd"><iframe id="chat<?= mt_rand() ?>" class="FRAME" src="chat.php" frameborder="0" name="framechat"></iframe></td>
|
<td class="frametd"><iframe id="chat<?= mt_rand() ?>" class="FRAME" src="chat.php" frameborder="0" name="chatframe"></iframe></td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
</body>
|
</body>
|
||||||
|
3
js/main.js
Normal file
3
js/main.js
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
function leave(link) {
|
||||||
|
top.frames['main'].location = link
|
||||||
|
}
|
8
shop.php
8
shop.php
@ -213,15 +213,11 @@ if (!empty($_GET['buy'])) {
|
|||||||
<script src="js/jquery-1.7.2.min.js"></script>
|
<script src="js/jquery-1.7.2.min.js"></script>
|
||||||
<script src="js/jquery.simplemodal.js"></script>
|
<script src="js/jquery.simplemodal.js"></script>
|
||||||
<script src="js/jquery.ui.js?100"></script>
|
<script src="js/jquery.ui.js?100"></script>
|
||||||
<script>
|
<script src="js/main.js"></script>
|
||||||
function leave() {
|
|
||||||
top.frames['main'].location = 'city.php?cp'
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<h1>Государственный магазин</h1>
|
<h1>Государственный магазин</h1>
|
||||||
<a href=# onclick=leave()> ← выйти на Центральную площадь</a>
|
<a href=# onclick=leave('city.php?cp')> ← выйти на Центральную площадь</a>
|
||||||
<div><?php if (!empty($status)) err($status); ?></div>
|
<div><?php if (!empty($status)) err($status); ?></div>
|
||||||
<TABLE width=100% cellspacing="0" cellpadding="4">
|
<TABLE width=100% cellspacing="0" cellpadding="4">
|
||||||
<TR>
|
<TR>
|
||||||
|
12
top_menu.php
12
top_menu.php
@ -27,12 +27,12 @@
|
|||||||
</HEAD>
|
</HEAD>
|
||||||
<body>
|
<body>
|
||||||
<div>
|
<div>
|
||||||
<a href="/user_anketa.php" title="Анкета" target="framemain">Анкета</a>
|
<a href="/user_anketa.php" title="Анкета" target="gameframe">Анкета</a>
|
||||||
<a href="/contacts.php" title="Контакты" target="framemain">Друзья</a>
|
<a href="/contacts.php" title="Контакты" target="gameframe">Друзья</a>
|
||||||
<a href="/main.php?edit=1" title="Инвентарь" target="framemain">Инвентарь</a>
|
<a href="/main.php?edit=1" title="Инвентарь" target="gameframe">Инвентарь</a>
|
||||||
<a href="/klan.php" title="Клан" target="framemain">Клан</a>
|
<a href="/klan.php" title="Клан" target="gameframe">Клан</a>
|
||||||
<a href="/user_abilities.php" title="Особые умения" target="framemain">Особые умения</a>
|
<a href="/user_abilities.php" title="Особые умения" target="gameframe">Особые умения</a>
|
||||||
<a href="/forum.php" title="Форум" target="framemain">Форум</a>
|
<a href="/forum.php" title="Форум" target="gameframe">Форум</a>
|
||||||
</div>
|
</div>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
Loading…
Reference in New Issue
Block a user