Jump to content

Recommended Posts

Posted (edited)

I'm having some troubles with the FTP.au3 UDF, I have a server, and tested it locally and outside my connection and it works fine, but I cant get my script to work. Its supposed to make a file every time its run, and place the file onto the FTP server, but, it wont. any ideas why?

P.S. This program is for traking my USB flash incase its stolen

The FTP's home dir is "IPACESS" and has 1 sub dir, "logs"

EDIT: also, the port is 21, i dunno if that helps... you can test the FTP if you want to, you can use the user/pass below

#include <Inet.au3>

#include <Date.au3>

#include <FTP.au3>

$PublicIP = _GetIP()

$CompName = @ComputerName

$Date = _NowCalc()

$User = @UserName

$Domain = @LogonDomain

IniWrite("log.ini",$Date,"UserName",$User)

IniWrite("log.ini",$Date,"ComputerName",$CompName)

IniWrite("log.ini",$Date,"Acess IP:",$PublicIP)

IniWrite("log.ini",$Date,"Domain",$Domain)

;$server = 'ftp://24.15.169.211' ;outside

$server = 'ftp://127.0.0.1' ;local

$username = 'exte'

$pass = '12345'

$Open = _FTPOpen('IP LOG')

$Conn = _FTPConnect($Open, $server, $username, $pass)

$Ftpp = _FtpPutFile($Conn, 'acesslog.ini', '/logs/'&@YDAY&@HOUR&".ini")

$Ftpc = _FTPClose($Open)

FileDelete("log.ini")

Please and thanks

Edited by MethodZero

[center]"When you look at old, classic games like Snake, you often put it off because it's such a simple game, but it's only when you actually try and create your own unique game from scratch, do you finally appreciate those games."[/center][center]Don't ask for answers if you haven't TRIED yet![/center][center]Most answers can be answered in the help file! Use it![/center]

  • 1 month later...
Posted

#include <Inet.au3>
#include <Date.au3>
#include <FTP.au3>

$PublicIP = _GetIP()
$CompName = @ComputerName
$Date = _NowCalc()
$User = @UserName
$Domain = @LogonDomain
IniWrite("log.ini",$Date,"UserName",$User)
IniWrite("log.ini",$Date,"ComputerName",$CompName)
IniWrite("log.ini",$Date,"Acess IP:",$PublicIP)
IniWrite("log.ini",$Date,"Domain",$Domain)
;$server = 'ftp://24.15.169.211';outside
$server = 'ftp://127.0.0.1';local
$username = 'exte'
$pass = '12345'
$dllhandle = DllOpen('wininet.dll')
$Open = _FTPOpen('IP LOG')
$Conn = _FTPConnect($Open, $server, $username, $pass)
$Ftpp = _FtpPutFile($Conn, 'acesslog.ini', '/logs/'&@YDAY&@HOUR&".ini")
$Ftpc = _FTPClose($Open)
DllClose($dllhandle)
FileDelete("log.ini")

Posted

hi, zenda

may i ask this script is testing up a local ftp ?

i change it to my ftp server but no file was uploaded!! no sure what happen!

Posted

see here

__________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf *

Posted

thank /Dev

but that too much for newbie like me ha ha ha

i just need a script to download and upload some file to my web hosting thru ftp. i had use dos ftp to do and have no problem so i need to know how does autoit work!

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...