Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $uid = $_SESSION['id'];
- #First I assign the query to an object.
- $sql = "SELECT email from users where id='$uid'";
- #i assign the result of the query to an object, which in turn runs the query
- $result=mysql_query($sql);
- #checking my sql just for this and giggles.
- #echo $sql;
- #echo "<br />";
- #assigns the resulting array to an object..doesnt have to be query_row..it could be called anything..
- $query_row=mysql_fetch_array($result);
- #echos out the result of the array, more specifically the result within the coloumn email
- #echo $query_row[email];
- #again im assigning the query to an object
- $sql = "SELECT bid from manifest where uid='$uid'";
- #result of the query to an object again, which in turn runs the query
- $result=mysql_query($sql);
- #setting of the array to an object
- $query_row=mysql_fetch_array($result);
- #just echoing the secondary query
- #echo $sql;
- #and pulling the info.
- #echo $query_row[bid];
- $bid = $query_row[bid];
- # $pullbooking = "SELECT * from bookings where id='$bid'" ;
- #$sqlbig = "SELECT bookings.title, bookings.date, bookings.start_time, bookings.end_time, bookings.venue, bookings.city, bookings.state, bookings.country, bookings.created_at, bookings.updated_at, bookings.creator_id, bookings.cover, bookings.age_limit, bookings.description
- # FROM bookings
- # INNER JOIN manifest ON bookings.id = manifest.bid
- # WHERE manifest.uid ='$uid'";
- $sqlbig = "SELECT bookings.title, bookings.date, bookings.start_time, bookings.end_time, bookings.venue, bookings.city, bookings.state, bookings.country, bookings.created_at, bookings.updated_at, bookings.creator_id, bookings.cover, bookings.age_limit, bookings.description
- FROM bookings
- INNER JOIN manifest ON bookings.id = manifest.bid
- WHERE manifest.uid ='$uid'";
- $bookingresult = mysql_query($sqlbig);
- $bookingarray=mysql_fetch_array($bookingresult);
- echo "<br><br><br>";
- $bookingresult = mysql_query($sqlbig);
- $row = mysql_fetch_assoc($bookingresult);
- do{
- echo $row["title"];
- echo "<br />";
- echo $row["venue"];
- echo "<br />"
- }
- while ($row = mysql_fetch_assoc($bookingresult));
- $bookingresult = mysql_query($sqlbig) or die(mysql_error());
- if (mysql_num_rows($bookingresult) > 0) {
- ?><table cellspacing="0" cellpadding="2">
- <thead>
- <tr>
- <th>Title</th>
- <th>Date</th>
- <th>Start Time</th>
- <th>End Time</th>
- <th>Venue</th>
- <th>City</th>
- <th>State</th>
- <th>Country</th>
- <th>Cover</th>
- <th>Age Limit</th>
- <th>Description</th>
- </tr>
- </thead>
- <tbody><?
- while ($row = mysql_fetch_assoc($bookingresult)) {
- ?><tr>
- <td><?= $row["title"] ?></td>
- <td><?= $row["date"] ?></td>
- <td><?= $row["start_time"] ?></td>
- <td><?= $row["end_time"] ?></td>
- <td><?= $row["venue"] ?></td>
- <td><?= $row["city"] ?></td>
- <td><?= $row["state"] ?></td>
- <td><?= $row["country"] ?></td>
- <td><?= $row["cover"] ?></td>
- <td><?= $row["age_limit"] ?></td>
- <td><?= $row["description"] ?></td>
- </tr>
- <?
- }
- }
- else {
- echo "aint shit here nigga";
- }
- ?>
Add Comment
Please, Sign In to add comment