Hi guys was wondering if anyone could help me out, I have been googling for hours for a solution but to no avail .
Basically I want to know how I can create a contact me link on a page that will take the user to the main contact me page of my website but fill out the title part of the form with a description of the previous page.
Any help would be greatly appreciated
Where should this description come from? The TITLE of the page?
The link URL to the contact page might contain a query string that reveals the previous page. For example, on the page "foo.html" the link URL to the contact page might be "contact.html?from=foo". Then a script on the contact page might select the description related to foo from an array of descriptions.
The site is a very simple image gallery, there isn't ever going to be hundreds of images so I elected to go with a simple layout from the gallery page displaying a grid of thumbnail pictures, once one is clicked it opens up to a new page specifically about that image alone. The contact page contains no images, I don't want people having to flick back and forth between the contact form and the previous picture, I would prefare when the contact link is clicked that the info about the picture would automatically fill the title of the contact form.
Gallery.html > select thumbnail > open Image1.html > select enquire about image > Contact.html with title pre filled with name of picture.
I was wondering WHERE that info is to start with, if it exists. You could hard code a query string per Christians directives, but if the info needed, or at least part of it, is already available on the page there may be ways to extract it so you don't need to hard code the query string.
Do you for example have <title>Name of the picture</title> you could extract the text content of TITLE with JavaSript and put it into the query string. On the contact page another script would get the name of the image out of the query sting and use it in the form. That way you can use the same script on all image pages and don't need to edit anything for each new page.
The first part could go something like this. Note that you must have a TITLE if you try it. You needn't use TITLE for this, but that's how the example is written.
@pandy, I took your code and rewrote it a little. This line:
Powered by Invision Power Board (http://www.invisionboard.com)
© Invision Power Services (http://www.invisionpower.com)