我正在建立一个社交网络类型的网站,用户可以上传他们的项目进行评级.但是,我正在尝试改进网站的布局方式,因此想要在用户插入新项目后自动生成页面. add.PHP页面具有以下形式:
<form action="add.PHP" method="post" autocomplete="on" enctype="multipart/form-data" action="<?PHP echo $_SERVER['PHP_SELF']; ?>" method="POST" id="pic"> <p> <label for="jname" class="iconic user"> Name of Jam <span class="required">*</span></label> <input type="text" name="jname" id="jname" value="<?PHP if (isset($_POST['jname'])) echo $_POST['jname']; ?>" required="required" placeholder="Input your Name of Jam here" /> </p> <p> <select name="jtype" id="jtype" value="<?PHP if (isset($_POST['jtype'])) echo $_POST['jtype']; ?>" required="required"> <option value="jam">Jam</option> <option value="jelly">Jelly</option> <option value="marmalade">Marmalade</option> <option value="preserve">Preserve</option> </select> </p> <p> <label for="producer" class="iconic user"> Jam Producer <span class="required">*</span></label> <input type="text" name="producer" id="producer" value="<?PHP if (isset($_POST['producer'])) echo $_POST['producer']; ?>" required="required" placeholder="Input the producer of the Jam here" /> </p> Upload a picture of your jam: </br> </br> <input name="userfile" type="file" /> </br> <input type="submit" name="submit" value="Register" /> <input type="hidden" name="submitted" value="TRUE" /> </form>
提交表单后,我希望它为该新用户创建的项生成新页面.有这么简单的方法吗?
干杯