[PHP-DB] Passing variables to a PHP script on clicking a hyperlink

2007-08-24 Thread Suamya Srivastava
Hello, How can I pass variables on clicking a hyperlink to a PHP script? I have 5 hyperlinks, all pointing to the same PHP script. However, on clicking each hyperlink a different value of the variable needs to be passed to the PHP script. i.e. I have 5 databases from which I want to obtain

[PHP-DB] Re: [PHP] Passing variables to a PHP script on clicking a hyperlink

2007-08-24 Thread mike
On 8/23/07, Suamya Srivastava [EMAIL PROTECTED] wrote: Hello, How can I pass variables on clicking a hyperlink to a PHP script? I have 5 hyperlinks, all pointing to the same PHP script. However, on clicking each hyperlink a different value of the variable needs to be passed to the PHP

Re: [PHP-DB] Re: [PHP] Passing variables to a PHP script on clicking a hyperlink

2007-08-24 Thread Goltsios Theodore
I think that you can also do that buy making a drop down list with the available databases and pass the chosen database to another (or perhaps the same) script and make the queries and output results there. You can catch the posted or got option buy using the $_REQUEST array ($_GET and

Re: [PHP-DB] Re: [PHP] Passing variables to a PHP script on clicking a hyperlink

2007-08-24 Thread mike
On 8/24/07, Goltsios Theodore [EMAIL PROTECTED] wrote: the posted or got option buy using the $_REQUEST array ($_GET and $_POST are included in that like a less lame solution). Let's say you have a Please do not encourage the use of $_REQUEST. You might as well just tell people to enable

Re: [PHP-DB] Re: [PHP] Passing variables to a PHP script on clicking a hyperlink

2007-08-24 Thread Goltsios Theodore
I thought I just did a comment and suggested that it is a lame solution to use $_REQUEST plus I did not know witch of the two method (POST or GET) would be appropriate so I picked up the lame way :-) . mike wrote: On 8/24/07, Goltsios Theodore [EMAIL PROTECTED] wrote: the posted or got

Re: [PHP-DB] Re: [PHP] Passing variables to a PHP script on clicking a hyperlink

2007-08-24 Thread Suamya Srivastava
Thank you all for the help. I did not want to use dropdown box..that was the very reason i was wondering if I can pass the variables through a hyperlink. I used $_GET and it worked fine. However, as mentioned in the posts its not advisable to use $_REQUEST. Could you please elaborate on the

Re: [PHP-DB] Re: [PHP] Passing variables to a PHP script on clicking a hyperlink

2007-08-24 Thread Brian Rue
In this case $_POST would be the appropriate array, since your form is using the POST method: form method=post Goltsios Theodore wrote: I thought I just did a comment and suggested that it is a lame solution to use $_REQUEST plus I did not know witch of the two method (POST or GET)

Re: [PHP-DB] Re: [PHP] Passing variables to a PHP script on clicking a hyperlink

2007-08-24 Thread Suamya Srivastava
Hi.. in the settings, session.use_cookies is turned ON but session.trans_sid is turned OFF. do i need to enable this as well? by doing this can i disable the register_globals? - suamya Hi Me again Check on Your setting - ; Whether to use cookies.

Re: [PHP-DB] Re: [PHP] Passing variables to a PHP script on clicking a hyperlink

2007-08-24 Thread Johan de Wit
Hi Me again Check on Your setting - ; Whether to use cookies. session.use_cookies = 1 session variable is saved here if the user have cookies turned off it will still work if your have trans-sid turn on. BTW you don't have to use a dropdown radio buttons or

Re: [PHP-DB] Re: [PHP] Passing variables to a PHP script on clicking a hyperlink

2007-08-24 Thread Johan de Wit
Hi Here is my 2cents I will not use GET. If you want to pass a db name i would use POST. Because if you don't do something with the statusbar the the user can see the dbname if you use GET and i don't think that is a good thing. I'm working on an webbased app with a lot of db work and i learnt

Re: [PHP-DB] Re: [PHP] Passing variables to a PHP script on clicking a hyperlink

2007-08-24 Thread Johan de Wit
Hi I have sessions working like a charm, i use it for my user login vars and so on, here is the settings i used. register_globals = Off session.use_cookies = 1 and switch on session.trans_sid if you know that not all your users will have cookies turned on This worked for me Johan Suamya

[PHP-DB] Re: [PHP] Re: [PHP-DB] Re: [PHP] Passing variables to a PHP script on clicking a hyperlink

2007-08-24 Thread mike
On 8/24/07, Suamya Srivastava [EMAIL PROTECTED] wrote: Hi.. in the settings, session.use_cookies is turned ON but session.trans_sid is turned OFF. do i need to enable this as well? by doing this can i disable the register_globals? - suamya You need to make sure session_start() is called on

[PHP-DB] $db=new mysqli fails while $db=mysqli_connect succeeds in PHP/MySQL 5

2007-08-24 Thread Linux NG/Lists
From a php-general thread earlier: ?php $db=new mysqli('localhost','whil','secret','test'); ? generates: Fatal error: Call to undefined function new mysqli() in index.php on line 24 while ?php $conn = mysqli_connect(localhost,whil,secret,test); echo 'conn good: '.$conn.'

[PHP-DB] Looking for some help on a project!

2007-08-24 Thread Austin C
Hello, im working on making a custom CMS for my new site which will have tons of tutorials all about technology, and will have forums, and news, and stuff. But, its such a big undertaking, that I need help! If your willing to help me, I can give you FTP access, and database access. Just post here

RE: [PHP-DB] Looking for some help on a project!

2007-08-24 Thread Bastien Koert
Why not look at mambo or drupal to provide the framework? Be a lot quicker than coding it from scratch bastien Date: Fri, 24 Aug 2007 23:18:48 -0500 From: [EMAIL PROTECTED] To: php-db@lists.php.net Subject: [PHP-DB] Looking for some help on a project! Hello, im working on making a custom