Jump to content

MrAdam

Members
  • Posts

    489
  • Joined

  • Last visited

Posts posted by MrAdam

  1. haha. i had very similar problems installing them ! My friend reccomended i uninstalled them and used xampp. It installs everything in one and has it's own control panel. Far better I thought!Also i've found that it doesn't slow my computer down at all - and im using a pretty.. poo.. computer.Good luck !

  2. In your insert query, you didn not include the field names:

    mysql_query("INSERT INTO users-online (field1,field2) VALUES ('".$random."', '".$_SERVER['REMOTE_ADDR']."')");

    Rename field1 and field2 obviouslly. I assume you have connected to the internet earlier in your script?

  3. Before a freind reccomended me xampp, i was messing round following a tutorial to try and install apache, php and mysql all sperate, then get them all working with each other - and i was completely lost. Xampp is really simple, just download it and everything is sorted out in one simple installation. There are a few extra things available with it, like "Mercury" and "FileZilla", but i had no idea what they were, so had no use for them.Good luck !

  4. you could create a sort of php image template file. when you open the window, open it with a url like:"image.php?img=images/img1.jpg"that way there will only be 1 file for all the images, and you could still use the auto resize script on that webpage.a script i made not so long ago to do almost the same thing:

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html><head><title>Image: <?php print $_GET['img']; ?></title><meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"><style type="text/css">body {	margin: 0px;}</style></head><body><img src="<?php print $_GET['img']; ?>" alt="" /></body></html>

    ...it's fairly basic, but does the job! Just remember you need to have PHP enabled on your webserver/host - and save it as a ".php" file.Adammm

  5. oh right, just that in the url, if you have "?var1=Hello&var2=" it will recognise var2 as not set. i pressumed it would be the same in other circumstances too.

  6. <?php$con = mysql_connect("host", "user", "pass") or die("Could not connect to database because ".mysql_error());if(!mysql_select_db("database",$con)) die("Could not connect to database because ".mysql_error();$query = mysql("SELECT * FROM table ORDER BY unique_field DESC LIMIT 10");while ($rows=mysql_fetch_array($query)) {print $rows['field_name'].'<br />'.$rows['another_field'].'<br /><br />';}?>i've not tested it, but it should work. Just replace host, user, pass and database to connect. Then obviouslly change the values in the query.

  7. Just let me get it straight, you are setting an event which is yet to happen, by a date & time? then calculating the time until that event?You see, you have:

    I am trying to show a time left until a certain event
    - futureand then the text your printing says:
    Time until last signup
    - past
  8. I think he means like forums have: "1 User(s) are reading this topic..." sort of thing, if so stone, follow justsomeguy's advice...

  9. as far as i know you can't use ";" to seperate them. There may be a way of allowing it i'm not aware of though. Where did you see it being used? I've seen it being used on .cgi files before?

  10. you could use php ..when setting the frames, your banner thing across the top could contain a link that is generated using PHP.for example:"toppage.php?url=http://www.google.co.uk"then in between the link have like:

    <a href="<?php print $_GET['url']; ?>" target="_top">Remove this frame</a>

    <?php => opens the php scriptprint => prints text to the page$_GET['url']; => the value of the 'url' parameter within the url?> => closes the php scriptsorry if you think i was being too condescending there.

  11. quite simple really. Any tags you don't want removing (so anything required for bbcode) you just add to the function parameter:

    $tekst = strip_tags($tekst, '<p>,<span>');

×
×
  • Create New...