(I don’t know the best way to word this but here goes!)
I have a site that is in PHP and it grabs certain data from tables depending on an identifier input like .php?id=500 and looks up from each table grabbing each respective fields and putting them into tables or lists.
What is the best easy CMS that I would use? How would I approach this? Is there a simple plugin for something like Joomla or WordPress or the such I can point to specific tables, tell it the identifier column, and tell it to list every row that matches? Including other tables?
IE. It pulls something from address table and lists all their address, pulls something from information and lists their gender age, and etc.
So this way, it creates dynamic pages that I can manage a lot easier and have searches and indexes. Trying to code all that and it’s getting way ahead of me. I figured there’s a CMS that does all this for me.
I hope you guys understand my question, I tried searching many wordings of this.
You’re making the right decision. Move to a CMS.
I have successfully migrated data (categories, articles and images) into a Joomla installation, the steps are:
relevant data
if pictures are stored separately from articles in your CMS, prepend at least one
to the text and append the rest;
articles to a single Asset ID
extra fields to fill-in-the-blanks
To perform the SQL Import you need to also clear the content_frontpage table.
Here is a function that receives a row from another cms and puts it into Joomla; a few comments are in Italian but you should get a feel of how to do it.
mdc2j are dedicated functions I wrote to proper escape the data and change formats/category ids etc. as needed.
There are a LOT of CMS solutions that can do this for you. To be honest, if you already have a site up and running and you just want a CMS, Joomla or WordPress is sort of overkill. Have a look at PyroCMS, it does exactly what you’re describing. It’s very easy to set up and get running and has good documentation.
If you’re into Python and interested in a hybrid solution, I’ve had success using PHP frameworks for main sites and Django (which is in Python) for the CMS.
This really wouldnât be that complicated to write yourself. In fact, itâs similar to how one of my content management systems works: I have a class for each âmoduleâ and properties that specify the database table to select records from, the columns to show on the overview page (table headings), and the columns to show in the form view (inputs).
Trying to shoe-horn an already-built website into a CMS like WordPress or Joomla! that is wanting to do everything for you (including the front-end site) out of the box is going to be a pain in the ass. And even if you do shoe-horn a CMS onto your site and get it working, itâs going to be bloated as hell.
Another idea might be to use Cakephp http://cakephp.org/. Cake can read your database schemes and produce the files that you need to get up and running. (If you have command line access). It uses the MVC pattern and its pretty quick to set up. I’v personally used cake on number of projects that you are describing.
WordPress might be a bit hard to get all your posts into without doing it manually. But if you don’t want to code too much and are will to manually move everything wordpress or some other out of the box CMS system might be the thing for you.
Nice question. Since Joomla is answered I will answer for WordPress. I would suggest creating a php file that exports all your table data to xml (RSS or WordPress). Then you can simply import your info into WordPress using WordPress import function.
This way you can keep both the tables and you can fully import info into WordPress.
If your interested I could probably cook some code together if you give me the format of your tables.
Finally you should search for and repost your answer on WordPress Stack Exchange ( wordpress.stackexchange.com).
You have a few options:
Also see http://thethemefoundry.com/blog/html-wordpress/
Also see http://wordpress.org/plugins/tablepress/
There are four question marks:
Q. What is the best easy CMS that I would use?
A. WordPress.
How would I approach this?
A. Learn PHP.
Q. Is there a simple plugin for something like Joomla or WordPress or the such I can point to specific tables, tell it the identifier column, and tell it to list every row that matches?
A. Probably. This is a simple task in PHP.
Q. Including other tables?
A. Ditto.
Here are some possible shortcuts for what you’re trying to accomplish:
If your current site is generating an RSS aggregation link, then WP-RSS-Multi-Importer looks promising.
If your current site doesn’t have RSS, but you have access to the database (via a hosting control panel / phpmyadmin, or via a server command line utility like mysqldump), then you can export the database as CSV or XML and try to import it into WordPress with a plugin like WP-All-Import.
This will take a little more time, since you’ll need to map the data to the appropriate wordpress fields.
If you have neither RSS nor access to the database, then you’re going to need to “scrape” your site. Usually this means coding, but there are several wordpress plugins that might work for you. A lot can go wrong here, so don’t be surprised if the final product isn’t what you want.
A bit more low level – than using cakephp – approach would be the usage of ActiveRecord which helps a lot with dealing with databases.
e.g. use PHP ActiveRecord
You can use a framework like yii or codeigniter. They can make your life very easy. You can make CMS very easily and quickly using these framework.
You can pass the parameter like id