Content Management - Base Content


Published on

Learning the basics of using the content management system in ProdigyView.

Published in: Technology
  • Be the first to comment

  • Be the first to like this

No Downloads
Total views
On SlideShare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide

Content Management - Base Content

  1. 1. Content Management – Base Content
  2. 2. OverviewObjectiveLearn the basics of the content management system inProdigyView and how to manipulate base content.Requirements Installed version of ProdigyView with a databaseEstimated Time8 minutes
  3. 3. Follow Along With Code Example1. Download a copy of the example code at Install the system in an environment you feel comfortable testing in.3. Proceed to examples/content/BasicContentExample.php
  4. 4. What is Content Management?One of the features that ProdigyView offers is a built-in cms thatsupports all kinds of content including audio, video, file, eventand ecommerce. Important!The content management is meant to be a way of quicklybuilding sites and presenting a proof of concept orprototypes to stakeholders and decisions makers such as theCEO, Managers, and Investors.The cms contains many extra fields that do not make suitablefor a scaled production. If you are going to use the cms inproduction, remember to optimize your database.
  5. 5. Base Content Base content is the parent content for all the other content types. Whenever you are creating a different content type, you will be using base content. Base ContentAudio Video Event E-commerce File
  6. 6. Creating Base Content Creating base content is relatively easy. It only requires defining fields and passing them into PVContent::createContent method.1. Set the contentarguments in anarray2. Pass thearguments into thecreateContentmethod3. Return the id ofthe content
  7. 7. Database CheckThe content should look something like this in yourdatabase.
  8. 8. Base Content Fields In our last example, we only used three fields for creating content. When using base content, you have access to a variety of fields that can help you differentiate your content and set data. Below is a larger data set of fields that can be used.content_id date_active content_languagecontent_title date_inactive translate_contentcontent_description date_created content_approvedparent_content date_modified content_parametersapp_id is_searchable sym_linkowner_id allow_comments content_ordercontent_meta_tags allow_rating content_access_levelcontent_meta_description content_activecontent_thumbnail content_promotedcontent_alias content_permissions
  9. 9. Unique Alias One of the features we skipped over before was the ability to create a unique content alias. The content alias is a unique human readable string identifier that can be given to any content type. 1. Create the unique alias based upon the based text content2. Set the content alias 3. Create the contentin the args array
  10. 10. Searching For ContentSearching for content create is relatively easy. The PV StandardSearch Query is used with PVContent::getContentList() method. Thiswill return an array of arrays. 1. Search based on the passed arguments 2. Pass args into getContentList() method 3. Returns an array of arrays that contains the list of content
  11. 11. Iterate Through ArrayAfter we have retrieved out list of data, we can iteratethrough it. Each row will be the data associated with adifferent content id.1. Iterate through the list of arrays 2. Get the information associated with each row
  12. 12. Retrieving ContentNext we are going to retrieve content with a variable.Remember the id of the content that was returned before? Wecan use that for retrieving data associated with that id in theform of an array. 1. The ID of the content 2. The content returned in an array
  13. 13. Updating The ContentWhen the array is returned, is contains all the dataassociated with that content id from the database. If we wantto update the content, we change an index in the array andpass the content back. 1. getContentIDByAlias return the id of content with the alias 2. Use the id and retrieve the data associated with that id3. Change a value in the content array 4. Pass the array in updateContent
  14. 14. Deleting ContentThe final action when dealing with content is deleting. Todelete the content, pass in the id of the content you wantto delete into PVContent::deleteContent().
  15. 15. Review1. Create base content by passing an array of arguments into PVContent::createContent()2. PVContent::createContent() will return the id of the newly generated content3. Search for content by using the syntax from PV Standard Search Query and passing those arguments into PVContent::getContentList()4. Update content by passing an array of accepted fields in PVContent::updateContent(). The content_id must be present for this method to work.5. Delete content by passing the content_id into PVContent::deleteContent().
  16. 16. API ReferenceFor a better understanding of base content, visit the apiby clicking on the link below.PVContent More TutorialsFor more tutorials, please visit: