Jump to content

joethetree

New Members
  • Posts

    7
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

joethetree's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Turns out the problem was that notepad++ was in ANSI/UTF-8 instead of normal ANSI, changed it and it worked. Though yes, I do need to address the problem before its made instead of creating a hacky fix. UTF-8 for databases, yeah? Also, how do I go about backing up a database? Thanks everyone for your replies
  2. Hey, I've been obsessing over this for hours now, probably have just missed something simple. But. I've got a file saved in a mysql DB - which I'm then opening and echoing. When it gets uploaded the euro sign '€' gets turned into this: '€' (without quotes). So I thought "great, I'll just str_replace() it". I tried this on a test script, and it worked. However, when I went to add this to my main script - it didn't work. str_replace just won't replace it. strpos() won't find it either. Anyone got any ideas? I just can't see what I'm doing wrong. The code: $script = $row['script']; //from sql $script = str_replace(array("€","£"),array("€",'"'),$script); echo $script; Thanks tree
  3. I still need to send the request to another script, just not go to that script. So I need the data back from the request, like doing a file_get_contents() on the page, but with the response from a submitted form. tree
  4. Hey, I'm trying to send a form input to a page, and then get the response (as in, the body) from that page without leaving my PHP script. So instead of when you normally submit a form and it will take you to the 'action="/somepage"'. I want it to get that information and bring it back to the original page. No navigation should happen. I'm almost certain this is possible, but the only thing I've found at the moment requires a custom addon - which, isn't on most hosting sites. Sorry if I haven't described this very well, but any help would be appreciated Thanks tree
  5. I guess its my host then. Yeah, I've just run it through XAMPP and it works. Thanks for the help Though I accidentally spammed the server for about 0.25 seconds, and am now banned
  6. Hey, I've had this problem for a couple days now, and haven't been able to work it out. I'm trying to connect to the Gamesurge IRC using PHP - though the code I am using times out and can't connect. I thought it was my code, however I have searched the web for working codes and they all *seem* to do the same basic thing as mine. So if anyone has any ideas as to why I am getting a timeout, I would appreciate it. The code I'm using. <?php error_reporting(E_ERROR); $cfg = array( "server" => "irc.gamesurge.net", "channel" => "#wiremod", "port" => 6667, "name" => "thetree PHP" ); echo "Connecting to " . $cfg["server"] . " on port " . $cfg["port"] . "<br/>"; $socket = fsockopen($cfg["server"], $cfg["port"], $errno, $errstr, 5); if (!$socket) { echo("Error[$errno]: $errstr...<br/>"); } else { echo "Socket connection successful..<br/>"; } fclose($socket); ?> Hosted file: http://joethetree.lil.org.uk/socket.php Thanks thetree
×
×
  • 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.