Hello guys,
I am new to modx & I am wondering that how could I use DB table I have created in the same way we use existing tables like $document_table = $modx->getTableName('modResource');.
So here how could I use my table as $document_table = $modx->getTableName('modSampleTable');. Do I have to make any schema or something or what?
Please help.
Thanks in advance
If the table already exists, this would be one way:
http://bobsguides.com/custom-db-tables.html
If you have complex relationships between multiple tables, you'd probably want to go this route:
http://rtfm.modx.com/display/revolution20/Using+Custom+Database+Tables+in+your+3rd+Party+Components
---------------------------------------------------------------------------------------------------------------
PLEASE, PLEASE specify the version of MODX you are using . . . PLEASE!
MODX info for everyone:
http://bobsguides.com/modx.html