Jump to content

chutchick

New Members
  • Posts

    4
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

chutchick's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Ive got it down to: if($_SESSION["ledger"]) { $led = $_SESSION["ledger"]; $sql = mysql_query("SELECT * FROM employee_works WHERE employee_id = $led"); while($row = mysql_fetch_array($sql)) <--this is line 113 { echo "<tr>"; echo "<td align='center' width='300'>" . $row['employee_work_des'] . "</td>"; echo "<td align='center' width='300'>" . $row['employee_work_time'] . "</td>"; echo"</tr>"; } echo "</table>"; its giving an error: Warning: mysql_fetch_array() expects parameter 1 to be resource, string given in C:\xampp\htdocs\beta\function\ledger.php on line 113
  2. so lets say i assign a $session[id] = 4; then i call a javascript function to close the child window and window.opener.reload() to refresh the parent window. then on the parent window i add something like: if($session[id]) { //code for employee_works here } would this be ok?
  3. I cant figure out how to populate the parent window. How do I pass a php variable from child to parent and then using that variable to "auto-query" on the parent window. Is that at all possible with a Server side lang?
  4. Good day and Merry Christmas to all, I just spent a good time of my christmas eve trying to figure out this problem. I hope one of you santas would be so kind as to help me with it. First off I have two tables; employee and employee_works both connected via employee_id key. Basically I have a parent window we'll call parent.php. inside the parent page is a search button that once clicked will open a child window we'll call child.php inside the child page is a list, lets say employees with name, employee_id, etc. My main concern is this: How do I populate parent.php based off the employee selection I made in the child window. Example: -Access parent.php -Click on search -Click on [iD: 004] [NAME: JOHN SMITH] [PHONE: 1233456] [DATE HIRED: JULY 16, 1992] <---format of a row in child.php -child.php automatically closes and parent.php now shows all data from employee_works with the employee_id = 004 Is this even possible? I know this is vary vague and would be willing to explain more if needed. My website is built mostly on javascript and php.
×
×
  • 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.