1234567891011121314151617181920212223242526 |
- <?php
- /* For licensing terms, see /license.txt */
- /**
- * This script generates four session categories.
- */
- require_once '../../main/inc/global.inc.php';
- api_protect_admin_script();
- $accessUrlId = api_get_current_access_url_id();
- $categories = array(
- 'capacitaciones',
- 'programas',
- 'especializaciones',
- 'cursos prácticos'
- );
- $tableSessionCategory = Database::get_main_table(TABLE_MAIN_SESSION_CATEGORY);
- foreach ($categories as $category) {
- Database::insert(
- $tableSessionCategory,
- [
- 'name' => $category,
- 'access_url_id' => $accessUrlId
- ]
- );
- }
|