LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 01-30-2007, 01:09 AM   #1
stranger_6_7
LQ Newbie
 
Registered: Nov 2006
Posts: 24

Rep: Reputation: 15
Execute a php or sql script by button click


Hi

I want to run a php file or a .sql file with a button click. As soon as a user clicks a button on a page the onclick function must execute the php/mysql file. How can i do this.

Thanks for the help in advance
stranger
 
Old 01-30-2007, 06:37 AM   #2
tbutttbutt
Member
 
Registered: Jan 2006
Location: India
Distribution: Fedora 7, Linuxfromscratch 6.2
Posts: 66

Rep: Reputation: 15
Looks like you need link on your page which invokes a php script that does whatever needs to be done.
 
Old 01-31-2007, 11:32 PM   #3
stranger_6_7
LQ Newbie
 
Registered: Nov 2006
Posts: 24

Original Poster
Rep: Reputation: 15
Yes,

When a user clicks on a button in a page, it should run the script in the back ground.

stranger
 
Old 02-02-2007, 08:24 PM   #4
tbutttbutt
Member
 
Registered: Jan 2006
Location: India
Distribution: Fedora 7, Linuxfromscratch 6.2
Posts: 66

Rep: Reputation: 15
You need to have a php script running in standalone mode, that is, not embedded in html. You can call it from a embedded php code using a system() or some such function in php. Look up the php manual for the right function.
 
  


Reply


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



Similar Threads
Thread Thread Starter Forum Replies Last Post
php+mysql: how to execute a sql batch file prabhatsoni Linux - Software 7 04-19-2006 06:11 AM
how to execute a shell script in GUI by double click kamesh156 Programming 1 10-18-2005 05:25 AM
How to Execute PHP Script? notooth Linux - General 2 06-02-2005 05:43 AM
PHP -- How to execute a shell script from PHP using FTP functions?? zoonalex Programming 3 07-29-2004 11:51 AM
ColdFusion - Using a script to build and execute SQL query when a button is clicked Locura Programming 1 02-25-2004 09:59 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 03:19 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration