jonniejoejonson Posted October 27, 2009 Share Posted October 27, 2009 If you have a class. Within that class you have a function. Witihin that function you have an sql statement to select some data from mysql. In the main script you load your class. You then execute the function. My question: Has the main script ran the sql in the function at the point where the class was loaded... or from when the script executed the function? kind regards to any responders.. J Link to comment https://forums.phpfreaks.com/topic/179181-solved-function-class-and-sql/ Share on other sites More sharing options...
Mark Baker Posted October 27, 2009 Share Posted October 27, 2009 Unless the query is executed within the constructor, then it will be executed when you call the method Link to comment https://forums.phpfreaks.com/topic/179181-solved-function-class-and-sql/#findComment-945359 Share on other sites More sharing options...
jonniejoejonson Posted October 27, 2009 Author Share Posted October 27, 2009 Thanks Mark Baker Link to comment https://forums.phpfreaks.com/topic/179181-solved-function-class-and-sql/#findComment-945365 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.