The app does not work in both directions. This is for security reason as well as technical reasons. It is better for the webmaster to have control then allow the app to randomly delete support files it may need for other pages.
I get why you would want this option but @Flash is correct. There are lots of reasons why automating deletions from servers is not a good idea and could easily cause problems. I think best practice is to use one of the many FTP clients available (I use Transmit).
Note to @dan … Is it possible to indicate on the “Publish” icon on the top bar the currently active destination? Maybe with a hover?
Every so often, late on a sunday night when I expect minimal traffic - I upload an “under maintenance” index.html file to the server, and then delete all the other files and folders in the public_html folder. (Any required local resources folders can left)
I download a few other files first - the htaccess, the robots, the google account html file for your google search console, and the sitemap. Also download any pdf files
Then I completely publish the site; then upload the 4 files above back to the public_html.
(then i rerun a sitemap generator and upload that XML file and replace the old one)
Now all the “old” files that shouldn’t be there are gone and you are confident only needed ones are on the server.
Faster than looking for old files and saving you from possibly deleting something you shouldn’t and not noticing.
This discussion highlights a very good point that Elements can do better than any other.
Why isn’t there a trash folder where renamed or deleted pages (directories) are noted and an attempt is made to delete them with every upload? Only when I remove the pages from the trash folder can Elements no longer know about them and doesn’t delete anything.
So, all changes to the page’s directory should be noted in the trash folder. The contents must be backed up using macOS’ “Duplicate” option or a proper backup.
Wouldn’t that be a nice feature for working with Elements?
I like the idea of having a “Trash” folder so nothing gets properly deleted and the user can then decide if it should really be deleted.
We plan to revisit publishing, and work on better sync between Elements and the Server. So while I can’t say when this will happen, something like this is on the roadmap