Jump to content

maxudaskin

Members
  • Posts

    628
  • Joined

  • Last visited

Everything posted by maxudaskin

  1. Where'd you get your smilies from?
  2. Is it possible to 'filter' a string using an array of what I called shortcuts and image locations and have the location replace the shortcut (if found)... For example; "Hi! : )" would show "Hi! ".
  3. I have a database with all of my smilies for my forum, and I was wondering why it did this... Database Error... The real post is This is some sample text inserted under OOM0100 Michael Bonanno's name. (second post) $topicid = $_GET['t']; $namesql = mysql_query("SELECT * FROM forum_posts WHERE topicid = '{$topicid}'"); $postsql = mysql_query("SELECT * FROM forum_posts WHERE topicid = '{$topicid}'"); $smilies_query = mysql_query("SELECT * FROM smilies"); $smilies_array = mysql_fetch_array($smilies_query); while($namerow = mysql_fetch_array($namesql)){ define('name',$namerow['title']); } ?> <table style="border-top:1px #FFFFFF solid" width="100%" border="0" cellspacing="0" cellpadding="0"> <tr> <td height="20" colspan="2" bgcolor="#333355"><span class="style26"> <?php echo constant('name'); ?></span></td> </tr> <?php while($posts = mysql_fetch_array($postsql)){ ?> <tr> <td width="17%" rowspan="3" valign="top" nowrap="nowrap" bgcolor="#EFF4FB" style="border-bottom:1px #333355 solid; border-right: 1px #333355 solid; padding-left:5px;"><br /> OOM<?php echo $posts['pid']; ?><br /> <?php echo $posts['name']; ?><br /> <br /> --- Hours<br /> [php Rank]<br /> [php Position]<br /> <br /> <br /> </td> <td width="83%" height="15" valign="top" bgcolor="#F6F6F6" style="padding-left:5px"> <?php echo '<em>Posted on '.$posts['date'].' at '. $posts['time'] .'</em>'; ?></td> </tr> <tr> <td valign="top" style="padding-left:5px; padding-top:3px;" bgcolor="#FFFFFF"><?php echo strtr($posts['text'],$smilies_array); $smilies_array; ?></td> </tr> <tr> <td height="39" bgcolor="#FFFFFF" style="border-bottom:1px #333355 solid; padding-left:5px;">Signature </td> </tr> <?php } ?> </table> I made it echo the implode of the array and this is what is said: ../comm/smilies/smile.gif../comm/smilies/smile.gif[smile][smile]:)
  4. Yes... I wouldn't bother posting here without trying out all my ideas first, but I know, you just wanted to make sure before we got into something complicated.
  5. Is it possible to put an image in a dropdown menu? If not, what is the best alternate? I want it to be something that people can use to find an emote (smilies) and find the shortcut for it. Eg. [smiley] or : ) would show
  6. I can see someone needing that if they are doing websites that are stored in databases instead of HTML files... waste of space? I don't know, I think it takes less space to put a full HTML file coded in a database rather than a seperate HTML file.
  7. Is there a way to replace a space with an image?
  8. How would I replace the character with a picture?
  9. MySQL Query: ['OOM0100'],['Max Udaskin'],['CYYZ-CYUL']['763']['Departing'] To output with the letters, and a space between each array thing....
  10. Any ideas?
  11. I mean like, I wanted it to explode (except put every letter instead of every word or whatever seperated by a colon for example)... then check the letter and the case. After that, it will echo an image of a letter in a font only I have...
  12. Is it possible for PHP differentiate between an uppercase and lowercase letter?
  13. How could I use a font that I uploaded to my server on my site?
  14. How could I make it so it doesn't show all the page numbers, but show the first 4 and the last 4?
  15. What language should I use to interact with FS9 and FSX and make a program to get the phases of flight and interact with a PHP script to insert it with the MySQL server.
  16. start_session() is called way before this PHP, but there is only HTML between them.
  17. <?php if(!$logged_in){ echo 'You are not logged in'; }else{ if($_SESSION['type'] != 1){ $action = $_GET['action']; $pirep = $_GET['pirep']; $user = 'OOM'.$_SESSION['username'].' '.$_SESSION['name']; $date = ''; if(!empty($action) && !empty($pirep)){ if($action = 'accept'){ $acceptsql = mysql_query("UPDATE `zoomdb`.`pireps` SET `type` = '0' WHERE `pireps`.`pirepid` ='{$pirep}' LIMIT 1"); if($acceptsql){ echo 'Application Accepted'; }else{ die('ERROR: Application not accepted due to internal error.'); } }elseif($action = 'deny'){ $denysql = mysql_query("UPDATE `zoomdb`.`pireps` SET `type` = '2' WHERE `pireps`.`pirepid` ='{$pirep}' LIMIT 1"); }else{ echo 'You have specified an unknown action.'; } }else{ echo 'You do not have either an action or a pirep specified or both.'; }}} ?> It does not output anything, but it does not give an error either... no actions at all.
  18. Try <?php $query_WADAALFL = sprintf("SELECT * FROM ALFL WHERE visitorTeam LIKE '%%%s%%' OR '-1' = '%s' OR homeTeam LIKE '%%%s%%' OR '-1' = '%s' OR rainout = %s OR '0' = '%s' ORDER BY ID ASC", $ParamvisitorTeam_WADAALFL,$ParamvisitorTeam_WADAALFL,$ParamhomeTeam_WADAALFL,$ParamhomeTeam_WADAALFL,$Paramrainout_WADAALFL,$Paramrainout_WADAALFL; ?>
  19. Yeah, just caught that.... thanks.
  20. Just incase you were wondering... I changed topicid to topic and it works... Thanks
  21. PID is Pilot ID.
  22. $query = "SELECT * FROM forum_posts WHERE topicid = '0' && forumid = '{$forumid}' LIMIT $offset,$limit"; $result = mysql_query($query) or die("Error (QUERY): " . mysql_error() . "<p>With Query:<br>$query<p>"); But nothing displays...
  23. The problem is, is that there should be two matches...
  24. And now it echo's 'Nothing to Display' <?php $query_count = "SELECT count(*) FROM forum_posts WHERE topic = '0'"; $result_count = mysql_query($query_count) or die("Error: (result_count) " . mysql_error()); $totalrows = mysql_result($result_count, 0, 0); $numofpages = ceil($totalrows/$limit); if (isset($_GET['page'])){ $page = $_GET['page'];} else{ $page = 1;} $offset = ($page - 1) * $limit; $query = "SELECT * FROM forum_posts WHERE topicid = '$topicid' LIMIT $offset,$limit"; $result = mysql_query($query) or die("Error (QUERY): " . mysql_error() . "<p>With Query:<br>$query<p>"); if (mysql_num_rows($result) == 0) { exit("Nothing to Display!"); } ?> <table style="border-top:1px #FFFFFF solid" width="100%" border="0" cellspacing="0" cellpadding="0"> <tr> <td width="3%" height="20" align="center" valign="middle" bgcolor="#333355"><span class="style26"></span></td> <td width="54%" height="20" align="center" valign="middle" bgcolor="#333355"><span class="style26">Subject</span></td> <td width="7%" height="20" align="center" valign="middle" bgcolor="#333355"><span class="style26">Posts</span></td> <td width="16%" height="20" align="center" valign="middle" bgcolor="#333355"><span class="style26">Author</span></td> <td width="20%" height="20" align="center" valign="middle" bgcolor="#333355"><span class="style26">Last Post By </span></td> </tr> <?php $forumid = $_GET['f']; $topicssql = mysql_query("SELECT * FROM forum_posts WHERE topic = '0' && forumid = '{$forumid}'") or die("Error (TOPICSSQL): " . mysql_error());; while($topics = mysql_fetch_array($result)){ $topicid = $topics['topicid']; $type = $topics['type']; $type_img = constant($type); $postssql = mysql_query("SELECT * FROM forum_posts WHERE topicid = '{$topicid}'") or die("Error ($POSTSQL): " . mysql_error());; $posts = mysql_num_rows($query); echo "<tr onClick=\"MM_goToURL('parent','forum.php?t=".$topicid."');return document.MM_returnValue\" style=\"background-color:#EFF4FB;\" onMouseOver=\"this.style.backgroundColor='#E5EEF9';\" onMouseOut=\"this.style.backgroundColor='#EFF4FB';\">"; echo '<td class="cursor_link" align="center" valign="middle" style="border-bottom:1px #333355 solid" height="50px">'.$type_img.'</td>'; echo '<td class="cursor_link" align="left" valign="middle" style="border-bottom:1px #333355 solid" height="50px">'.$topics['title'].'</td>'; echo '<td class="cursor_link" align="center" valign="middle" style="border-bottom:1px #333355 solid" height="50px">'.$posts.'</td>'; echo '<td class="cursor_link" align="center" valign="middle" style="border-bottom:1px #333355 solid" height="50px">OOM'.$topics['pid'].' '.$topics['name'].'</td>'; echo '<td class="cursor_link" align="center" valign="middle" style="border-bottom:1px #333355 solid" height="50px"> </td>'; echo '</tr>'; } if ($page > 1) { echo("<a href=\"forum.php?f=".$_GET['f']."&page=".($page-1)."\">PREV</a> "); } else { echo("PREV "); } for ($i=1; $i<=$numofpages; $i++) { if ($i == $page) { echo "$i "; } else { echo "<a href=\"forum.php?f=".$_GET['f']."&page=$i\">$i</a> "; } } if ($page < $numofpages) { echo("<a href=\"forum.php?f=".$_GET['f']."&page=".($page+1)."\">NEXT</a>"); } else { echo("NEXT"); } ?> <tr> <td height="45" colspan="2" align="left"> <?php if($logged_in){ ?> <table width="156" border="0" cellspacing="0" cellpadding="2"> <tr> <td align="center"><a href="forum.php?a=post"><div class="status_message status_blue">Post New Thread</div></a></td> </tr> </table> <?php } ?></td> <td align="left" colspan="4"> </td> </tr> </table>
×
×
  • 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.