コード例 #1
0
<?php

ini_set('display_errors', 1);
error_reporting(E_ALL);
?>

<?php 
require "template.php";
require_once 'api.php';
$userData = api_user_read($_GET["id"]);
$pageTitle = "Edit user information";
$content = '
      <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap-datetimepicker/4.17.37/css/bootstrap-datetimepicker.min.css">
      <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.10.6/moment-with-locales.min.js"></script>
      <script src="https://cdnjs.cloudflare.com/ajax/libs/bootstrap-datetimepicker/4.17.37/js/bootstrap-datetimepicker.min.js"></script>
      
      <div class="container">
        <div class="row">
          <div class="col-md-10 col-md-offset-1">
            <div class="panel panel-default">
              <div class="panel-body">
                <div class="page-header">
                  <h2>Edit user information</h2>
                </div>

                <form class="form-horizontal" action="form.php?id=' . $userData["id"] . '" method="post" enctype="multipart/form-data">
                  <div class="form-group">
                    <label for="inputUsername" class="col-sm-2 control-label">Username</label>
                    <div class="col-sm-10">
                      <input type="text" class="form-control" id="inputUsername" name="username" value="' . $userData["username"] . '" placeholder="Username" required>
                    </div>
コード例 #2
0
ファイル: edit.php プロジェクト: sanderheinsoo/php
<?php

ini_set('display_errors', 1);
error_reporting(E_ALL);
require_once 'api.php';
require 'template.php';
$userData = api_user_read($_GET['id']);
$pageTitle = "Kasutaja andmete muutmine";
$content = '
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap-datetimepicker/4.17.37/css/bootstrap-datetimepicker.min.css">
    <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.10.6/moment-with-locales.min.js"></script>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/bootstrap-datetimepicker/4.17.37/js/bootstrap-datetimepicker.min.js"></script>

	<div class="container">
		<h2>Kasutaja andmete muutmine</h2>
		<form class="form-horizontal" role="form" method="post" action="form.php?id=' . $userData["id"] . '" enctype="multipart/form-data">

			<div class="form-group">
				<label class="control-label col-sm-2" for="usr">Kasutajanimi:</label>
				<div class="col-sm-10">
					<input type="text" class="form-control" id="usr" name="username" value="' . $userData["username"] . '" placeholder="Kasutajanimi">
				</div>
			</div>

			<div class="form-group">
				<label class="control-label col-sm-2" for="pwd">Parool:</label>
				<div class="col-sm-10">
					<input type="password" class="form-control" id="pwd" name="password" value="' . $userData["password"] . '" placeholder="Parool">
				</div>
			</div>