Pick up a blog
Files: Forms in Site/links/img0_add.html (line 4th)
<form id=save action= "@{sys:face}site/links/img0_add_up1.chtml" onsubmit= "return false;" Target=_self Method=post Enctype= "Multipart/form-data" ><input type=hidden name=reurl value= "site/links/img0.html" ><tr>< TD Width=88><font Class=acttitle> name </FONT></TD><TD width=700><input size=36 Name=NAME ></td></tr><tr><td><font class=acttitle> Link Address </font></td><td> <input size=40 name=link></td></tr><tr><td><font class=acttitle> Pictures </font ></td><td><input name=image size=32 type=file> (730x486) </td></tr></form>
submit to File: site/links/img0_add_up1.chtml (in the
Light Open e-commerce system (Enterprise entry-level business website) under the site/links/directory)
organize the full file name
<bag Id=ppage><we name=img_url>site/links/upimgs/@{sys:only}@{ppage:image_extname}</we></ Bag>
Insert name, link address, file URI into database
<esql module=base Act=edit>insert into Images_base (name,link,img_url) Values (@{ppage:name:string},@{ppage: Link:string},@{ppage:img_url:string}) </ESql>
Save File
<file value= "@{ppage:image}" islast>@{ppage:img_url}</file>
If the author does not have permissions, prompt and return
<script>alert ("You do not have permission!"); location.href= ' @{sys:face}@{ppage:reurl} ' </script>
returned when added successfully
<script>alert ("added successfully! "); location.href= ' @{sys:face}@{ppage:reurl} ';</script>
All code
(file: site/links/img0_add_up1.chtml) in the Light Open e-commerce system (Enterprise entry-level business website) under the site/links/directory
Easy to download resources for Internet development Platform
Development example: Light Open Enterprise Entry-level e-commerce website , free download: http://download.csdn.net/detail/tx18/8818883
Light open platform will be upgraded to provide you with more powerful and easy features, please pay attention to Download the latest version
Change the page Carousel theme Picture (3, save add)---Light open e-commerce system (Enterprise entry-level business website)