$sodapop->view->templatePath($templateName)
templatePath() creates the path to the current template. If no template is assigned, or the template file doesn't exist, its going to load a null template Location: view.sodapop.php public function...
View Article$sodapop->view->loadTemplate($templateName)
loadTemplate() loads the current template Parameter: $templateName - the name of the template to be loadedLocation: view.sodapop.php public function loadTemplate($templateName) { $loadTemplate =...
View Article$sodapop->database->getModuleData($id)
getModuleData($id) pulls module data from the db based on the modules ID number then returns an array of that data.Parameter: $id - the id of the module for which we are pulling data. Location:...
View Article$sodapop->database->modsInPosition($position)
modsInPosition($position) determines which modules are to be loaded for the given position, then processes all the info from the modules in that position loading them into an array $mod then returning...
View Article$sodapop->database->pageData($sodapop)
appData() retrieves all the info from the apps table for the given handle and packs it into the $app array. If no app exists, it routes to a 404 app... Parameters: $sodapop - this is the applications...
View Article$sodapop->database->getDefaultTemplate()
getDefaultTemplate() loads the template that is set as default in the templates table. Location: model.sodapop.php public function templateLookup() { ## Let's find out which template is set to...
View Article$sodapop->database->getData($query)
getData() performs the basic db query, and add scrubbing for sql injection protection. Location: model.sodapop.php public function getData($query) { ##### ## Add some sql injection protection here?...
View Article$sodapop->database->getUserDataById($id)
getUserDataById($id) acceptes the user's ID number and pulls all of their user data based on that. Parameters: $id - the user's ID number.Location: model.sodapop.php public function...
View Article$sodapop->hashIt($string)
hashIt() is used for hashing things. Right now it's just a double md5. Will probably add another layer of SHA, any suggestion here would be appreciated. Parameter: $string: the string to be hashed,...
View Article$sodapop->getCookie($cookieName)
getCookie() just grabs a desired cookies value. Parameter: $cookieName - the name of the cookie you want to get the data from. Expects: a cookie name.Location: class.sodapop.php public function...
View Article$sodapop->setaCookie($cookieName, $userID, $duration)
setaCookie() At this point it just does the same thing as PHP setcookie, but now we have the option doing some checking before actually setting a cookie.Parameters: $cookieName, $userID, $duration -...
View Article$sodapop->scrubFormData ($data)
scrubFormData() This needs to be built yet. It will scrub input form data to make sure that there aren't any injection attacks, etc.Parameter: $data - this is the data array from the form.Location:...
View Article$sodapop->getFormData($data)
getFormData() should be getting the data submitted by a form. It sends it to scrubFormData() to clean it up from injection attacks, etc.Parameter: $data - data from the form. Expects: An array of...
View Article$sodapop->parseModParams($modParams)
parseModParams() was intended to parse out the parameter of the module but I think that's currently being done in mod.sodapop.pop in getModuleData(). This method can probably be removed.Parameters:...
View Article$sodapop->doShowModule($modData)
doShowModule($modData) finds out whether or not to show the module on this app. This is ugly and probably needs to be refactoredParameter: $modData - takes an array of module data. Expects:...
View Article$sodapop->buildModPath($modDataName)
buildModPath() creates the path to the module's index appParameters: $modDataName - the name of the module to me loaded. Expects: The modules name.Location: class.sodapop.php private function...
View Article$sodapop->loadModule()
loadModule() loads all the modules for the given positionLocation: class.sodapop.php private function loadModule() { // How many modules are in this position so we know how many times to loop...
View Article$sodapop->modPosition($position)
modPosition() determines which modules are assigned to the given module positionParameters: $position - the module position which you would like to load. Expects: The name of the module position to...
View Article$sodapop->langPath($scope)
langPath() sets the path to the language files Parameters: $scope - sets the scope if the language to load, either application, app or template. Expeciting: sodapop, template or app.Location...
View Article$sodapop->loadView()
loadView() allows the app's controller to call in the apps view and push the $data array into it.Location: class.sodapop.php public function loadView() { $appPath = "./apps/" ....
View Article