Perl Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming LanguagesPerl Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old September 25th, 2001, 05:33 AM
thuynh7 thuynh7 is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Nov 2000
Posts: 109 thuynh7 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 11 h 42 m 14 sec
Reputation Power: 9
automatic field inputs

I have some product pages, but after the user reads the content, there is a "click here for further information" button, as soon as teh user clicks on the button a pop up form appears, with the standard fields, Name, email, tel, and so on. However there is a field that called product that I want to be already filled in. This field will be dependant on the the product page that they're on.

this is what I've got so far, the button:

<a href="/cgi-bin/form.cgi" onclick="NewWindow(this.href,'name','595','255','no');return false";>


but I need to integrate this some how

<input type="hidden" name="Product" value="Product A">

Reply With Quote
  #2  
Old September 25th, 2001, 07:41 AM
MattWilliams MattWilliams is offline
hmmmm...
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2001
Location: UK
Posts: 37 MattWilliams User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 8
Why dont you look at passing the parameter using the JavaScript method "location.search."

eg:
somepage.html?thisproduct

this a piece of code not used often but very useful when it is.

Reply With Quote
  #3  
Old September 25th, 2001, 07:57 AM
telex4's Avatar
telex4 telex4 is offline
Wacky hack
Dev Shed Novice (500 - 999 posts)
 
Join Date: Apr 2001
Location: London, England
Posts: 512 telex4 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 25 m 29 sec
Reputation Power: 8
Could you not just include the product name in the href, like so:

Code:
<a href="/cgi-bin/form.cgi?product=productA" onclick="NewWindow(this.href,'name','595','255','no');return false";>

Reply With Quote
  #4  
Old September 25th, 2001, 08:05 AM
MattWilliams MattWilliams is offline
hmmmm...
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2001
Location: UK
Posts: 37 MattWilliams User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 8
You could but i cant see why thuynh7 needs to use a cgi script just to create a web form as the only dynamic part of it (based on his note) would be the inclusion of the product type?

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming LanguagesPerl Programming > automatic field inputs


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 2 hosted by Hostway
Stay green...Green IT