Hi there, I've developed the following php code from scratch, but I think there are some syntax errors that are not allowing it to work, can some kind soul here take a look and see if there is anything blatently obvious as far as why it's not functioning?
I would greatly appreciate it.
PHP Code:
$down = ""; $row = ""; $buttons = ""; $pdf = ""; $firstC = ""; $getTabs = "SELECT type_name, behavior, event.shortName from content_type inner join page on page.contentID = content_type.ID left join behaviors on behaviors.defID = content_type.ID inner join event on event.ID = page.evID where evID = '".$_GET['i']."' group by type_name order by content_type.page_order ASC"; $doTabs = mysql_query($getTabs); if(mysql_num_rows($doTabs) > 0) { while($arTabs = mysql_fetch_array($doTabs)) { if($firstC=="" && $arTabs[0] != "PDF" && $arTabs[0] != "Whitepaper" && $arTabs[0] ! = "Podcast"){$firstC = $arTabs[0];} if($arTabs[0] != "Sponsor") { $tabs = str_replace("_"," ",$arTabs[0]); if($tabs == "Register") { $buttons.= "<h2><a href='event_register.php? i=".$_GET['i']."&t=".$tabs."'>PRICING & REGISTRATION</a></h2></a><br><hr><br>"; } elseif($tabs == "PDF") { if(is_numeric(substr($short,-1))){$short = substr($short,0,-1);} $style = file_get_contents('../'.$tabs.'/style/style.inc'); $test = explode('|',$style); if($test[2]!="") { $pdf.= "<a href='".$test[2]."?i=".$_GET['i']."' onClick='NewWindow(this.href,\"".$tabs."\",\"900\",\"800\",\"yes\");return false;' >".$test[0]."</a>"; } else { $pdf.= "<a href='../".$arTabs[1]."/".$arTabs[2].$test[1]."' onClick='NewWindow(this.href,\"".$tabs."\",\"900\",\"800\",\"yes\");return false;' >".$test[0]."</a>"; } } elseif($tabs == "Podcast" || $tabs == "Whitepaper") { $style = file_get_contents('../'.$arTabs[1].'/style/style.inc'); $test = explode('|',$style); if($test[2]!="") { $down.= "<h2><a href='".$test[2]."?i=".$_GET['i']."' onClick='NewWindow(this.href,\"".$tabs."\",\"900\",\"800\",\"yes\");return false;' >".$test[0]."</a></h2>"; } else { $down.= "<h2><a href='../".$arTabs[1]."/".$arTabs[2].$test[1]."' onClick='NewWindow(this.href,\"".$tabs."\",\"900\",\"800\",\"yes\");return false;' >".$test[0]"</a></h2>"; } } else { if(strstr($tabs," ") !== FALSE) { $buttons .= "<div class='autosize'><div><h2><a href='event_listing.php?i=".$_GET['i']."&t=".$arTabs[0]."'>".strtoupper($tabs)."</a></h2></div></div><hr><br>"; } else { $buttons .= "<div class='autosize'><div><h2><a href='event_listing.php?i=".$_GET['i']."&t=".$tabs."'>".strtoupper($tabs)."</a></h2></div></div><hr><br>"; } } } }
|