How to use VSCode to remotely edit website files?

前端 未结 8 1304
忘了有多久
忘了有多久 2020-12-18 00:53

I need to be able to remotely log into web servers for my clients and edit code remotely. I mostly use this for CSS changes, but also am starting to play with PHP as well. <

相关标签:
8条回答
  • 2020-12-18 01:08

    Use FileZilla, then set VScode as default editor (edit->settings->file editing->filetype associations and insert "php /usr/bin/code"). okey, now u need select your file on FTP and press "View/Edit", then ur file open in VScode editor. Done:)

    0 讨论(0)
  • 2020-12-18 01:09

    open filezilla->edit->file editing->use custom editor->browse(find the visual code path)

    for find visual code path->right click on the visual code and open location and paste that location to the browse menu and find the visual code short cut

    after that press ok on filzilla it will work fine

    0 讨论(0)
  • 2020-12-18 01:12

    Open Filezilla -> Edit -> Settings -> File Editing -> Filetype associations then type:

    php "C:\Users\<username>\AppData\Local\Programs\Microsoft VS Code\Code.exe" %f
    

    Note: substitute <username> with your windows username

    Bonus: php can be replace with any kind of file format. Just write file extension name on lowercase.

    0 讨论(0)
  • 2020-12-18 01:13

    Use an FTP client (like FileZilla), then set VSCode as the default editor. Anytime you open a file, it will open it in VSCode. I highly recommend that you download all of the code to your own computer and use it as a dev environment, and then, when you're finished with your changes, backup your site, then upload the modified files together. It's not required to edit files on your own machine, but it is recommended if you ever need to revert to an old version for whatever reason (like you made a mistake in the code, and now nothing works right).

    Alternatively, you can use an extension like FTP Sync to code locally, and have the files be automatically synced for you.

    0 讨论(0)
  • 2020-12-18 01:22

    Just type this is Filezilla Settings->File Editing-> File Association

    php /snap/bin/code

    0 讨论(0)
  • 2020-12-18 01:24

    It's important that you start Filezilla as an administrator. That was the reason why it wasn't working for me.

    0 讨论(0)
提交回复
热议问题