Help please - "#exec cmd" stops working after downloading to Windows
Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Help please - "#exec cmd" stops working after downloading to Windows
Sorry if I'm posting in the wrong place but I need some help with some code on a UNIX server running Apache.
The index.html runs fine with the exec cmd command if the html is updated on the Unix server itself with VI editor, but if it's downloaded to a Windows machine then uploaded back, the exec cmd doesn work. It's as if the server is reading the code as a remark. If you look at the source code of the page, it's just in there like a remark. It also doesn't make a difference if I don't even open the code. If I just FTP it to my PC then put the file back, the command is read as a remark.
Can anyone help me with fixing this problem? I'm not familiar enough with VI editor to make the changed using Putty so I need to make the changed in a text editor in Windows.
Although I'm a Windows user, I've managed to figure out the fix; I had do a chmod to allow it to execute, but now I have a chmod question.
I found a tutorial that explains chmod but I can't figure out how to get my index.html file to have these permissions: - rwxrwxr-x
My understanding is that the last 6 characters are for the group, the last 3 is other so I'm assuming the 1st 3 are user. How do I do a chmod to so -rwxrwxr-x?
BTW, what I did was give all read, write and execute permissions to run, but I'd like to fix it so permission remains what the original permissions were before I downloaded the file.
Thanks for the info. I'd played around with Linux when Red Hat 5.0 came out so I remembered doing a chmod command. Funny thing is is that last night, when I was looking up the info on chmod, the 1st examples had me using "chmod og=rw filename". It confused me because I remember doing chmod 777 to give everyone access, but since it worked I left it alone. Well, atleast not, chmod and the numbers still work. Thanks for the info and I'll make sure to bookmark the link.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.