View Single Post
Old 08-27-2009, 06:58 AM   #7 (permalink)
JaoudeStudios
The Acquainted
 
JaoudeStudios's Avatar
 
Join Date: Jul 2009
Location: Surrey
Posts: 105
Thanks: 1
JaoudeStudios is on a distinguished road
Default

Yes definitely do it in the class, keep it all contained and encapsulated.

The code I gave you is not hard coding a value as such, as it refers to a default option, making the 2nd variable optional from outside the class! So you do not need to pass the 2nd variable when initiating the class object, however you will need to check in the class if another value besides the default has been passed.

Maybe we are not on the same page?!?!
__________________
JaoudeStudios.com | JaoudeStudios.com Forum | JaoudeStudios.com Blog
OpenSource is the road ahead...!
JaoudeStudios is offline  
Reply With Quote
The Following User Says Thank You to JaoudeStudios For This Useful Post:
captainmerton (08-27-2009)