The "Notice" (not an error) you are getting is not because you are using mysqli. You probably had the same "problem" before, but the error_reporting level is probably set "higher" (by default) on the new server, so you are now seeing it.
The reason you are getting this "Notice" is because there are no rows returned in your result set and the $quan1 variable is not being explicitly set. (It will default to 0 in this case.)
Initialise your variables at the start of your code - always good practise.