Jump to content

form issue


point86

Recommended Posts

Hi,

I am pretty new to javascript and would like some help please!

Basically I have a form which searches through text for a keyword using:

var highlight = document.getElementById('highlightWords').value;

And then new Ajax.Updater ... '&highlight=' + highlight etc.

I need to add another form box that does exactly the same thing, ie searches for a keyword, but for a different keyword than box one.

I know this is pretty simple but like I said, Im new! Anyone any ideas?

Thanks!
Link to comment
https://forums.phpfreaks.com/topic/26708-form-issue/
Share on other sites

Well I have two form boxes, in each of which a user can enter a keyword. My program then searches a text file for the search term and highlights it. Box 1 I have got working fine, using:

var highlight = document.getElementById('highlightWords').value;

But I dont know how to code the other box so it does the same thing as box 1, but using a different keyword; i.e. the user can select two keywords to use in the search.

Hope this clears things up,

Thanks

Point.
Link to comment
https://forums.phpfreaks.com/topic/26708-form-issue/#findComment-122916
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

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.