![]() |
Which is best - $vbulletin->db->query_read OR $db->query_read
Just a very quick question.
I'm wondering what's the difference between $vbulletin->db->query_read(Select bla bla bla ..... and $db->query_read(Select bla bla bla ..... Trying to write my first mod for vBulletin 4.x (wish me luck I'll need it :P ) and wondering which is the best to use. I've being using lots of the tutorials and other posts as references but I'm not sure which is best practice. Both seam to work fine. |
You should always use $vbulletin->db->xxxxxx - the other method is obsolete and only still around for backwards compatibility.
|
Excellent, thanks for that Paul M and for the fast reply.
This can be closed if you want as it's answered :D |
I always use $vbulletin->db simply because putting "global $vbulletin" into a function covers everything, while "global $db" only covers database queries.
|
All times are GMT. The time now is 12:49 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|