Jump to content
xisto Community
Sign in to follow this  
kvarnerexpress

Move/delete Image On Webpage Automatically?

Recommended Posts

Hi,Im creating a website that sells carpets and basically ive created webpages with the picture and checkboxes underneath the pictures so users can select which carpet they want!Once they submit the form, we get the order including form details!The problem is that once the user checks the checkboxes, i want to be able to delete that image from that webpage or move that picture to another location in the folders i have stored on the server. The reason is becuase evry carpet is unique so that two people cant order the same carpet!Now wat is the best way 2 do this.....Using a database or can this be done using sumat like javascript or sumat?Thanks in advanced!

Share this post


Link to post
Share on other sites

Hi,

Im creating a website that sells carpets and basically ive created webpages with the picture and checkboxes underneath the pictures so users can select which carpet they want!

Once they submit the form, we get the order including form details!

The problem is that once the user checks the checkboxes, i want to be able to delete that image from that webpage or move that picture to another location in the folders i have stored on the server. The reason is becuase evry carpet is unique so that two people cant order the same carpet!

Now wat is the best way 2 do this.....

Using a database or can this be done using sumat like javascript or sumat?

Thanks in advanced!

<{POST_SNAPBACK}>


i think the easiest way is to use php. I am not sure how many carpets there are and how the you display them, but with php you can write a script to display whatever is in the "carpets" directory and then add exclusions.

 

So, when someone submits a form to buy a particular carpet, the php script for the form can also change the file extension to "sold" (or whatever). When the carpet display php script goes to display all the carpets, tell it to skip all "sold" extensions... if !(strstr($filename,'.sold')) { display some html stuff here }

 

i'm not sure how much php you know, but i can help you. I wrote a similar script to display images so that whatever images I put in that directory would get displayed. No need to update html code... just upload the file into the directory.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.