I have a working form passing the information to me via email but need to add one more item to the form which I'm not sure how to do or that it is possible with PHP.

I have an image which needs to have sections change color on mouseover, mouse out, with the color changing state with a mouse click. Clicks should change the values being passed via post to the email processing php page.

Any thoughts on a good way to go about this?

onmouseover, onmouseout and onclick are all client side Javascript events. I am assuming that this portion already works. So depending on your needs, probably the easiest way of doing this would be to use hidden form fields.

<input type="hidden" id="your_id1" value="your default">

Now when the Javascript fires (lets say the onclick triggers a function "setColorBlock1()") then the function setColorBlock1 would do the setting of the value of the hidden field.

function setColorBlock1() {
    hiddenFldObj = document.getElementById('your_id1');
    hiddenFldObj.value = "something else";
 }
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.