Jump to content

Storing the result and calling it.


gokhul

Recommended Posts

Hello,

Can anyone tell me how can i save a variable in the results page and call it into another php page for a query.

 

I got the result (KEGG_ID and Gene_Name) page from the following query

 

import_request_variables('p','p_');

$connect=mysql_connect('localhost','gkkilaru','gkkilaru')

or die('could not open:'. mysql_error());

mysql_select_db('gkkilaru_db'); /* Identify database */

$result=mysql_query("SELECT * FROM HPD WHERE $p_searchtype='$p_search'");

 

 

I need to have additional data related to the variable Gene_Name in the result page in another page. I tried this

 

import_request_variables('p','p_');

$connect=mysql_connect('localhost','gkkilaru','gkkilaru')

or die('could not open:'. mysql_error());

mysql_select_db('gkkilaru_db'); /* Identify database */

$result=mysql_query("select * from HPD1 where HPD1.Gene_Name = (SELECT Gene_Name FROM HPD WHERE KEGG_ID='$p_search')");

 

But,I am getting a error like undefined variable p_search at line 13.

Can anyone tell me how to store the Gene_Name in the result page and query for additional data using it?

Link to comment
https://forums.phpfreaks.com/topic/154085-storing-the-result-and-calling-it/
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.