We are using the following functions for an Invoice Module:
/* Functions: Before */
function before ($here, $inthat){
return substr($inthat, 0, strpos($inthat, $here));
}
/* Functions: After */
function after ($here, $inthat){
if (!is_bool(strpos($inthat, $here)))
return substr($inthat, strpos($inthat,$here)+strlen($here));
}
/* Functions: Between */
function between ($here, $that, $inthat){
return before ($that, after($here, $inthat));
}
This code is showing following Error Message in PHP 8.1:
Deprecated: strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated
Please guide us as to what to do in this regard.
Thanks,
Lakshmanan
Error Messages are shown for the following code:
We are getting the following Error Messages:
We post the following Comments [showing only short example] in the Online Order [osCommerce earlier and Zen Cart now]:
We capture these values through the following code:
All the values are shown correctly in spite of the Error Messages.
We have hidden Error Messages by changing the above code as follows:
Any other suggestion is welcome.
Thanks,
Lakshmanan