big-moving.ru/api/mod/edit_module.html

71 lines
3.4 KiB
HTML
Executable File

{include file=$header_admin h1="Редактор кода" title="Редактор кода {$smarty.get.id}"}
<!-- -->
<div id="tabs">
<ul>
<li><a href="#HTML">HTML</a></li>
<li><a href="#PHP">PHP</a></li>
<li><a href="#JS">JS</a></li>
<li><a href="#ACT">ACT</a></li>
<li><a href="#NEWS">NEWS</a></li>
</ul>
<div id="HTML">
<form method="post" id="form_code_html">
<input type="hidden" name="act" value="save_html">
<input type="hidden" name="mod" value="{$smarty.get.id}">
<input type="submit" name='ok2' value='Сохранить' class="btn btn-success btn_save_code btn-sm">
<textarea id="code_html" name="code" style="height: 600px;">{$html_code}</textarea>
<input type="submit" name='ok' value='Сохранить' class="btn btn-success btn_save_code btn-sm">
</form>
{include file='api/templates/admin/inc/codemirror.html' mod='html' el='code_html'}
</div>
<div id="PHP">
<form method="post" id="form_code_php">
<input type="hidden" name="act" value="save_php">
<input type="hidden" name="mod" value="{$smarty.get.id}">
<input type="submit" name='ok2' value='Сохранить' class="btn btn-success btn_save_code btn-sm">
<textarea id="code_php" name="code" style="height: 600px;"><?php
{$php_code}
?></textarea>
<input type="submit" name='ok' value='Сохранить' class="btn btn-success btn_save_code btn-sm">
</form>
{include file='api/templates/admin/inc/codemirror.html' mod='php' el='code_php'}
</div>
<div id="JS">
<form method="post" id="form_code_js">
<input type="hidden" name="act" value="save_js">
<input type="hidden" name="mod" value="{$smarty.get.id}">
<input type="submit" name='ok2' value='Сохранить' class="btn btn-success btn_save_code btn-sm">
<textarea id="code_js" name="code" style="height: 600px;">{$js_code}</textarea>
<input type="submit" name='ok' value='Сохранить' class="btn btn-success btn_save_code btn-sm">
</form>
{include file='api/templates/admin/inc/codemirror.html' mod='js' el='code_js'}
</div>
<div id="ACT">
<form method="post" id="form_code_act">
<input type="hidden" name="act" value="save_act">
<input type="hidden" name="mod" value="{$smarty.get.id}">
<input type="submit" name='ok2' value='Сохранить' class="btn btn-success btn_save_code btn-sm">
<textarea id="code_act" name="code" style="height: 600px;"><?php
{$act_code}
?>
</textarea>
<input type="submit" name='ok' value='Сохранить' class="btn btn-success btn_save_code btn-sm">
</form>
{include file='api/templates/admin/inc/codemirror.html' mod='php' el='code_act'}
</div>
<div id="NEWS">
<form method="post" id="form_news">
<input type="hidden" name="act" value="save_js">
<input type="hidden" name="mod" value="{$smarty.get.id}">
<input type="submit" value='Сохранить' class="btn btn-success btn_save_code btn-sm">
<textarea id="code_news" name="news" style="height: 600px;">{$news}</textarea>
<input type="submit" name='ok' value='Сохранить' class="btn btn-success btn_save_code btn-sm">
</form>
</div>
</div>
<br><br>
<input id="load_page" type="text" value="/{$smarty.get.id}/">
<br><br>
<iframe src="/{$smarty.get.id}/" id="demo_page" style="width: 100%; height: 600px;"></iframe>
<link rel="stylesheet" href="/api/jquery/jquery-ui/dark-hive1.12.1/jquery-ui.css">
<link rel="stylesheet" href="/api/jquery/jquery-ui/dark-hive1.12.1/jquery-ui.theme.min.css">