Jump to content

Search the Community

Showing results for tags 'sendingfiles'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Multi Theft Auto: San Andreas 1.x
    • Support for MTA:SA 1.x
    • User Guides
    • Open Source Contributors
    • Suggestions
    • Ban appeals
  • General MTA
    • News
    • Media
    • Site/Forum/Discord/Mantis/Wiki related
    • MTA Chat
    • Other languages
  • MTA Community
    • Scripting
    • Maps
    • Resources
    • Other Creations & GTA modding
    • Competitive gameplay
    • Servers
  • Other
    • General
    • Multi Theft Auto 0.5r2
    • Third party GTA mods
  • Archive
    • Archived Items
    • Trash

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Member Title


Gang


Location


Occupation


Interests

Found 1 result

  1. function myCallback(data, errno,path) if errno == 0 then triggerEvent("onFileTDownload", root, "sound.mp3", data); else outputChatBox ('Error '..errno) --it return error 7, when ip == localhost returns error 1006 end end addEvent("onFileTDownload", false); addEventHandler("onFileTDownload", root, function(path,data) local file; if not fileExists(path) then file = fileCreate(path); else file = fileOpen(path); end; fileWrite(file, data); fileClose(file); -- do whatever with the file ... end); function testdownload () fetchRemote("http://127.0.0.1:80/testressource/sound.mp3",myCallback, "", false,':testressource/sound.mp3'); --[[i tried the following two examples too... fetchRemote("http://localhost/testressource/sound.mp3",myCallback, "", false,':testressource/sound.mp3'); fetchRemote("http://localhost:80/testressource/sound.mp3",myCallback, "", false,':testressource/sound.mp3'); ]] end addCommandHandler ('tts',testdownload) --[[ All in the client side]] How to solve it? can someone help me pls
×
×
  • Create New...