Cameron
Cameron is a PHP Application Developer and consultant and spends much of his time furthering the business goals of his company Magnetic Merchandising Inc. which he started in 2005.
Cameron has provided technical deployment and consultation for many entities since starting MMI. Much of that work has been in complex hosted auction platforms, professional Joomla! deployments and extension development and sales.
As such, Cameron has acquired a deep technical skill-set, a sensitivity to client needs, and the ability to produce anything those clients can visualize.
Everyday, he actively seeks out and becomes familiar technologies that will give MMI clients maximum return for their web development and general e-presence dollar.
Put your iLance plugin code where you want
Over a period of years I have migrated from developing iLance plugins with the normal XML plugin structure. For a look at iLance plugins read Your First iLance Plugin. It gives a nice intro into plugins and the manner in which they can be used to customize the way iLance works and renders your material.
Like everyone else I used to plop the php into the tags in the plugin xml file. The thing is, I use Netbeans to do all of my work. That IDE has a nice PHP implementation, but when developing your plugin in an XML file, Netbeans looses its ability to render the nice visual differences and indicators which are based on PHP rules, functions and included libraries.
Your First iLance Plugin
iLance Plugins
The iLance Auction Platform is an extensive system designed to provide you with a professional level competition system to be hosted on your web server. Well, you already know this because you are reading this. AND – if you are reading this you are wondering : “How do I make changes and customize this system to suit my Web site and MY NEEDS??”.
Useful Tip: Ubuntu Linux Download Speed (Wireless)
Every so often I seem to switch back and forth between using Windows and Linux as my primary platform.
There are advantages to each. I actually prefer linux for localhost development, but that's not what I am wirting about here.
The latest version of Wubi.exe yields Ubuntu 11.10 and my install was a breeze. However, right out of the box the download speeds were "Poopie" to say the least.
Found out that it is the the wireless part of the system and found the solutuion, thanks to the follwing forum post by Jay @ Peppermint
peppermintos.net/viewtopic.php?f=39&t=311
It worked for me and maybe it will work for you.
iLance Pseudo-MVC Structure
iLance Pseudo-MVC Structure
iLance is a “Many Entry Point” application or platform. There are a number of files that take care of the ‘controller’ logic in the root directory, i.e. buying.php, main.php, etc. The logic in these is files is not delivered via a “class method” structure, where each piece of functionality is separated nicely into a method of the controlling class. The situation specific logic is perform via if statements in each of the files.
The “Model” like processing is perform via several class objects which are by default contained in the /functions/api directory with the file name class.class_name.inc.php where class_name exactly matches the class name as it appears in the file. i.e.
Setting up the current Joomla PHPUnit Tests on Netbeans
Like everyone else who writes Netbeans has recently included PHPUnit with its 6.8 version. I have the linux distribution, and am new to this so I am recording it for others to use.
Auction Expiry
In auction expiry (class.auction_expiry.inc.php)
For the specific circumstances:
- An auction is expired.
- Is service auction
- The auction has been identified as having escrow associated with it.
- That escrow transaction is marked completed.
Then the auction status will be moved from 'expired' to 'finished'.
Archiving, Delisting
This is a quicky!
When a user is in there MyCP and they cancel a listing, it goes into the Delisited Tab. It cannot be reopened. The Tab serves as a record of items delisted by the Admin or the user (owner).
This differs from a the Ended tab ($ilance->GPC['sub'] == 'exprired') loads all projects where the status is expired. Upon the execution of each cron, the auction_expiry class is loaded and it moves all due open listings to expired, and then all expired listings to finished.
I think maybe finished items, should probably get their own tab, or be moved to the archive automatically.
Customizing Head tags Joomla...
You can download the plugin with the "Custom Header Plugin and Title Plugin for Joomla" link at the bottom of the page!
Customizing Head tags Joomla...
And maybe just removing the "Joomla! 1.5 - Open Source Content Management" from the generator tag...
When looking into this right off the bat (well almost, I spent a good deal of time digging around the Joomla core first) I found this:
http://www.wzcreativetechnology.com/joomla-tips-and-tricks/73-how-to-remove-meta-tag-qgeneratorq-in-joomla.html
And hey! this seemed reasonable enough. Simply altering, the template file seems to be a good option, because its straight forward.
Simply add:
to the top of the template that you are currently using and there is your quick fix.
In fact, you can do this with all of your meta and other head tags right from the template (through related accessor methods).
However, one of the things that I really like about dynamically generated web sites is the ability to switch between templates and where ever possible I like to avoid hacking specific/concrete instances instead of abstracting the issue.
The entire content between the head tags is generated by /libraries/joomla/document/html/renderer/head.php (as mentioned in the above referrence page), and the code that is acuall responsible for loading that is in the JDocument class definition(/libraries/joomla/document/document.php), in the _loadRenderrer() method:
{
$null = null;
$class = 'JDocumentRenderer'.$type;
if( !class_exists( $class ) )
{
$path = dirname(__FILE__).DS.$this->_type.DS.'renderer'.DS.$type.'.php';
if(file_exists($path)) {
require_once($path);
} else {
JError::raiseError(500,JText::_('Unable to load renderer class'));
}
}
if ( !class_exists( $class ) ) {
return $null;
}
$instance = new $class($this);
return $instance;
}
What jumps out at me is the fact, unlike some of the other Joomla core classes (like JModel, JView, JController) is that the $path variable is not built with a $this->_path array that could have been set as an alternative path to search before it finds the default.
For me, the work around comes from the conditional :
if( !class_exists( $class ) )
This tells me that if we include our own definition of the JDocumentRendererHead class in a system plugin at onAfterRoute, then we can customize the header across all of our templates.
my little slice of the web
what does one say about one's self in this kind of forum. i guess the answer to that question is dependant on why this web site is up. another question.
i guess it is here for general interest, beginner, intermediate and advanced topics about the web. i think i will post solutions to problems that took me a while or just share what I have learned through the years. principally, my focus has been on the LAMP stack and a great deal more specific focus on Joomla!1.5 and iLance auction software. i do have a degree in mechanical engineering and work for several years as a impact/injury biomechanical engineer, but I have found my passion is actually the developing for the web.
i think that's a good start. I hope to find time regularly to post.
K2: Custom Templates
To override layouts in K2, you follow nearly the same process that you would in the Native Joomla content component. There is one slight difference though. It would seem that K2 .