Welcome Guest, Not a member yet? Register   Sign In
Spark Fatal error: Uncaught Error: Call to undefined function str_starts_with()
#1

Hi,

i trie to setup my codeigniter framework with shield. For that i think i have finaly setup shield with this command "php spark shieldConfusedetup"

After typing this command in putty, i recieved this message:

"php spark
Fatal error: Uncaught Error: Call to undefined function str_starts_with() in /v2.4u.tools/httpdocs/spark:28
Stack trace:
#0 {main}
  thrown in /my_domain/httpdocs/spark on line 28"

What I doing wrong?
Reply
#2

Your PHP version? Function added in PHP 8.0
Simple CI 4 project for beginners codeigniter-expenses ( topic )
Reply
#3

PHP 8.2
Reply
#4

(This post was last modified: 11-27-2024, 12:19 AM by 4usol.)

Anyone an idear?

php -m give this situation

"[PHP Modules]
bcmath
bz2
calendar
Core
ctype
curl
date
dba
dom
exif
fileinfo
filter
ftp
gd
gettext
gmp
hash
iconv
igbinary
imagick
imap
intl
ionCube Loader
json
ldap
libxml
mbstring
mysqli
mysqlnd
openssl
pcntl
pcre
PDO
pdo_mysql
pdo_pgsql
pdo_sqlite
Phar
posix
redis
Reflection
session
shmop
SimpleXML
soap
sockets
sodium
SPL
sqlite3
standard
sysvmsg
sysvsem
sysvshm
tidy
tokenizer
wddx
xml
xmlreader
xmlrpc
xmlwriter
xsl
Zend OPcache
zip
zlib

[Zend Modules]
Zend OPcache
the ionCube PHP Loader + ionCube24"
Reply
#5

(This post was last modified: 11-28-2024, 10:38 AM by 4usol.)

Sometimes its hard to see how less i know :-((

I forget to tell shell the php version before do the command, so after that i do the following command


"
Code:
/usr/local/php82/bin/php spark shield:setup
"

Now the result is:

Code:
CodeIgniter v4.5.5 Command Line Tool - Server Time: 2024-11-28 18:33:28 UTC+01:00

Command "shield:setup" not found.


What i now do wrong?
Reply
#6

lets say i run this command :
Code:
[andrew@darkstar ~]$ makepkg -s
==> ERROR: PKGBUILD does not exist.

" pkgbuild does not exist" but then :

Code:
[andrew@darkstar ~]$ cd kooha-git
[andrew@darkstar kooha-git]$ makepkg -s
==> Making package: kooha-git 2.2.2.r13.g705e8dc-1 (Thu Nov 28 19:08:57 2024)
==> Checking runtime dependencies...
==> Installing missing dependencies...
[sudo] password for andrew:
sudo: a password is required

==> ERROR: Aborted by user! Exiting...


In the above you can see the problem I was at ~ to begin with and theres no makepkg in home. but plenty in sub directories . in
Code:
/usr/local/php82/bin/php spark shield:setup
i cant see the context of where the command line is running from ? yet /usr/local looks suspiciously like a linux box
CMS CI4 A CMS system, runs out of the box written on top of CI4
Arch Book  CodeIgniter4 on Apache(pages 92-114) 
Reply
#7

you've right, it was a problem ob the wrong directorie, now i could rund all commands without any error ;-)) Thanks !
Reply
#8

glad its working

if you ever want to know where you are run this command pwd eg:

Code:
[andrew@darkstar CI4-CMS]$ pwd
/srv/http/CI4-CMS
[andrew@darkstar CI4-CMS]$
CMS CI4 A CMS system, runs out of the box written on top of CI4
Arch Book  CodeIgniter4 on Apache(pages 92-114) 
Reply




Theme © iAndrew 2016 - Forum software by © MyBB