Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

PHP Forum


You are currently viewing our PHP Forum as a guest. Please register to participate.
Login



Freelance Jobs

Reply
PHP Form Session Variables HELP!
Old 02-08-2010, 06:58 AM PHP Form Session Variables HELP!
Junior Talker

Posts: 1
Name: david
Trades: 0
Hi guys.

I need some help with a client of mines website.

Basically, the front page has a simple form that captures (name, email, and tel etc), and the price of their home.

On the second page, the information from the first page is stored on a Mysql database, and the customer is given an offer for their home.

They are presented with another form that asks if they accept the offer or not.

This then updates the Mysql database if they click 'yes' 'no' or 'maybe'.

The problem I am having is the client has now introduced a third party into the equation.

As well as the system I have developed, they also want the information, including the second set of information to be submitted via an iframe to another company.

At the moment I have created a third page, which asks the user to confirm their information.

Obviously this is not ideal, as not every customer is not going to resubmit their details.

Is there anyway I can build a timer of some sort into my database that waits 10 mins or so to see if the customer clicks 'yes' 'no' 'maybe', and then submits it to the other companies database?

The code they have given me looks like this:-

CustomEnquiry.aspx?NM=<? echo $name; ?>&EM=<? echo $email; ?>&PH=<? echo $tel; ?>&PC=<? echo $postcode; ?>&VL=<? echo $propvalue2; ?>&BMV=<? echo $bmvpercentage; ?>&OF=<? echo $acceptbmv; ?>

the echo $'s, are my variables, but they need all of this info sent across.

Hope someone can help.
sess4561 is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 02-08-2010, 07:09 AM Re: PHP Form Session Variables HELP!
chrishirst's Avatar
Missing! presumed drunk.

Posts: 42,385
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
Quote:
Is there anyway I can build a timer of some sort into my database that waits 10 mins or so to see if the customer clicks 'yes' 'no' 'maybe', and then submits it to the other companies database?
Nope, HTTP doesn't work like that. If it doesn't happen there and then it isn't going to happen.
__________________
Chris. ->>
Please login or register to view this content. Registration is FREE
<<-

A foolish consistency is the hobgoblin of little minds
Thought for today:- Is SEO the only industry where all the cowboys are Indians?
chrishirst is offline
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Old 02-08-2010, 01:18 PM Re: PHP Form Session Variables HELP!
kingsleyben's Avatar
Junior Talker

Posts: 3
Name: Ben Kingsley
Location: Huntsville/Florence, AL
Trades: 0
I'm a newbie so take what I say with a grain of salt, but could you create a cookie that times out in 10 minutes? When the cookie expires the data could be removed from the database. Feel free to tell me if this is a retarted idea, I'm here to learn! =)
kingsleyben is offline
Reply With Quote
View Public Profile
 
Old 02-08-2010, 03:54 PM Re: PHP Form Session Variables HELP!
chrishirst's Avatar
Missing! presumed drunk.

Posts: 42,385
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
HTTP is a disconnected protocol. Once a page is served to the client the connection is finished and no further communication occurs until another page is requested by the user.
Cookies are passive devices, simply clientside text files that have no means of interaction with the server.

What you need to accomplish will need user action to trigger.
__________________
Chris. ->>
Please login or register to view this content. Registration is FREE
<<-

A foolish consistency is the hobgoblin of little minds
Thought for today:- Is SEO the only industry where all the cowboys are Indians?
chrishirst is offline
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Old 02-08-2010, 04:24 PM Re: PHP Form Session Variables HELP!
lynxus's Avatar
Awesomeo-Maximo

Posts: 1,618
Location: UK
Trades: 1
Id personally have it all in the DB like you do now and have a Created TIMESTAMP

Id then ( on a linux box ) have a crontab that ran every 1minute and executed a PHP file that would look at the DB, Take the rows that are older than 10 minutes.

Do summat with the data ( send it to the 3rd party or update anotehr table )
and then delete it.
__________________

Please login or register to view this content. Registration is FREE

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

Please login or register to view this content. Registration is FREE


lynxus is offline
Reply With Quote
View Public Profile Visit lynxus's homepage!
 
Old 02-08-2010, 07:59 PM Re: PHP Form Session Variables HELP!
NullPointer's Avatar
Will Code for Food

Posts: 2,815
Name: Matt
Location: Irvine, CA
Trades: 0
Quote:
Originally Posted by sess4561 View Post
Is there anyway I can build a timer of some sort into my database that waits 10 mins or so to see if the customer clicks 'yes' 'no' 'maybe', and then submits it to the other companies database?
I think there's something here I'm not understanding. Is there a reason why you cannot submit the data when the user click yes or no?
__________________

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
NullPointer is online now
Reply With Quote
View Public Profile Visit NullPointer's homepage!
 
Old 02-09-2010, 09:22 AM Re: PHP Form Session Variables HELP!
kingsleyben's Avatar
Junior Talker

Posts: 3
Name: Ben Kingsley
Location: Huntsville/Florence, AL
Trades: 0
Wow, I have a lot to learn...
kingsleyben is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to PHP Form Session Variables HELP!
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.24967 seconds with 12 queries