query($appnamequery); $theApp=utf8_encode(mysql_result($resultAppName,0,$lang)); $queryDivs="SELECT * FROM `Links` WHERE Lang = \"".$lang."\""; $resultDivs=$conn->query($queryDivs); $numDivs=mysql_numrows($resultDivs); $queryLinksText="SELECT * FROM `LinkTexts` WHERE Lang = \"".$lang."\""; $resultDivsLinkTexts=$conn->query($queryLinksText); $mainText = utf8_encode( mysql_result($resultDivsLinkTexts,0,"MainText") ); $headerTextQuery="SELECT * FROM `Header` WHERE App = \"".$appname."\""; $resultHeader=$conn->query($headerTextQuery); $headerText=mysql_result($resultHeader,0,$lang); $menuQuery="SELECT * FROM `NavMenu` WHERE AppId = \"".$appname."\" AND Lang = \"".$lang."\""; $resultMenu=$conn->query($menuQuery); $numMenus=mysql_numrows($resultMenu); $footerTextQuery="SELECT * FROM `Footer` WHERE AppId = \"".$appname."\" AND Lang = \"".$lang."\""; $resultFooter=$conn->query($footerTextQuery); $footerText= utf8_encode( mysql_result($resultFooter,0,"Text") ); mysql_close(); ?> <? echo "$theApp"; ?>