質問編集履歴
1
質問内容追記のため
test
CHANGED
File without changes
|
test
CHANGED
@@ -321,3 +321,307 @@
|
|
321
321
|
|
322
322
|
|
323
323
|
```
|
324
|
+
|
325
|
+
|
326
|
+
|
327
|
+
```php
|
328
|
+
|
329
|
+
変更後1ページ
|
330
|
+
|
331
|
+
|
332
|
+
|
333
|
+
<?php
|
334
|
+
|
335
|
+
session_start();
|
336
|
+
|
337
|
+
?>
|
338
|
+
|
339
|
+
<!DOCTYPE html>
|
340
|
+
|
341
|
+
<html>
|
342
|
+
|
343
|
+
<head>
|
344
|
+
|
345
|
+
<meta charset="UTF-8">
|
346
|
+
|
347
|
+
<title>顧客管理*検索</title>
|
348
|
+
|
349
|
+
<form action="/phpkiso/DB/DB/updata.php" name="form1" method="post">
|
350
|
+
|
351
|
+
<link rel="stylesheet" href="DB_color.css" class="e">
|
352
|
+
|
353
|
+
<style type="text/css">
|
354
|
+
|
355
|
+
<!--
|
356
|
+
|
357
|
+
body {line-height: 130%;}
|
358
|
+
|
359
|
+
-->
|
360
|
+
|
361
|
+
</style>
|
362
|
+
|
363
|
+
<style type="text/css">
|
364
|
+
|
365
|
+
<!--
|
366
|
+
|
367
|
+
body{
|
368
|
+
|
369
|
+
line-height : 170%;
|
370
|
+
|
371
|
+
}
|
372
|
+
|
373
|
+
or
|
374
|
+
|
375
|
+
p{
|
376
|
+
|
377
|
+
line-height : 170%;
|
378
|
+
|
379
|
+
}
|
380
|
+
|
381
|
+
-->
|
382
|
+
|
383
|
+
</style>
|
384
|
+
|
385
|
+
</head>
|
386
|
+
|
387
|
+
<center>顧客管理情報ツール(入金金額*一覧)</center>
|
388
|
+
|
389
|
+
<body background="back.gif" bgcolor="#ccc" class="a">
|
390
|
+
|
391
|
+
<br />
|
392
|
+
|
393
|
+
<body>
|
394
|
+
|
395
|
+
<?php
|
396
|
+
|
397
|
+
$dsn = 'mysql:host=localhost;dbname=customer;charset=utf8';
|
398
|
+
|
399
|
+
$user = 'root';
|
400
|
+
|
401
|
+
$password = '';
|
402
|
+
|
403
|
+
|
404
|
+
|
405
|
+
$dbh = new PDO($dsn, $user, $password);
|
406
|
+
|
407
|
+
$dbh->query('SET NAMES utf8');
|
408
|
+
|
409
|
+
$sqlcmd = "SELECT * FROM `customer_Payment`";
|
410
|
+
|
411
|
+
$statement = $dbh->prepare($sqlcmd);
|
412
|
+
|
413
|
+
$statement->execute();
|
414
|
+
|
415
|
+
|
416
|
+
|
417
|
+
if($statement->execute()){
|
418
|
+
|
419
|
+
$row_count = $statement->rowCount();
|
420
|
+
|
421
|
+
while($row = $statement->fetch()){
|
422
|
+
|
423
|
+
$rows[] = $row;}
|
424
|
+
|
425
|
+
// $rowsをセッション'ROWS'に保存
|
426
|
+
|
427
|
+
$_SESSION['ROWS'] = $rows;
|
428
|
+
|
429
|
+
}else{
|
430
|
+
|
431
|
+
$errors['error'] = "検索失敗しました。";
|
432
|
+
|
433
|
+
}
|
434
|
+
|
435
|
+
|
436
|
+
|
437
|
+
$dbh = null;
|
438
|
+
|
439
|
+
?>
|
440
|
+
|
441
|
+
<br />
|
442
|
+
|
443
|
+
<fieldset>
|
444
|
+
|
445
|
+
<!-- <?php foreach($rows as $row){ ;?> -->
|
446
|
+
|
447
|
+
<br />
|
448
|
+
|
449
|
+
[名 前]<input type="text" value="<?php echo $row['name']; ?>" class="d-na" name="name">
|
450
|
+
|
451
|
+
[カテゴリ]<input type="text" value="<?php print $row['abc']; ?>" class="d-na" name="abc">
|
452
|
+
|
453
|
+
[支払い月]<input type="text" value="<?php print $row['semina_month'];?> " class="d-year" name="semina_month">
|
454
|
+
|
455
|
+
[金 額]<input type="text" value="<?php print $row['payment'];?> " class="d-na" name="payment">
|
456
|
+
|
457
|
+
[有無]<input type="text" value="<?php print $row['ab'];?> " class="d-da" name="ab">
|
458
|
+
|
459
|
+
<input type="submit" onclick="/phpkiso/DB/DB/updata.php" value="変更" method="post">
|
460
|
+
|
461
|
+
<input type="button" name="delate" value="削除">
|
462
|
+
|
463
|
+
<!-- <?php }?> -->
|
464
|
+
|
465
|
+
</fieldset>
|
466
|
+
|
467
|
+
<?php
|
468
|
+
|
469
|
+
print(isset($row['name']));
|
470
|
+
|
471
|
+
?>
|
472
|
+
|
473
|
+
<br />
|
474
|
+
|
475
|
+
<br />
|
476
|
+
|
477
|
+
<input type="button" onclick="location.href='./DB_top.php'" value="トップ戻る">
|
478
|
+
|
479
|
+
<!-- <input type="submit" value=変更 name="/phpkiso/DB/DB/updata.php"></td></tr>
|
480
|
+
|
481
|
+
-->
|
482
|
+
|
483
|
+
</body>
|
484
|
+
|
485
|
+
</html>
|
486
|
+
|
487
|
+
|
488
|
+
|
489
|
+
```
|
490
|
+
|
491
|
+
|
492
|
+
|
493
|
+
|
494
|
+
|
495
|
+
|
496
|
+
|
497
|
+
```php
|
498
|
+
|
499
|
+
2ページめ
|
500
|
+
|
501
|
+
|
502
|
+
|
503
|
+
|
504
|
+
|
505
|
+
<?php
|
506
|
+
|
507
|
+
session_start();
|
508
|
+
|
509
|
+
$rows=$_SESSION['ROWS'];
|
510
|
+
|
511
|
+
?>
|
512
|
+
|
513
|
+
<!DOCTYPE html>
|
514
|
+
|
515
|
+
<html>
|
516
|
+
|
517
|
+
<head>
|
518
|
+
|
519
|
+
<meta charset="UTF-8">
|
520
|
+
|
521
|
+
<title>顧客管理*検索</title>
|
522
|
+
|
523
|
+
<link rel="stylesheet" href="DB_color.css" class="e">
|
524
|
+
|
525
|
+
<style type="text/css">
|
526
|
+
|
527
|
+
<!--
|
528
|
+
|
529
|
+
body {line-height: 130%;}
|
530
|
+
|
531
|
+
-->
|
532
|
+
|
533
|
+
</style>
|
534
|
+
|
535
|
+
<style type="text/css">
|
536
|
+
|
537
|
+
<!--
|
538
|
+
|
539
|
+
body{
|
540
|
+
|
541
|
+
line-height : 170%;
|
542
|
+
|
543
|
+
}
|
544
|
+
|
545
|
+
or
|
546
|
+
|
547
|
+
p{
|
548
|
+
|
549
|
+
line-height : 170%;
|
550
|
+
|
551
|
+
}
|
552
|
+
|
553
|
+
-->
|
554
|
+
|
555
|
+
</style>
|
556
|
+
|
557
|
+
</head>
|
558
|
+
|
559
|
+
<form action="../DB_top.php" method="post">
|
560
|
+
|
561
|
+
<center>顧客管理情報ツール(セミナー情報*検索)</center>
|
562
|
+
|
563
|
+
<body background="back.gif" bgcolor="#ccc" class="a">
|
564
|
+
|
565
|
+
<br />
|
566
|
+
|
567
|
+
<?php
|
568
|
+
|
569
|
+
|
570
|
+
|
571
|
+
print(isset($post['name']));
|
572
|
+
|
573
|
+
|
574
|
+
|
575
|
+
|
576
|
+
|
577
|
+
?>
|
578
|
+
|
579
|
+
<fieldset>
|
580
|
+
|
581
|
+
<fieldset>
|
582
|
+
|
583
|
+
<br />
|
584
|
+
|
585
|
+
<tr>
|
586
|
+
|
587
|
+
<td>コ ー ド</td>
|
588
|
+
|
589
|
+
<td><input type="text" value="<?php echo $_SESSION['code']; ?>" class="d-i"></td><br />
|
590
|
+
|
591
|
+
<td>名 前</td>
|
592
|
+
|
593
|
+
<td><input type="text" value="<?php echo $_SESSION['name']; ?>" class="d-i"></td><br />
|
594
|
+
|
595
|
+
<td>カ テ ゴ リ</td>
|
596
|
+
|
597
|
+
<td><input type="text" value="<?php echo $_SESSION['abc']; ?>" class="d-i"></td><br />
|
598
|
+
|
599
|
+
<td>支払 い月</td>
|
600
|
+
|
601
|
+
<input type="text" value="<?php echo $_SESSION['semina_month']; ?>" class="d-i">月</td><br />
|
602
|
+
|
603
|
+
<td>金 額</td>
|
604
|
+
|
605
|
+
<td><input type="text" value="<?php print $_SESSION['payment']; ?>" class="d-ad"></td><br />
|
606
|
+
|
607
|
+
<td>有 無</td>
|
608
|
+
|
609
|
+
<td><input type="text" value="<?php echo $_SESSION['ad']; ?>" class="d-na"></td><br /></tr>
|
610
|
+
|
611
|
+
</fieldset>
|
612
|
+
|
613
|
+
</fieldset>
|
614
|
+
|
615
|
+
<br />
|
616
|
+
|
617
|
+
<br />
|
618
|
+
|
619
|
+
<input type="button" onclick="location.href='../DB_top.php'" value="トップ戻る">
|
620
|
+
|
621
|
+
</body>
|
622
|
+
|
623
|
+
</html>
|
624
|
+
|
625
|
+
|
626
|
+
|
627
|
+
```
|