IWeb FTP upload

I'm having a significant problem uploading using iWeb's FTP functionality.
It has no problem connecting to the site. It goes through the process of uploading the content. The folders with the images and css files all seem to be uploading correctly. The uploading indicator slowly goes around until it gets to about the last 10% or less and then it stalls and just sits there and sits there and sits there and never seems to finish. It doesn't look as if it's actually loading any pages.
Does anybody have any idea what might be going on?
Thanks very much.
All the best,
Tom

Thanks. I have been using Transmit but wanted to test the iWeb function. It's still stuck were it was. I'm not sure how long I'm going to stick with it before writing it off as a lost cause. Seems strange that Apple can't manage something as simple as FTP software. It's more than 20 years since Fetch could do this.
Thanks again.

Similar Messages

  • I have created a Blog in iWeb and uploaded it to an FTP server.   It works fine, except that the 'Comments' facility is missing.   When I upload the blog to MobileMe   the 'Comments' facility is there and working great.   How can I solve the problem on th

    I have created a Blog in iWeb and uploaded it to an FTP server.   It works fine, except that the 'Comments' facility is missing.   When I upload the blog to MobileMe   the 'Comments' facility is there and working great.   How can I solve the problem on the FTP server Blog.

    You haven't a problem. You simply did not read the iWeb Help :

  • Used Iweb to upload to ftp but now all my mobileme sites show up on ftp

    I created a website on Iweb, then uploaded to Mobile me for final drafting process. When the client was satisfied, I moved the website to their designated ftp server using Iweb.
    Now, however, all the other websites I've been creating on Iweb and uploading to Mobile Me can only be found on this client's ftp server. What happened?I checked my Mobile me settings and the other websites are set to upload to Mobile me.
    The ftp server where everything seems to be migrating is ftp://dcimed.com.
    Any help would be greatly appreciated.
    Oh, and here is the message I get when I try to view the sites published to Mobile me
    The address could be spelled incorrectly.
    The address may be old or outdated.
    The page that you have requested may no longer exist.
    You can contact our webmaster at [email protected], or return to http://www.dcimed.com.

    here is the message I get when I try to view the sites published to Mobile me
    Please provide your mobileme username and the names of the sites you have published there.

  • Index problems with iweb 09 and ftp uploads

    Hi,
    after several issues with the site i eventually re-built and published with iweb 09's built in ftp.
    The problem i have is that the published site goes in a folder called Site on my server but the index page that redirects to the welcome.html file doesn't direct it to inside the site folder. This means when i navigate to the site it comes up as welcome.html not found on this server.
    I've resorted to filezilla again as when i publish to a local folder and upload it works ok.
    I still want to resolve this as the iweb ftp will publish just the canges so is loads quicker.
    I imagine the only way to resolve this is to change the settings in the iweb site settings page.
    does anyone know if i need to tell iweb a different path other than the server url.
    EG; my url is www.thepaddyproject.co.uk
    iweb put the site on the server ok (www.thepaddyproject.co.uk/Site
    the index page needs to redirect to www.thepaddyproject.co.uk/Site/Welcome.html
    any help appreciated
    Paul

    Posted by me in error.

  • IWeb, Finder and FTP Uploads...

    Hey folks...
    I was wondering if anyone was aware of an app that integrates FTP uploading capabilities straight into Finder - as opposed to use a third party FTP application to upload files.
    I would like to use iWeb to publish websites to my website's FTP account - via FTP, by using Finder (But, obviously Finder is only read-only FTP access).
    Does an application like this exist?

    I don't know if this solves your problem, but I connect to an FTP server through Safari and it mounts on my dekstop - thus Finder. If I type the line below in Safari (substituting my information where it says "username, password, and FTP host), then the FTP volume will mount on my desktop (after a few seconds), and appear in the Finder. Depending upon on your privileges you should be able to drag files in and out of the window (or the volume in the finder).
    The line looks like this (type in the URL of Safari):
    ftp://username:password@hostname
    Again, not sure if this is what you want.

  • Iweb with Lion: Umlaute after ftp-upload on linux-Server are not correct - but worked with Leopard!

    Hi from Germany. I used iweb 3.04 and OS X 10.6+ and everything worked fine on different websites, including German Umlaute ä, ö, ü, ß.
    After upgrading to Lion all Umlaute are not correct spelled (strange letters) after ftp-upload on a linux-server (which is the same as before). Before upload these Umlaute are spelled correctly, but not after upload.
    Trials were a) upload htaccess file b) use older iWeb 3.03 c) asking server administrator (answer: "use ae, oe, ue instead"), but nothing worked.
    Any ideas or help?
    Thank you very much, and excuse my english
    Peter

    The problem lies in the uploading of the files or the server itself.  If the umlautes looked good on the server before then we have to think it's the uploading process.  Try using the free FTP client  Cyberduck to upload your site folder to your server.  Then check to see if the rendering is correct.
    What's the URL of your site so we can examine it first hand?

  • IWeb folder to FTP uploader results in page not found!

    I had he original site on created on iWeb and uploaded to yahoo through filezilla. I re-made the site and then proceeded to delete the other site publish folder from filezilla and then replace it with the new published folder.
    this did not work and since the ste has looked like this: www.myaccountstogo.com
    please help asap!

    Your site works perfectly for me.
    Try to empty your browser's cache and reload the page. In Safari go to the Safari menu and select Empty cache.
    Regards,
    Cédric

  • I'm using a Mac. After swithcing to ICloud will I be able to use IWeb to upload and publish my sites hosted by other servers like Prohosting ?

    I'm using a Mac. After swithcing to ICloud will I be able to use IWeb to upload and publish my sites hosted by other servers like Prohosting ?

    iWeb has two other ways to publish your site...
    http://www.iwebformusicians.com/iWeb/Publish-Website.html
    ... and the second method allows you a choice of how you upload the files...
    http://www.iwebformusicians.com/iWeb/URLs-Favicons.html
    Here's a publishing workflow checklist...
    http://www.iwebformusicians.com/Search-Engine-Optimization/Website-Publishing-Wo rkflow.html
    The MobileMe only features can be replaced by alternatives...
    http://www.iwebformusicians.com/iWeb/Comments-Password-Protect.html
    If you have folders of assets outside of the main website folder on MobileMe, download them from the Apple server. From the Finder Go menu, follow the path iDisk/My iDisk/ to get there. Your website files are in the Web/Sites folder. Drag any files/folders onto the desktop.
    Use an FTP application to upload these assets to the root folder on your new server...
    http://www.iwebformusicians.com/Search-Engine-Optimization/Upload.html
    ...and change the relevant URLs to...
    http://www.domain-name.com/Folder-Name/file-name.file-extension
    There are lots of options for hosting for about half the cost of MobileMe...
    http://www.iwebformusicians.com/iWeb/Website-Hosting.html
    If you have been using a web.me.com domain name, you need to register a new one. Most hosting services give you at least one free and registering with your hosting company will make forwarding and managing it a lot easier.
    Make sure you add the new name to Google and create, upload and enter a new sitemap.xml...
    http://www.iwebformusicians.com/Search-Engine-Optimization/SEO.html
    If you have inbound links on other sites...
    http://www.iwebformusicians.com/Search-Engine-Optimization/Inbound-Link.html
    ... remember to inform the webmasters of you new URL.
    "I may receive some form of compensation, financial or otherwise, from my recommendation or link."

  • Using iWeb FTP results in nested site...

    I'm sure I'm just being a dummy here... but I'm lost.
    I'm using iWeb v3.01 to upload a site to a non-.mac host (bluehost.com). The uploads proceed without a hitch, no problem. Let's call it "www.genericsite.com."
    But when I go visit the site just uploaded, the browser's URL field immediately duplicates the URL, so that it reads "www.genericsite.com/genericsite.com/index.html."
    I then use Fetch (FTP client) to view the files on the site. I go into the public_html folder (where the site is supposed to go), and there I find an index.html file (good) and a FOLDER named "genericsite.com." Inside that folder, I find all the site files, and ANOTHER index.html file too.
    The Bluehost people are telling me that this "nested" folder is what's causing my problem. I could work around the problem by uploading from iWeb to a folder, then using Fetch (etc.) to upload the files. But that means I have to re-publish the entire site for every little change. So that ain't a great option.
    Is there any way to fix it so that iWeb just uploads files directly to the root of public_html, without putting them into a second folder?
    Help, anyone?

    Hi Ethmoid
    Thanks for you reply & patients. I followed you instructions, when I connect to my server I see several folders, php_uploads, public_html, SP_Barbarians.
    I click on public_html, I see my files connected to my website but looks like without content as the files are only 4.0 - 4.0KB.
    Then I click on public_htm - upload - it takes me to my desktop where I see my website folder - I select all and upload the contents of the folder. Cyberduck successfully uploads the content which is 436MB, however the website address stays the same, i.e www.spbarbarians/public_html/welcome.html , this is the previous address that came up when I used FTP to upload from iWeb with the site address public_html as you suggested earlier (to try & get rid of the double address www.spbarbarians/spbarbarians/welcome.html)
    Then I look back at the folder public_html which is in my cyberduck window connected to my server & I see that all the files are still the same size, i.e 4.0 - 8.0 KB. If Cyberduck has uploaded 436MB of content to this folder shouldn't the folders reflect this size?
    This window that I am looking at In Cyberduck is connected to my GoDaddy server and shows the content at that server correct?
    Please help as I have followed the instructions but I must be doing something wrong>

  • Iweb ftp problem - adding a folder where I don't want one

    Hi,
    I'd like to use iweb to upload directly to a web site.
    I have put in the same ftp details as work in dreamweaver but it creates a file that appears to be the site name. I've named the site the same as my URL, so the 'welcome' page becomes something like:
    www.  myurl.  co.  uk  /myurl/  welcome.html
    (ive added the spaces to the example to stop it becoming a hyperlink, but you get the idea)
    Am I doing something daft? Is there any way to not add this extra folder? My URL is already quite long.
    At present I'm creating the site in Iweb, piublishing to a folder on my mac, opening dreamweaver and loading from there. I'm sure it should be easier that that!
    Cheers.

    It is perfectly normal for iWeb to do this and no, you are doing nothing wrong.
    Re-name your site and don't use your url for the name of your site - change it to something shorter.
    If you want to upload your site without the site folder, then download Cyberduck and upload ONLY the contents of your site folder and not the whole folder itself.
    You can do this using Cyberduck or continue to use Dreamweaver.  There is no other way to avoid this really except using either of these two to upload.  That's it.  You can't do this using iWeb ftp.

  • Free Website Hosting With No Ads, Free FTP Uploading

    Hi there!
    I am working on a website for a technology scholarship I am applying for. I need to upload my iWeb site, so I am going to use Cyberduck. I need a web host that is ad free (it is a requirement of the scholarship) and offers free FTP uploading (so I can upload using Cyberduck). Thanks for your help!

    I need a web host that is ad free (it is a requirement of the scholarship) and offers free FTP uploading (so I can upload using Cyberduck).
    Who is your ISP? Normally ISP's offer their subscribers a certain (smallish) amount of free ftp accessible web space. That would probably be your best bet, because others are unlikely to meet your criteria.
    Or perhaps a school you have a relationship with.

  • How to create in iweb but upload to something other than .mac account

    I bought my own domain name and have a hosting server all setup through a friend.
    My question is can I create my page in iweb and upload it to my own hosting server which is not .mac?
    If not, how can I pull all files and folders out to copy up using Classic FTP?
    If I cant use iweb at all, what can I use to build my page on my macbook?
    Thank You
    Patrick

    Hi Patrick,
    all you have to do is go to File=>Publish to a folder when in iWeb and then upload the resulting files (index.html & folder named with name of your site in iWeb) to your server using an FTP application.
    http://alyeska.altervista.org/en/iWebFolderFTP.html
    Regards,
    Cédric

  • How do I get iweb to upload to different family pack accounts?

    Hi. sorry if this has been covered before, but I can't find this particular problem anywhere. Also sorry this is going to take a while to explain. We feel we wasted an extra 50 bucks on our family pack for mac.com last year to have accounts we never could find out how to upload from our separate iWeb domain files. We needed 4 different "sub accounts" but we use one mac laptop using one desktop. Calling apple customer service was of no help. We have figured out the way to get iWeb to open different domain2 files was to copy and into each person's file (one for the gardener for their garden stuff, one for the budding chef and his cooking stuff, etc). But no matter what domain file is opened and worked on iWeb always uploads it to our main (original) user name thus erasing the site previously uploaded to it. We can't seem to find out how to change the settings in iWeb so when it uploads particular iWeb projects to Mac.com (or now me.com?) it goes to the sub accounts and not overwriting the main account. Our main account is for the entire household's news/photos etc and we don't link to the others from there. We thought by setting up the family pack we could easily get iweb to send up to the other sub accounts. Not so. We ended up last year just doing all our websites on the same iWeb domain file using "new website" function and adding a complete new website to the bottom of the list on our iWeb pages. All of them would be combined into one which uploaded everything to the main account. Not what we wanted but that was the only way that nothing would get erased by anyone else's updates but also not very private as those near the bottom of the list would have a mac.com address as long as my arm. Sorry so long winded here. But if we can't have two iweb domain files on a desk top upload to two separate mac.com accounts or sub accounts, then why pay the extra for them? Is a family pack only good for families with a computer in every room? Our family pack accounts expires in 10 days so would like to know if we need to waste another 50 bucks. And no, setting up separate desktops for for the sake of individual iWeb projects is not an option as all the files are kept together. We tried that once and got so much duplication in photos and stuff, our hard drive was full in no time.

    so you have 45 different users on your one computer? ie: 45 different desktop users or am I still not understanding. To me a "user" you are referring to is what I would go up to the upper right of my toolbar and use the drop down menu and select another name (or in this case another alias of myself) but those additional accounts (users) would all have to be tied into my files on the main account to access them from all users, correct? All my files are on my one main user (myself) and not all of them are in iPhoto or iTunes, for instance any swf files. If I have other iWeb domain files (which I know how to create, duplicate and know about the last one used in iweb etc) then I have to create a separate user name (myself again) in my computer for as many iweb/me.com accounts or sub accounts that I have? But my problem with that is if I copy those domain files and move them into another account/user (which I tried) the link (the stuff at the bottom of the iWeb work window) still says my original Mac.com (me.com) address and will not let me change even when the new "user" has not even logged into Mac.com ever or the second computer is linked to a completely different mac.com account. I would have to start all over from scratch. I am sorry that I am not getting this. I know you are trying hard to explain it to me but it is just a bit too complicated to do a simple task of: I want to create a new iWeb/domain2 file on my own desktop with my own user name and have it go to "here" and not "here" within the me.com environment. I have actually copied and moved over 20 domain and domain2 files between our two macs to work on them, but each time the same connection indicated at the bottom is always the same and they will all upload to the master account at Mac I am referring to thus deleting anything we uploaded before no matter which computer they are located on. Once that domain file is created it is locked into that Mobileme account no matter what. So it has been easier to simply save to folders and purchase hosting from someone else than try to figure out what I am doing wrong with mac and me. (me, not myself)

  • Help with ftp upload problem

    Hi I am using a ftp class (known as FTPConnection) that i found on this site: http://www.nsftools.com/tips/JavaFtp.htm , and they only have an example of how to download a File through FTP and not upload one. I am in the proccess of making an FTP upload applet, and need some help on getting upload to work. I also need it to work on both a Pc and mac, so that may be attributing to the problem becuase i am currently on a mac which uses file:// instead of C:\\. Ill post the ftp class, and a snippet of my code that tries to upload a selected file.
    FTPConnection
    /* <!-- in case someone opens this in a browser... --> <pre> */
    * File:   FTPConnection.java
    * Author: Bret Taylor <[email protected]>
    * URL: http://www.stanford.edu/~bstaylor/cs/ftpconnection/FTPConnection.java.shtml
    * see also <a href="http://www.nsftools.com/tips/JavaFtp.htm">http://www.nsftools.com/tips/JavaFtp.htm</a>
    * $Id$
    * Parts of this code were adopted from a variety of other FTP classes the
    * author has encountered that he was not completely satisfied with.  If you
    * think more thanks are due to any particular author than is given, please
    * let him know.  With that caveat, this class can be freely distributed and
    * modified as long as Bret Taylor is given credit in the source code comments.
    * Modified by Julian Robichaux -- http://www.nsftools.com
    * Added constructors, logout(), listFiles(), listSubdirectories(), getAndParseDirList(),
    * processFileListCommand(), and overloaded getFullServerReply().
    * Also added StringBuffer parameter options to transferData() and executeDataCommand()
    * and did a few other little things.
    import java.io.*;
    import java.net.*;
    import java.util.*;
    * <p>A wrapper for the network and command protocols needed for the most common
    * FTP commands.  Standard usage looks something like this:</p>
    * <pre> FTPConnection connection = new FTPConnection();
    * try {
    *     if (connection.connect(host)) {
    *         if (connection.login(username, password)) {
    *             connection.downloadFile(serverFileName);
    *             connection.uploadFile(localFileName);
    *         connection.disconnect();
    * } catch (UnknownHostException e) {
    *     // handle unknown host
    * } catch (IOException e) {
    *     // handle I/O exception
    * }</pre>
    * <p>Most FTP commands are wrapped by easy-to-use methods, but in case clients
    * need more flexibility, you can execute commands directly using the methods
    * <a href="#executeCommand(java.lang.String)">executeCommand</a> and
    * <a href="#executeDataCommand(java.lang.String,
    * java.io.OutputStream)">executeDataCommand</a>,
    * the latter of which is used for commands that require an open data port.</p>
    * @author Bret Taylor
    * @author Julian Robichaux
    * @version 1.01
    public class FTPConnection extends Object {
         * If this flag is on, we print out debugging information to stdout during
         * execution.  Useful for debugging the FTP class and seeing the server's
         * responses directly.
        private static boolean PRINT_DEBUG_INFO = false;
         * The socket through which we are connected to the FTP server.
        private Socket connectionSocket = null;
         private String username;
         private String password;
         private String host;
         * The socket output stream.
        private PrintStream outputStream = null;
         * The socket input stream.
        private BufferedReader inputStream = null;
         * The offset at which we resume a file transfer.
        private long restartPoint = 0L;
         * Added by Julian: If this flag is on, we're currently logged in to something.
        private boolean loggedIn = false;
         * Added by Julian: This is the line terminator to use for multi-line responses.
        public String lineTerm = "\n";
         * Added by Julian: This is the size of the data blocks we use for transferring
         * files.
        private static int BLOCK_SIZE = 4096;
         * Added by Julian: After you create an FTPConnection object, you will call the
         * connect() and login() methods to access your server. Please don't forget to
         * logout() and disconnect() when you're done (it's only polite...).
        public FTPConnection ()
             // default constructor (obviously) -- this is just good to have...
         * Added by Julian: Allows you to specify if you want to send debug output to
         * the console (true if you do, false if you don't).
        public FTPConnection (boolean debugOut)
             PRINT_DEBUG_INFO = debugOut;
         public FTPConnection (String user, String pw, String host_)
             username=user;
              password=pw;
              host=host_;
              PRINT_DEBUG_INFO = false;
         * Prints debugging information to stdout if the private flag
         * <code>PRINT_DEBUG_INFO</code> is turned on.
        private void debugPrint(String message) {
            if (PRINT_DEBUG_INFO) System.err.println(message);
         * Connects to the given FTP host on port f, the default FTP port.
        public boolean connect(String host)
            throws UnknownHostException, IOException
            return connect(host, 21);
         * Connects to the given FTP host on the given port.
        public boolean connect(String host, int port)
            throws UnknownHostException, IOException
            connectionSocket = new Socket(host, port);
              connectionSocket.setSoTimeout(10000);
            outputStream = new PrintStream(connectionSocket.getOutputStream());
            inputStream = new BufferedReader(new
                           InputStreamReader(connectionSocket.getInputStream()));
            if (!isPositiveCompleteResponse(getServerReply())){
                disconnect();
                return false;
            return true;
         * Disconnects from the host to which we are currently connected.
         static boolean URLexists(String URLName)
              try
                   HttpURLConnection.setFollowRedirects(false);
                   // note : you may also need
                   // HttpURLConnection.setInstanceFollowRedirects(false)
                   HttpURLConnection con =
                   (HttpURLConnection) new URL(URLName).openConnection();
                   con.setRequestMethod("HEAD");
                   return (con.getResponseCode() == HttpURLConnection.HTTP_OK);
              catch (Exception e)
                   e.printStackTrace();
                   return false;
         public String getSimpleFileName(File f)
              String path=f.getPath();
              String fileName=path.replace("\\", "/");
              int slashPos = fileName.lastIndexOf("/");
              fileName=fileName.substring(slashPos+1);
              return fileName;
         public String verifyFileName(String name)
              int count=0;
              //String url="http://chris-malcolm.com/images/"+URLEncoder.encode(name).replace("+", "%20");
              while (URLexists("http://chris-malcolm.com/images/"+URLEncoder.encode(name).replace("+", "%20"))==true)
              count++;
              name=FileExt(name)[0]+"-"+count+"."+FileExt(name)[1];
              return name;
         public String[] FileExt(String fileName)
            int dotPos = fileName.lastIndexOf(".");
              fileName=fileName.replace("\\", "/");
              int slashPos = fileName.lastIndexOf("/");
              String extension, name;
              if (slashPos==fileName.length()-1)
                   fileName=fileName.substring(0, fileName.length()-1);
                   slashPos=fileName.lastIndexOf("/");
                   extension="/";
                   name=fileName.substring(slashPos+1);
              else if(dotPos==-1)
                   name=fileName.substring(slashPos+1);
                   extension="";
              else
                   extension = fileName.substring(dotPos+1);
                   name=fileName.substring(slashPos+1, dotPos);
                   String[] output={name, extension};
                   return output;
              String[] output={name, extension};
              return output;
        public void disconnect()
            if (outputStream != null) {
                try {
                      if (loggedIn) { logout(); };
                    outputStream.close();
                    inputStream.close();
                    connectionSocket.close();
                } catch (IOException e) {}
                outputStream = null;
                inputStream = null;
                connectionSocket = null;
         * Wrapper for the commands <code>user [username]</code> and <code>pass
         * [password]</code>.
        public boolean login(String username, String password)
            throws IOException
            int response = executeCommand("user " + username);
            if (!isPositiveIntermediateResponse(response)) return false;
            response = executeCommand("pass " + password);
            loggedIn = isPositiveCompleteResponse(response);
            return loggedIn;
         * Added by Julian: Logout before you disconnect (this is good form).
        public boolean logout()
            throws IOException
            int response = executeCommand("quit");
            loggedIn = !isPositiveCompleteResponse(response);
            return !loggedIn;
         * Wrapper for the command <code>cwd [directory]</code>.
        public boolean changeDirectory(String directory)
            throws IOException
            int response = executeCommand("cwd " + directory);
            return isPositiveCompleteResponse(response);
         * Wrapper for the commands <code>rnfr [oldName]</code> and <code>rnto
         * [newName]</code>.
        public boolean renameFile(String oldName, String newName)
            throws IOException
            int response = executeCommand("rnfr " + oldName);
            if (!isPositiveIntermediateResponse(response)) return false;
            response = executeCommand("rnto " + newName);
            return isPositiveCompleteResponse(response);
         * Wrapper for the command <code>mkd [directory]</code>.
        public boolean makeDirectory(String directory)
            throws IOException
            int response = executeCommand("mkd " + directory);
            return isPositiveCompleteResponse(response);
         * Wrapper for the command <code>rmd [directory]</code>.
        public boolean removeDirectory(String directory)
            throws IOException
            int response = executeCommand("rmd " + directory);
            return isPositiveCompleteResponse(response);
         * Wrapper for the command <code>cdup</code>.
        public boolean parentDirectory()
            throws IOException
            int response = executeCommand("cdup");
            return isPositiveCompleteResponse(response);
         * Wrapper for the command <code>dele [fileName]</code>.
        public boolean deleteFile(String fileName)
            throws IOException
            int response = executeCommand("dele " + fileName);
            return isPositiveCompleteResponse(response);
         * Wrapper for the command <code>pwd</code>.
        public String getCurrentDirectory()
            throws IOException
            String response = getExecutionResponse("pwd");
            StringTokenizer strtok = new StringTokenizer(response);
            // Get rid of the first token, which is the return code
            if (strtok.countTokens() < 2) return null;
            strtok.nextToken();
            String directoryName = strtok.nextToken();
            // Most servers surround the directory name with quotation marks
            int strlen = directoryName.length();
            if (strlen == 0) return null;
            if (directoryName.charAt(0) == '\"') {
                directoryName = directoryName.substring(1);
                strlen--;
            if (directoryName.charAt(strlen - 1) == '\"')
                return directoryName.substring(0, strlen - 1);
            return directoryName;
         * Wrapper for the command <code>syst</code>.
        public String getSystemType()
            throws IOException
            return excludeCode(getExecutionResponse("syst"));
         * Wrapper for the command <code>mdtm [fileName]</code>.  If the file does
         * not exist, we return -1;
        public long getModificationTime(String fileName)
            throws IOException
            String response = excludeCode(getExecutionResponse("mdtm " + fileName));
            try {
                return Long.parseLong(response);
            } catch (Exception e) {
                return -1L;
         * Wrapper for the command <code>size [fileName]</code>.  If the file does
         * not exist, we return -1;
        public long getFileSize(String fileName)
            throws IOException
            String response = excludeCode(getExecutionResponse("size " + fileName));
            try {
                return Long.parseLong(response);
            } catch (Exception e) {
                return -1L;
         * Wrapper for the command <code>retr [fileName]</code>.
        public boolean downloadFile(String fileName)
            throws IOException
            return readDataToFile("retr " + fileName, fileName);
         * Wrapper for the command <code>retr [serverPath]</code>. The local file
         * path to which we will write is given by <code>localPath</code>.
        public boolean downloadFile(String serverPath, String localPath)
            throws IOException
            return readDataToFile("retr " + serverPath, localPath);
         * Wrapper for the command <code>stor [fileName]</code>.
        public boolean uploadFile(String fileName)
            throws IOException
            return writeDataFromFile("stor " + fileName, fileName);
         * Wrapper for the command <code>stor [localPath]</code>. The server file
         * path to which we will write is given by <code>serverPath</code>.
        public boolean uploadFile(String serverPath, String localPath)
            throws IOException
            return writeDataFromFile("stor " + serverPath, localPath);
         * Set the restart point for the next download or upload operation.  This
         * lets clients resume interrupted uploads or downloads.
        public void setRestartPoint(int point)
            restartPoint = point;
            debugPrint("Restart noted");
         * Gets server reply code from the control port after an ftp command has
         * been executed.  It knows the last line of the response because it begins
         * with a 3 digit number and a space, (a dash instead of a space would be a
         * continuation).
        private int getServerReply()
            throws IOException
            return Integer.parseInt(getFullServerReply().substring(0, 3));
         * Gets server reply string from the control port after an ftp command has
         * been executed.  This consists only of the last line of the response,
         * and only the part after the response code.
        private String getFullServerReply()
            throws IOException
            String reply;
            do {
                reply = inputStream.readLine();
                debugPrint(reply);
            } while(!(Character.isDigit(reply.charAt(0)) &&
                      Character.isDigit(reply.charAt(1)) &&
                      Character.isDigit(reply.charAt(2)) &&
                      reply.charAt(3) == ' '));
            return reply;
         * Added by Julian: Returns the last line of the server reply, but also
         * returns the full multi-line reply in a StringBuffer parameter.
        private String getFullServerReply(StringBuffer fullReply)
             throws IOException
            String reply;
            fullReply.setLength(0);
            do {
                reply = inputStream.readLine();
                debugPrint(reply);
                fullReply.append(reply + lineTerm);
            } while(!(Character.isDigit(reply.charAt(0)) &&
                      Character.isDigit(reply.charAt(1)) &&
                      Character.isDigit(reply.charAt(2)) &&
                      reply.charAt(3) == ' '));
              // remove any trailing line terminators from the fullReply
              if (fullReply.length() > 0) 
                   fullReply.setLength(fullReply.length() - lineTerm.length());
            return reply;
         * Added by Julian: Gets a list of files in the current directory.
         public String listFiles()
              throws IOException
              return listFiles("");
         * Added by Julian: Gets a list of files in either the current
         * directory, or one specified as a parameter. The 'params' parameter
         * can be either a directory name, a file mask, or both (such as
         * '/DirName/*.txt').
         public String listFiles(String params)
              throws IOException
              StringBuffer files = new StringBuffer();
              StringBuffer dirs = new StringBuffer();
              if (!getAndParseDirList(params, files, dirs))
                   debugPrint("Error getting file list");
              return files.toString();
         * Added by Julian: Gets a list of subdirectories in the current directory.
         public String listSubdirectories()
              throws IOException
              return listSubdirectories("");
         * Added by Julian: Gets a list of subdirectories in either the current
         * directory, or one specified as a parameter. The 'params' parameter
         * can be either a directory name, a name mask, or both (such as
         * '/DirName/Sub*').
         public String listSubdirectories(String params)
              throws IOException
              StringBuffer files = new StringBuffer();
              StringBuffer dirs = new StringBuffer();
              if (!getAndParseDirList(params, files, dirs))
                   debugPrint("Error getting dir list");
              return dirs.toString();
         * Added by Julian: Sends and gets the results of a file list command,
         * like LIST or NLST.
        private String processFileListCommand(String command)
            throws IOException
            StringBuffer reply = new StringBuffer();
            String replyString;
            // file listings require you to issue a PORT command,
            // like a file transfer
              boolean success = executeDataCommand(command, reply);
              if (!success)
                   return "";
            replyString = reply.toString();
            // strip the trailing line terminator from the reply
            if (reply.length() > 0)
                 return replyString.substring(0, reply.length() - 1);
            }  else  {
                 return replyString;
          * Added by Julian: Gets a directory list from the server and parses
          * the elements into a list of files and a list of subdirectories.
         private boolean getAndParseDirList(String params, StringBuffer files, StringBuffer dirs)
              throws IOException
              // reset the return variables (we're using StringBuffers instead of
              // Strings because you can't change a String value and pass it back
              // to the calling routine -- changing a String creates a new object)
              files.setLength(0);
              dirs.setLength(0);
              // get the NLST and the LIST -- don't worry if the commands
              // don't work, because we'll just end up sending nothing back
              // if that's the case
              String shortList = processFileListCommand("nlst " + params);
              String longList = processFileListCommand("list " + params);
              // tokenize the lists we got, using a newline as a separator
              StringTokenizer sList = new StringTokenizer(shortList, "\n");
              StringTokenizer lList = new StringTokenizer(longList, "\n");
              // other variables we'll need
              String sString;
              String lString;
              // assume that both lists have the same number of elements
              while ((sList.hasMoreTokens()) && (lList.hasMoreTokens())) {
                   sString = sList.nextToken();
                   lString = lList.nextToken();
                   if (lString.length() > 0)
                        if (lString.startsWith("d"))
                             dirs.append(sString.trim() + lineTerm);
                             debugPrint("Dir: " + sString);
                        }  else if (lString.startsWith("-"))  {
                             files.append(sString.trim() + lineTerm);
                             debugPrint("File: " + sString);
                        }  else  {
                             // actually, symbolic links will start with an "l"
                             // (lowercase L), but we're not going to mess with
                             // those
                             debugPrint("Unknown: " + lString);
              // strip off any trailing line terminators and return the values
              if (files.length() > 0)  {  files.setLength(files.length() - lineTerm.length());  }
              if (dirs.length() > 0)  {  dirs.setLength(dirs.length() - lineTerm.length());  }
              return true;
         * Executes the given FTP command on our current connection, returning the
         * three digit response code from the server.  This method only works for
         * commands that do not require an additional data port.
        public int executeCommand(String command)
            throws IOException
            outputStream.println(command);
            return getServerReply();
         * Executes the given FTP command on our current connection, returning the
         * last line of the server's response.  Useful for commands that return
         * one line of information.
        public String getExecutionResponse(String command)
            throws IOException
            outputStream.println(command);
            return getFullServerReply();
         * Executes the given ftpd command on the server and writes the results
         * returned on the data port to the file with the given name, returning true
         * if the server indicates that the operation was successful.
        public boolean readDataToFile(String command, String fileName)
            throws IOException
            // Open the local file
            RandomAccessFile outfile = new RandomAccessFile(fileName, "rw");
            // Do restart if desired
            if (restartPoint != 0) {
                debugPrint("Seeking to " + restartPoint);
                outfile.seek(restartPoint);
            // Convert the RandomAccessFile to an OutputStream
            FileOutputStream fileStream = new FileOutputStream(outfile.getFD());
            boolean success = executeDataCommand(command, fileStream);
            outfile.close();
            return success;
         * Executes the given ftpd command on the server and writes the contents
         * of the given file to the server on an opened data port, returning true
         * if the server indicates that the operation was successful.
        public boolean writeDataFromFile(String command, String fileName)
            throws IOException
            // Open the local file
            RandomAccessFile infile = new RandomAccessFile(fileName, "r");
            // Do restart if desired
            if (restartPoint != 0) {
                debugPrint("Seeking to " + restartPoint);
                infile.seek(restartPoint);
            // Convert the RandomAccessFile to an InputStream
            FileInputStream fileStream = new FileInputStream(infile.getFD());
            boolean success = executeDataCommand(command, fileStream);
            infile.close();
            return success;
         * Executes the given ftpd command on the server and writes the results
         * returned on the data port to the given OutputStream, returning true
         * if the server indicates that the operation was successful.
        public boolean executeDataCommand(String command, OutputStream out)
            throws IOException
            // Open a data socket on this computer
            ServerSocket serverSocket = new ServerSocket(0);
            if (!setupDataPort(command, serverSocket)) return false;
            Socket clientSocket = serverSocket.accept();
            // Transfer the data
            InputStream in = clientSocket.getInputStream();
            transferData(in, out);
            // Clean up the data structures
            in.close();
            clientSocket.close();
            serverSocket.close();
            return isPositiveCompleteResponse(getServerReply());   
         * Executes the given ftpd command on the server and writes the contents
         * of the given InputStream to the server on an opened data port, returning
         * true if the server indicates that the operation was successful.
        public boolean executeDataCommand(String command, InputStream in)
            throws IOException
            // Open a data socket on this computer
            ServerSocket serverSocket = new ServerSocket(0);
            if (!setupDataPort(command, serverSocket)) return false;
            Socket clientSocket = serverSocket.accept();
            // Transfer the data
            OutputStream out = clientSocket.getOutputStream();
            transferData(in, out);
            // Clean up the data structures
            out.close();
            clientSocket.close();
            serverSocket.close();
            return isPositiveCompleteResponse(getServerReply());   
         * Added by Julian: Executes the given ftpd command on the server
         * and writes the results returned on the data port to the given
         * StringBuffer, returning true if the server indicates that the
         * operation was successful.
        public boolean executeDataCommand(String command, StringBuffer sb)
            throws IOException
            // Open a data socket on this computer
            ServerSocket serverSocket = new ServerSocket(0);
            if (!setupDataPort(command, serverSocket)) return false;
            Socket clientSocket = serverSocket.accept();
            // Transfer the data
            InputStream in = clientSocket.getInputStream();
            transferData(in, sb);
            // Clean up the data structures
            in.close();
            clientSocket.close();
            serverSocket.close();
            return isPositiveCompleteResponse(getServerReply());   
         * Transfers the data from the given input stream to the given output
         * stream until we reach the end of the stream.
        private void transferData(InputStream in, OutputStream out)
            throws IOException
            byte b[] = new byte[BLOCK_SIZE];
            int amount;
            // Read the data into the file
            while ((amount = in.read(b)) > 0) {
                out.write(b, 0, amount);
         * Added by Julian: Transfers the data from the given input stream
         * to the given StringBuffer until we reach the end of the stream.
        private void transferData(InputStream in, StringBuffer sb)
            throws IOException
            byte b[] = new byte[BLOCK_SIZE];
            int amount;
            // Read the data into the StringBuffer
            while ((amount = in.read(b)) > 0) {
                sb.append(new String(b, 0, amount));
         * Executes the given ftpd command on the server and writes the results
         * returned on the data port to the given FilterOutputStream, returning true
         * if the server indicates that the operation was successful.
        private boolean setupDataPort(String command, ServerSocket serverSocket)
            throws IOException
            // Send our local data port to the server
            if (!openPort(serverSocket)) return false;
            // Set binary type transfer
            outputStream.println("type i");
            if (!isPositiveCompleteResponse(getServerReply())) {
                debugPrint("Could not set transfer type");
                return false;
            // If we have a restart point, send that information
            if (restartPoint != 0) {
                outputStream.println("rest " + restartPoint);
                restartPoint = 0;
                // TODO: Interpret server response here
                getServerReply();
            // Send the command
            outputStream.println(command);
            return isPositivePreliminaryResponse(getServerReply());
         * Get IP address and port number from serverSocket and send them via the
         * <code>port</code> command to the ftp server, returning true if we get a
         * valid response from the server, returning true if the server indicates
         * that the operation was successful.
        private boolean openPort(ServerSocket serverSocket)
            throws IOException
            int localport = serverSocket.getLocalPort();
            // get local ip address
            InetAddress inetaddress = serverSocket.getInetAddress();
            InetAddress localip;
            try {
                localip = inetaddress.getLocalHost();
            } catch(UnknownHostException e) {
                debugPrint("Can't get local host");
                return false;
            // get ip address in high byte order
            byte[] addrbytes = localip.getAddress();
            // tell server what port we are listening on
            short addrshorts[] = new short[4];
            // problem:  bytes greater than 127 are printed as negative numbers
            for(int i = 0; i <= 3; i++) {
                addrshorts[i] = addrbytes;
    if (addrshorts[i] < 0)
    addrshorts[i] += 256;
    outputStream.println("port " + addrshorts[0] + "," + addrshorts[1] +
    "," + addrshorts[2] + "," + addrshorts[3] + "," +
    ((localport & 0xff00) >> 8) + "," +
    (localport & 0x00ff));
    return isPositiveCompleteResponse(getServerReply());
    * True if the given response code is in the 100-199 range.
    private boolean isPositivePreliminaryResponse(int response)
    return (response >= 100 && response < 200);
    * True if the given response code is in the 300-399 range.
    private boolean isPositiveIntermediateResponse(int response)
    return (response >= 300 && response < 400);
    * True if the given response code is in the 200-299 range.
    private boolean isPositiveCompleteResponse(int response)
    return (response >= 200 && response < 300);
    * True if the given response code is in the 400-499 range.
    private boolean isTransientNegativeResponse(int response)
    return (response >= 400 && response < 500);
    * True if the given response code is in the 500-5

    ok i tried explaining th eproblem in the previous post, but i apologize if my explanation was poor. anyways, i tried to look into it further by doing a printStackTrace() and believe it may be a read error. here is my new updated snippet, and also a link to a screenshot ([click here for screenshot|http://img143.imageshack.us/my.php?image=picture4qr0.png]) of what the error looks like on my end. it seems like a socket is not being read, or maybe it is initialized properly. Again I apologize if my problem is vague, but I do appreciate your input. thanks.
    updated code snippet
    public void uploadFiles()
              statusLabel.setVisible(true);
              errorLabel.setVisible(true);
              uploadButton.setVisible(false);
              footer.setVisible(false);
              holdingPanel.setVisible(false);
              pbar.setVisible(true);
              pbar = new JProgressBar();
              pbar.setMinimum(0);
              float Total=0;
              for (int i=0; i<fileLengths.size(); i++)
                   if(((java.lang.Boolean)model.getValueAt(i,1)).toString().equals("true"))
                        Total+=Float.parseFloat((String)fileLengths.get(i));
              pbar.setMaximum((int)Total);
              String info="";
              try
                   ftp=new FTPConnection(false);
                   ftp.connect("ftp.chris-malcolm.com");
                   if (ftp.login("chrismal", "***"))
                        statusLabel.setText("Status: Connected.");
                        info+="Successfully logged in!\n";
                        info+="System type is: " + ftp.getSystemType()+"\n";
                        info+="Current directory is: " + ftp.getCurrentDirectory()+"\n";
                        if (ftp.changeDirectory("/www/images/"))
                             info+="directory changed to: " + ftp.getCurrentDirectory()+"\n";
                                                 try
                             for (int i=0; i<allFiles.size(); i++)
                                  if(((java.lang.Boolean)model.getValueAt(i,1)).toString().equals("true"))
                                       String f=client.verifyFileName((String)model.getValueAt(i,0));
                                       String f2=""+((File)allFiles.get(i)).getPath();
                                       info+="filename: "+f2+"\n";
                                       if (ftp.uploadFile(f2))
                                            statusLabel.setText("Status: Uploading "+f+" - "+i+" of "+calculateTotalFiles()+" files(s)");
                                            pbar.setValue(Integer.parseInt((String)fileLengths.get(i)));
                                       else
                                            errorLabel.setText("Error occured while uploading"+f2+"\n");
                        catch(Exception de) 
                             StringWriter sw = new StringWriter();
                                  PrintWriter pw = new PrintWriter(sw);
                                  de.printStackTrace(pw);
                                  pw.close();
                                  //errorLabel.setText("<html>ERROR:"+sw.toString().replace("\n", "<br>")+"</html>");
                                  info+="Error: "+de.getMessage()+"\n";
                                  info+="Trace: "+sw+"\n";
                             try { ftp.disconnect(); statusLabel.setText("Status: disconnected.");}  catch(Exception e2)  {};
                        else
                             info+="could not change directory\n";
                   else
                        info+="could not login";
              catch (Exception e)
                   StringWriter sw = new StringWriter();
                                  PrintWriter pw = new PrintWriter(sw);
                                  e.printStackTrace(pw);
                                  pw.close();
                                  info+="Error: "+e.getMessage()+"\n";
                                  info+="Trace: "+sw+"\n";
                   try { ftp.disconnect();  statusLabel.setText("Status: disconnected.");}  catch(Exception e2)  {};
              errorLabel.setText("ERROR:"+info);
              JOptionPane.showMessageDialog(this, info, "test", JOptionPane.PLAIN_MESSAGE);
              try { ftp.disconnect(); statusLabel.setText("Status: disconnected.");}  catch(Exception e2)  {};
         Edited by: cjm771 on Jul 13, 2008 7:23 PM

  • Base filtering engine is preventing FTP uploads

    Using win 8.1. Ftp uploads (from any ftp program, filezilla, winscp and with knowhow cloud backup) stalls after 2-3 files have been uploaded.  A single large file will upload but not multiple small files. If I boot into windows safe mode the problem
    does not occur, ftp works fine, always.  In normal mode by eliminating one running component at a time I found that the base filtering engine appeared to be the only problem.  If base filtering was running the ftp problem occurred, if not then ftp
    was fine.
    Can one repair or replace the base filtering engine?.    I found this as it relates to win 7
    FROM ONE OF YOUR OTHER THREADS:
    you may download and apply the BFE service registry fix (#11) in this page: Miscellaneous Registry Fixes for Windows 7/XP/Vista - The Winhelponline Blog: LINK REMOVED (could not submit, Body text cannot contain images or links until we are able to verify
    your account.)
    Is that applicable for this problem in win 8.1?
    I do understand the BFE is an important security issue.  I have also scanned my system for viruses, I use defender (computer associates) anti virus and firewall, and spybot for malware.  I can't specifically pinpoint the occurrence of the problem with
    the installation of any specific new software program.  I have disabled the defender  firewall and virus software and that does not solve the problem. Disabling base filtering engine results in a functioning ftp, enabling results in
    a stalled ftp.
    Any help would be appreciated.

    Try this suggestion
    http://social.technet.microsoft.com/Forums/en-US/d8e59632-fca9-4bbd-b748-881af144706a/access-denied-base-filter-engine?forum=winservergen
    1. Browse to the location for the BFE service in the registry (HKLM\System\CurrentControlSet\Services\BFE\Parameters\Policy), right click and select permissions.
    2. In the "Permissions for Policy" window, click advanced | Add.
    3. Once the "Select Users, Computers or Group" box appears, change the "From this location:" to point to the local machine name.
    4. After changing the search location, enter "NT Service\BFE" in the "Enter the object name to select" box and click "Check names" - this will allow you to add the BFE account.
    5. Give the following privileges to the BFE account:
    Query Value
    Set Value
    Create Subkey
    Enumerate Subkeys
    Notify
    Read Control
    After adding the BFE account to the registry key, please try to start the Base Filtering Engine service.

Maybe you are looking for

  • Video output from iPod Touch (2nd gen) via AV Component Cable (no audio)

    Hi, I'm trying to output a video from my iPod Touch (2nd gen) to my TV via a AV Component Cable. Unfortunately the audio doesn't work, I'm sure they are all connected into the right places. The video works, but I get no audio. (And no subtitles when

  • Black Box on TV.

    This morning when i turned on my TV there was a large black box covering the lower half of the screen.  I am not able to see anything through the box (no picture, menu, anything).  I tried resetting the box, but it just came back and am not sure what

  • GRR3 Deleted Report Painter report

    I deleted a Report Painter report in GRR2.  It no longer exists in table T008 or assigned to any report group.  However, the deleted report still appears in GRR3 under the respective library.  How can we remove permanently a deleted report from GRR3?

  • How to use init parameters?

    Is it posible to use init parameters with FacesServlet? With any other servlet I'd do this: <servlet> - <init-param>   <param-name>base</param-name>   <param-value>/shop</param-value>   </init-param> </servlet>but it doesn't seem correct to the same

  • Iphoto is blacking out vertical images when importing.  how do i fix this?

    iphoto is blacking out vertical images when importing. how do i fix this?