alin19 Posted January 15, 2008 Share Posted January 15, 2008 please give me a tutorial or a link with php cli, i have searched but i didn't find anything that helped me Quote Link to comment https://forums.phpfreaks.com/topic/86103-solved-php-cli/ Share on other sites More sharing options...
rajivgonsalves Posted January 15, 2008 Share Posted January 15, 2008 you can check out the following looks good http://www.phpfreaks.com/tutorials/86/0.php Quote Link to comment https://forums.phpfreaks.com/topic/86103-solved-php-cli/#findComment-439673 Share on other sites More sharing options...
alin19 Posted January 15, 2008 Author Share Posted January 15, 2008 i can't succesuful instal it, i've download it from here: http://www.php.net/get/php-5.2.5-win32-installer.msi/from/a/mirror and when i install it and try to execute a script i recive some dll erors Quote Link to comment https://forums.phpfreaks.com/topic/86103-solved-php-cli/#findComment-439685 Share on other sites More sharing options...
rajivgonsalves Posted January 15, 2008 Share Posted January 15, 2008 You can go into the php.ini and disable the extension some of the extensions must be not installed properly or your extension_dir path must be wrong in php.ini Quote Link to comment https://forums.phpfreaks.com/topic/86103-solved-php-cli/#findComment-439687 Share on other sites More sharing options...
alin19 Posted January 15, 2008 Author Share Posted January 15, 2008 i have looked at that, the extension_dir is ok, i'm reciving erors to some dll that are there already, i don't understand Quote Link to comment https://forums.phpfreaks.com/topic/86103-solved-php-cli/#findComment-439719 Share on other sites More sharing options...
rajivgonsalves Posted January 15, 2008 Share Posted January 15, 2008 what are the errors your getting ? Quote Link to comment https://forums.phpfreaks.com/topic/86103-solved-php-cli/#findComment-439741 Share on other sites More sharing options...
alin19 Posted January 15, 2008 Author Share Posted January 15, 2008 oci.dll, oci.dll, oci.dll,aspel-15.dll,libcs.dll,dbs2cli.dll,isqlt09a.dll,libsqldbc_c.dll, libmonetra.dll,lcrzo.dll, ociw32.dll,db2cli.dll,iclit09b.dll,int3_svn.dll not find, in the exact order i recive those error, those dll are not find in ext dir, but i think that not those are looked for, as i sow in the comand promt that opens then send or don't send error [attachment deleted by admin] Quote Link to comment https://forums.phpfreaks.com/topic/86103-solved-php-cli/#findComment-439751 Share on other sites More sharing options...
rajivgonsalves Posted January 15, 2008 Share Posted January 15, 2008 remove the .dll enteries from php.ini obviously the accompany libraries are not available for these extensions Quote Link to comment https://forums.phpfreaks.com/topic/86103-solved-php-cli/#findComment-439755 Share on other sites More sharing options...
alin19 Posted January 15, 2008 Author Share Posted January 15, 2008 those? : ; Local Variables: ; tab-width: 4 ; End: [php_BZ2] extension=php_bz2.dll [php_CURL] extension=php_curl.dll [php_DBA] extension=php_dba.dll [php_DBASE] extension=php_dbase.dll [php_EXIF] extension=php_exif.dll [php_FDF] extension=php_fdf.dll [php_GD2] extension=php_gd2.dll [php_GETTEXT] Quote Link to comment https://forums.phpfreaks.com/topic/86103-solved-php-cli/#findComment-439756 Share on other sites More sharing options...
rajivgonsalves Posted January 15, 2008 Share Posted January 15, 2008 Yes comment all the dll that are giving the error.... Quote Link to comment https://forums.phpfreaks.com/topic/86103-solved-php-cli/#findComment-439758 Share on other sites More sharing options...
alin19 Posted January 15, 2008 Author Share Posted January 15, 2008 i've remove those, i don't recive the erros, but my test script isn't working, 10x a lot for you're help, [attachment deleted by admin] Quote Link to comment https://forums.phpfreaks.com/topic/86103-solved-php-cli/#findComment-439759 Share on other sites More sharing options...
rajivgonsalves Posted January 15, 2008 Share Posted January 15, 2008 I could not read the image... I think you forgot the first line... check the tutorial.. Quote Link to comment https://forums.phpfreaks.com/topic/86103-solved-php-cli/#findComment-439761 Share on other sites More sharing options...
alin19 Posted January 15, 2008 Author Share Posted January 15, 2008 the tutorial is for linux, i'm working on a xp profesional, in linux is like this: #!/usr/bin/php -q <?php echo "This is a PHP-CLI Script!!"; ?> in windows i don't know and if i try to open the program i still get some errors, click on the picture it will get biger, i will try to fix it myself, 10x for the help [attachment deleted by admin] Quote Link to comment https://forums.phpfreaks.com/topic/86103-solved-php-cli/#findComment-439774 Share on other sites More sharing options...
rajivgonsalves Posted January 15, 2008 Share Posted January 15, 2008 #!/usr/bin/php -q should be the path to to your php-cli where did you install it Quote Link to comment https://forums.phpfreaks.com/topic/86103-solved-php-cli/#findComment-439776 Share on other sites More sharing options...
trq Posted January 15, 2008 Share Posted January 15, 2008 #!/usr/bin/php -q should be the path to to your php-cli where did you install it That is a linux path, not windows. Quote Link to comment https://forums.phpfreaks.com/topic/86103-solved-php-cli/#findComment-439781 Share on other sites More sharing options...
alin19 Posted January 15, 2008 Author Share Posted January 15, 2008 even if i used the exe file, not zip file, i din't use this program before C:\php -q <?php echo "This is a PHP-CLI Script!!"; ?> or? C:\php\php.exe -q <?php echo "This is a PHP-CLI Script!!"; ?> Quote Link to comment https://forums.phpfreaks.com/topic/86103-solved-php-cli/#findComment-439783 Share on other sites More sharing options...
trq Posted January 15, 2008 Share Posted January 15, 2008 You really don't need the shebang line, as long as you call your script as an argument to the php command. eg; php yourscript.php Quote Link to comment https://forums.phpfreaks.com/topic/86103-solved-php-cli/#findComment-439785 Share on other sites More sharing options...
alin19 Posted January 15, 2008 Author Share Posted January 15, 2008 aha that runs like c++, i got it, but i still get some errors, what dll are absolutly necesary? [attachment deleted by admin] Quote Link to comment https://forums.phpfreaks.com/topic/86103-solved-php-cli/#findComment-439797 Share on other sites More sharing options...
trq Posted January 15, 2008 Share Posted January 15, 2008 Depends what you want to do, but none are required. Quote Link to comment https://forums.phpfreaks.com/topic/86103-solved-php-cli/#findComment-439801 Share on other sites More sharing options...
alin19 Posted January 15, 2008 Author Share Posted January 15, 2008 it works, you are the best, 10x guys, i will ask you later abouth what libraries to add when i need them, 10x, Quote Link to comment https://forums.phpfreaks.com/topic/86103-solved-php-cli/#findComment-439804 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.