Jump to content

Recommended Posts

I m working on a site that someone else built. The former programmer used a echo of a sql query to produce a scroll effect across the screen. For some reason its not working.

 


<?php require ('qmbl.php');
$sqlstr = "select i_html from SiteInfo where i_type = 'NEWS_SCROLL'";
$rs_scroll = mysqli_query($sqlstr, $cid);
$scroll = mysql_result($rs_scroll,0,0);

$sqlstr = "select team_id, t_name from Team t, Settings s where t.t_season = s.cur_season order by t_name";

$rs_teams = mysql_query($sqlstr, $cid);

$count=0;

$templateTeams="";

while($row = mysql_fetch_assoc($rs_teams)){$templateTeams .= '<a href="team.php?t='.$row['team_id'].'">'.$row['t_name'].'</a><br />';

} //end while ?>

 

 

Any help will be greatly appreciated.

Link to comment
https://forums.phpfreaks.com/topic/269488-echo-of-a-sql-str-doesnt-work/
Share on other sites

$rs_scroll = mysqli_query($sqlstr, $cid);

 

^^^ Someone added an i to your mysql_query() statement. The mysql (no i) and mysqli (with an i) statements cannot be mixed on the same connection and it takes more than just adding an i to convert from mysql to mysqli statements.

Like I said before, the scroll effect is in a different language, not the one you posted. It's in a whole other file, processed on another computer, and works in a different way.

 

Get firebug or chrome developer tools and check the JS console for errors.

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.