GoFuckYourself.com - Adult Webmaster Forum

GoFuckYourself.com - Adult Webmaster Forum (https://gfy.com/index.php)
-   Fucking Around & Business Discussion (https://gfy.com/forumdisplay.php?f=26)
-   -   How to execute a script in C? (https://gfy.com/showthread.php?t=108622)

snowball179 02-15-2003 10:57 PM

How to execute a script in C?
 
I need to execute a file named toplist (there is no extension) on my web server. I think that it is in C.

How do I execute it?

Thanks!

snowball179 02-15-2003 11:08 PM

I also need to execute a file named toplist.sh

Anyone knows how?

lustbin 02-15-2003 11:14 PM

system("command line here");

http://www.cs.utah.edu/dept/old/texi...14.html#SEC213

for further info and alternate methods

TrafficTeam 02-15-2003 11:15 PM

got SSH access to your box?


Rgds,JOKER

snowball179 02-15-2003 11:19 PM

Quote:

Originally posted by TrafficTeam
got SSH access to your box?


Rgds,JOKER

yes

TrafficTeam 02-15-2003 11:26 PM

then make sure its executeable,you have the rights to execute it and type (inside the folder where the script is)


./scriptname


for the .sh script either:

./scriptname.sh

or:

sh scriptname.sh



Rgds,JOKER

for any further questions pls hit me up on ICQ,I'm not refreshing every 5 minutes here...

lustbin 02-15-2003 11:29 PM

hmm no more drinking while answering questions

chmod 2 tha res-q

res 02-16-2003 06:04 AM

For C scripts:
1) gcc -o target source.c
2) ./target

For Shell scripts:
1) Add header in your shell script: #!/bin/sh
2) chmod 755 filename.sh
3) filename.sh


All times are GMT -7. The time now is 03:47 PM.

Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2026, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc123