Hello,
I am trying to code a project and ran into a brick wall with one of my pages. I am pretty new at php/mySQL and can not figure this out. Now I know that you are not going to sit there and type my whole script out for me. That is NOT what I am asking. I need pointers, links to tutorials, or whatever help you can get me. I appreciate it very much!
First off, I am recoding a site I created a little while ago in pure HTML to php. This site is a help wanted site and it has had massive amounts of hits and requests to put up listings. I have the pages to submit a listing, write that to the database, and one to show the results in a raw format. However, I am running into two problems. One is that I want to code the main page to just be a mysql query. This means that I want it to show just the company name and position available, then have a button to click to get the rest of the info about the job listing in a separate pop-up window. I can not seem to find code, tut or anything of the like about this.
Second problem, in my raw data results (plan table showing database contents) I need a link that will remove the entry. I have tried a couple of scripts and messed up my code further. I was wondering if anyone knows of something that describes this is great detail. It is all in a table.
Here is some of my code for the table with the DB contents:
Code: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>View All Job Listings</title>
</head>
<body>
<?php
require 'dbconnect.inc';
mysql_select_db("coushatta", $con);
$result = mysql_query('SELECT * FROM jobs', $con);
echo "<table border='1'>
<tr>
<th>ID</th>
<th>Business Name</th>
<th>Contact Name</th>
<th>Phone Number</th>
<th>Fax Number</th>
<th>Email Address</th>
<th>Position Open</th>
<th>Open</th>
<th>Filled</th>
<th>Closed</th>
<th>Listing Content</th>
<th>Delete?</th>
</tr>";
while($row = mysql_fetch_array($result))
{
echo "<tr>";
echo "<td>" . $row['ID'] . "</td>";
echo "<td><a href='" . $row['ID'] . ".html'>" . $row['business_name'] . "</a></td>";
echo "<td>" . $row['contact_name'] . "</td>";
echo "<td>" . $row['phone_number'] . "</td>";
echo "<td>" . $row['fax_number'] . "</td>";
echo "<td>" . $row['email_address'] . "</td>";
echo "<td>" . $row['position_open'] . "</td>";
echo "<td>" . $row['learnmore'];
if ( $row['learnmore'] == TRUE ) {
echo "";
} else {
echo "";
}
"</td>";
echo "<td>" . $row['filled'];
if ( $row['filled'] == TRUE ) {
echo "";
} else {
echo "";
}"</td>";
echo "<td>" . $row['closed'];
if ( $row['closed'] == TRUE ) {
echo "";
} else {
echo "";
}"</td>";
echo "<td>" . $row['listing_content'] . "</td>";
echo "</tr>";
}
echo "</table>";
mysql_close($con);
?>
</body>
</html>
cstdatomic (c++0x std::atomic) / g++ 4.4
Hello,
Changing color in GD via variable?
Hey guys, I'm new here. x)I'm very much a noob when it comes to PHP, but I'm trying to learn as much as I can. I've been writing a script which will generate a new image after submitting some hex
Dynamically set AccordianPane Header
I have an accordian on my master page. I'd like to be able to dynamically change the header on different pages. The I can't figure out how to do it or if it's even possible. When I access the
Using loop to count number of entries
I'm writing a program that must ask user to type in numbers. After each entry, the program has to report the cumulative sum of the entries to date. The program should terminate when user enters 0.
$_POST variable un-useable
I'm trying to use a $_POST variable in a mysql update statement but i can't use it for some unknown reason i can echo the variable and it outputs the correct value but i cannot use that variable in
Facebook status update API
Hello,So, I'm trying to create my first Facebook application with PHP.Basic ideas for my application:My website includes feature called “tip of the week" and i would like to create a code
php not working written for consumption of slots
1. Here is the function where i will be allowed to consume the slot booked by me.2. Here i check the unique reservation id, current server time & date.3. Then i ask the user to enter the
Preg_match unknown modifyer
Hello,Im trying to write a little script for my forums i need to get the reply from my forums. Im trying thisCode: $pattern = '/<span
timezone change with date()
so i put all my times for posts in my made from scratch forum(not phpbb3 or sm)in my mysql db using the time()and when i show the time on webpages i use the date('ymd/h:i:s', $time) kind of thing.now
Looking for help on using joining mysql tables and php....
Does anyone have any good links to references on how to pull mysql data, through joining tables and how one can use php to handle the results? I need some solid clear examples to get me going in the