Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7770755
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T16:29:11+00:00 2026-06-01T16:29:11+00:00

For example to: preg_match or when you use concatenation? Answer to comments: I can

  • 0

For example to: preg_match or when you use concatenation?

Answer to comments:

I can test for preg_match or concatenation results, yes.

But there is a difference between:

PHP function with the signature: int f(string $parameter)

  • Will PHP convert the NULL to empty string before the f function gets it, or
  • Will the f function get NULL even if signature expects string, so the function may throw exceptions or behave not as it would received an empty string.

(I can’t test this, because I can’t write string type for a parameter at function signature.)

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-01T16:29:13+00:00Added an answer on June 1, 2026 at 4:29 pm

    It depends on the function you used for. Some may support null as parameter, some not. Some may throw notice, but dont forget that null may be converted to “” (empty string)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

In PHP one can use the function preg_match with the flag PREG_OFFSET_CAPTURE in order
i want to use preg_match to find text between bracket for example: $varx =
I want to use preg_match() such that there should not be special characters such
preg_match(/\w+/, $s, $matches); I have the PHP code above. I use it to match
I'm trying to use preg_match to find php code statements in template files so
I've got this pattern which I use with preg_match and I can't figure where
How do I use preg_match to get a query string from a URL? http://www.example.com/imgres?imgurl=http://www.example.com/images/blue-diamond-rings.jpg
I have the following string: keyword|title|http://example.com/ I would like to use the PHP function
I can get the [a-z0-9]* part from [a-z0-9]*@example.com with regex but I want to
Take for example the following regex match. preg_match('!^publisher/([A-Za-z0-9\-\_]+)/([0-9]+)/([0-9]{4})-(january|february|march|april|may|june|july|august|september|october|november|december):([0-9]{1,2})-([0-9]{1,2})/([A-Za-z0-9\-\_]+)/([0-9]+)(/page-[0-9]+)?$!', 'publisher/news/1/2010-march:03-23/test_title/1/page-1', $matches); print_r($matches); It produces the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.