Note that there are some explanatory texts on larger screens.

plurals
  1. POI cant display multiple results (even though the same exact code has worked for me in the past)
    primarykey
    data
    text
    <p>This is super strange.</p> <p>I used a portion of code for a new project I was working on, and for some reason the results won't display correctly. (They display, just one at a time though)</p> <p>It worked for me in the past and I really don't get why its not displaying like it should</p> <p>(Maybe it has to do with the fact I took a yearlong hiatus from coding and PHP 5 is wayyy different from the version I was used to)</p> <p>Here's the code</p> <pre><code>&lt;?php $search = $_GET['search']; $sfrom = $_GET['departure_label']; $sfromda = $_GET['txtdate1']; $sto = $_GET['arrival_label']; $stoda = $_GET['txtdate2']; $padt = $_GET['ddlPaxADT']; $pchd = $_GET['ddlPaxCHD']; $pinf = $_GET['ddlPaxINF']; $addition = $padt+$pchd+$pinf; $currency = $_GET['Currency']; //connect to database mysql_connect("localhost","poop","goldpoop"); mysql_select_db("moregoldpoop"); //echo outconstruct $sql = mysql_query("SELECT * FROM search_v WHERE Currency='$currency' AND rout_to='$sto' AND rout_from='$sfrom'ORDER BY date_avialable DESC"); $runrows = mysql_fetch_array($sql); { //get data $flightid = $runrows['flight_id']; $aseats = $runrows['seats_avialable']; $todate = strftime("%b %d, %Y %l:%M %p" ,strtotime($runrows['to_date'])); $date = strftime("%b %d, %Y %l:%M %p" ,strtotime($runrows['date_avialable'])); $from = $runrows['rout_from']; $to = $runrows['rout_to']; $acost = $runrows['adult_cost']; $ccost = $runrows['child_cost']; $cur = $runrows['currency']; $oth = $runrows['other_cost']; echo ""; ?&gt; &lt;li class="item clearfix"&gt; &lt;span id="cntntMiddle_ctl01_rptmain_lblFromt_0"&gt; &lt;table cellpadding="0" cellspacing="0"&gt; &lt;thead&gt;&lt;tr&gt; &lt;th class="price"&gt;Price&lt;/th&gt; &lt;th&gt;From&lt;/th&gt; &lt;th&gt;To&lt;/th&gt; &lt;th&gt;Depart&lt;/th&gt; &lt;/tr&gt; &lt;/thead&gt;&lt;tfoot&gt; &lt;tr&gt; &lt;td&gt;&lt;a class="more" href="#"&gt;Full Details&lt;/a&gt;&lt;/td&gt; &lt;td colspan="6"&gt; &lt;div class="select-wrap"&gt; &lt;p class="seats"&gt;&lt;strong&gt;&lt;?php echo $aseats; ?&gt;&lt;/strong&gt; &lt;span&gt;seats left&lt;/span&gt; &lt;em&gt;at this price&lt;/em&gt;&lt;/p&gt; &lt;button class="btn-select" type="button" onclick='return ray.ajax("#");'&gt;Select Flight&lt;/button&gt;&lt;/div&gt; &lt;/td&gt; &lt;/tr&gt; &lt;/tfoot&gt;&lt;tbody&gt; &lt;tr&gt; &lt;td class="price" rowspan="2"&gt;&lt;a style="font-weight: bold; cursor: pointer; text-decoration: none;" herf="#" onclick='return ray.ajax("#");'&gt;&lt;span style="font-size: 24px; font-weight: bold;"&gt;&lt;?php echo $acost; ?&gt;&lt;/span&gt;&lt;span style="font-size: 11px; margin-top: 2px; display: block; color: rgb(255, 255, 255); text-align: center; font-weight: normal;"&gt;per adult&lt;/span&gt;&lt;span style="font-size: 12px; margin-top: 2px; display: block; color: rgb(255, 255, 255); text-align: center; font-weight: normal;"&gt;(with fees)&lt;/span&gt;&lt;/a&gt;&lt;/td&gt; &lt;td&gt;&lt;?php echo $from; ?&gt;&lt;/td&gt; &lt;td&gt;&lt;?php echo $to ?&gt;&lt;/td&gt; &lt;td style="padding-right: 2px;"&gt;&lt;?php echo $date; ?&gt;&lt;/td&gt; &lt;/tr&gt; &lt;/tbody&gt; &lt;/table&gt; &lt;/span&gt; &lt;a id="cntntMiddle_ctl01_rptmain_lblResultDetails1_0" title="1" href="javascript:__doPostBack('ctl00$cntntMiddle$ctl01$rptmain$ctl00$lblResultDetails1','')" style="color: Black;"&gt;&lt;/a&gt;&lt;a class="close" href="#"&gt;Close&lt;/a&gt; &lt;div class="info clearfix"&gt; &lt;div class="info clearfix"&gt; &lt;h4&gt;Departing Flight&lt;/h4&gt; &lt;ul class="clearfix"&gt; &lt;li&gt; &lt;h5&gt;&lt;?php echo $from; ?&gt; to &lt;?php echo $to; ?&gt; &lt;?php echo $date; ?&gt;&lt;/h5&gt; &lt;ul&gt; &lt;li&gt;&amp;nbsp;&lt;/li&gt; &lt;li&gt;&lt;strong&gt;Flight #&lt;/strong&gt; - &lt;?php echo $flightid; ?&gt;&lt;/li&gt; &lt;li&gt;&lt;strong&gt;Departure Time – &lt;/strong&gt; &lt;?php echo $date; ?&gt;&lt;/li&gt; &lt;/ul&gt; &lt;/li&gt; &lt;/ul&gt; &lt;ul&gt; &lt;li style="padding-top: 5px;"&gt;&lt;span style="color: rgb(212, 22, 13); font-weight: bold; font-size: 11px; text-decoration: none;"&gt; Fare Breakdown&lt;/span&gt; &lt;/li&gt; &lt;/ul&gt; &lt;table class="more"&gt; &lt;tbody&gt; &lt;tr&gt; &lt;th&gt;Passenger&lt;/th&gt; &lt;th&gt;Fare&lt;/th&gt; &lt;th&gt; Taxes and Fees&lt;/th&gt; &lt;th&gt;Qty&lt;/th&gt; &lt;th&gt;Total Cost&lt;/th&gt; &lt;/tr&gt; &lt;/tbody&gt;&lt;tbody&gt; &lt;tr&gt; &lt;td&gt;Adult&lt;/td&gt; &lt;td style="color: rgb(100, 100, 100); font-size: 11px; font-weight: bold;"&gt;&lt;?php echo $acost; ?&gt;&lt;/td&gt; &lt;td&gt;&lt;?php echo $oth; ?&gt;&lt;/td&gt; &lt;td id="paxAdtTd"&gt;1&lt;/td&gt; &lt;td&gt;&lt;?php echo $acost; ?&gt;&lt;/td&gt; &lt;/tr&gt; &lt;tr&gt; &lt;td&gt;&amp;nbsp;&lt;/td&gt; &lt;td&gt;&amp;nbsp;&lt;/td&gt; &lt;td&gt;Cost of Sale(&lt;?php echo $cur; ?&gt;)&lt;/td&gt; &lt;td&gt;&amp;nbsp;&lt;/td&gt; &lt;td style="color: rgb(100, 100, 100); font-size: 14px; font-weight: bold;"&gt;&lt;?php echo $acost; ?&gt;&lt;/td&gt; &lt;/tr&gt; &lt;/tbody&gt; &lt;/table&gt; &lt;br /&gt; &lt;span style="font-weight: bold; padding-top: 10px;"&gt; *Additional airline fees for baggage may apply&lt;/span&gt; &lt;div class="select-wrap"&gt; &lt;p class="seats"&gt;&lt;strong&gt;&lt;?php echo $aseats; ?&gt;&lt;/strong&gt; &lt;span&gt;seats left&lt;/span&gt; &lt;em&gt;at this price&lt;/em&gt;&lt;/p&gt; &lt;button class="btn-select" type="button" onclick='return ray.ajax("https://res.com/checkout.aspx?recommendation=1&amp;subset=1&amp;supplier=53&amp;page=flightconfirm",1,this);'&gt;Select Flight&lt;/button&gt;&lt;/div&gt; &lt;/ul&gt; &lt;/div&gt; &lt;/div&gt; &lt;/li&gt; &lt;?php } ?&gt; </code></pre> <p>I just wanna know the main reason why it worked before and not now</p> <p>Thanks guys</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload