Jump to content

url problems?


Codeman0013

Recommended Posts

Ok here is my thing i have done some error testing and found it has somethign to do with how the information is being taken from the url if i set a default value it works fine but if i dont then it shows up blank can anyone trouble shoot the following code and see if i'm pulling from the url wrong?

[code=php:0]// begin Recordset
$colname__rs_employeeinfo = '1';
if (isset($HTTP_GET_VARS['employeeID'])) {
  $colname__rs_employeeinfo = $HTTP_GET_VARS['employeeID'];
}
$query_rs_employeeinfo = sprintf("SELECT * FROM employees WHERE employeeID = %s", GetSQLValueString($colname__rs_employeeinfo, "int"));
$rs_employeeinfo = $befh->SelectLimit($query_rs_employeeinfo) or die($befh->ErrorMsg());
$totalRows_rs_employeeinfo = $rs_employeeinfo->RecordCount();
// end Recordset

// begin Recordset
$colname__rs_employeeqa = '-1';
if (isset($HTTP_GET_VARS['employeeID'])) {
  $colname__rs_employeeqa = $HTTP_GET_VARS['employeeID'];
}
$query_rs_employeeqa = sprintf("SELECT * FROM staffanswers, staffquestions WHERE staffanswers.employeeID = %s AND staffanswers.staffquestionID = staffquestions.staffquestionID", GetSQLValueString($colname__rs_employeeqa, "int"));
$rs_employeeqa = $befh->SelectLimit($query_rs_employeeqa) or die($befh->ErrorMsg());
$totalRows_rs_employeeqa = $rs_employeeqa->RecordCount();
// end Recordset[/code]
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.