{$cm_text["synd-selectasynd"]}

"; echo "
\n"; echo ""; echo "
\n"; echo "
\n"; echo "
\n"; echo "
\n"; echo "
\n"; echo "
\n"; echo "

{$cm_text["synd-moresynd"]}

\n"; echo ""; echo ""; echo "
\n"; } if ($cmru) { echo "

{$cm_text["setup-return"]}

"; } if (($cm_superuser) && ($cm_superuser == $user_kurz)) { echo "

{$cm_text["synd-welcome"]}

"; if ($cm_delsynd) { if ($cm_sel_newsfeed) { $result1 = db_query("delete from " . CM_DB_PREFIX . "cmsynd3 where cmdb_title like '$cm_sel_newsfeed'") or db_die(); fcm_message ($cm_text["synd-deletedsynd"], CM_MSGSTYLE_INFORMATION); fcm_add_logentry ("", $user_kurz, CM_APPLOG_EDIT_SYND, "Deleted syndication newsfeed $cm_sel_newsfeed."); fcm_display_selform (); } else { fcm_display_selform (); } } elseif ($cm_editsynd) { if ($cm_sel_newsfeed) { $result1 = db_query("select cmdb_uri, cmdb_title, cmdb_ttl, cmdb_autodl, cmdb_inhome, cmdb_visitems from " . CM_DB_PREFIX . "cmsynd3 where cmdb_title = '" . $cm_sel_newsfeed . "'") or db_die(); $row1 = db_fetch_row($result1); echo "
\n"; echo ""; echo "{$cm_text["synd-title"]}: $cm_sel_newsfeed"; echo "
\n"; echo "{$cm_text["synd-url"]}:
"; echo "
\n"; echo "{$cm_text["synd-ttl"]}: "; fcm_val_droplist ("cm_synd_ttl", array(1,5,10,30,60,120,300,600,900,1440), $row1[2]); echo " "; echo "{$cm_text["synd-autodl"]}
\n"; echo " "; echo "{$cm_text["synd-showinhome"]}
\n"; echo "{$cm_text["synd-maxitems"]}: "; fcm_val_droplist ("cm_synd_maxitems", array(1,3,5,7,10,15,20,30), $row1[5]); echo "
\n"; echo "
\n"; echo "
\n"; } else { fcm_display_selform (); } } elseif ($cm_addsynd) { echo "
\n"; echo ""; echo "{$cm_text["synd-title"]}:
"; echo "
\n"; echo "{$cm_text["synd-url"]}:
"; echo "
\n"; echo "{$cm_text["synd-ttl"]}: "; fcm_val_droplist ("cm_synd_ttl", array(1,5,10,30,60,120,300,600,900,1440), 300); echo " "; echo "{$cm_text["synd-autodl"]}
\n"; echo " "; echo "{$cm_text["synd-showinhome"]}
\n"; echo "{$cm_text["synd-maxitems"]}: "; fcm_val_droplist ("cm_synd_maxitems", array(1,3,5,7,10,15,20,30), 5); echo "
\n"; echo "
\n"; echo "
\n"; } elseif ($cm_savesynd) { $cm_pub_date = fcm_curdate_string (); $cm_old_date = "1999-01-01 01:01:01"; $cm_synd_autodl = abs ($cm_synd_autodl); $cm_synd_showinhome = abs ($cm_synd_showinhome); $cm_synd_maxitems = abs ($cm_synd_maxitems); $result1 = db_query("select cmdb_type, cmdb_title from " . CM_DB_PREFIX . "cmsynd3 where cmdb_title like '$cm_synd_title'") or db_die(); $row1 = db_fetch_row($result1); if ($row1[0]) { $result2 = db_query("update " . CM_DB_PREFIX . "cmsynd3 set cmdb_uri='$cm_synd_url', cmdb_date_creation='$cm_pub_date', cmdb_date_update='$cm_old_date', cmdb_ttl=$cm_synd_ttl,cmdb_autodl=$cm_synd_autodl,cmdb_inhome=$cm_synd_showinhome,cmdb_visitems=$cm_synd_maxitems where cmdb_title like '$cm_synd_title'") or db_die(); fcm_add_logentry ("", $user_kurz, CM_APPLOG_EDIT_SYND, "Edited syndication newsfeed $cm_synd_title"); fcm_message ($cm_text["synd-editedsynd"], CM_MSGSTYLE_INFORMATION); } else { $result2 = db_query("insert into " . CM_DB_PREFIX . "cmsynd3 values($dbIDnull,'" . CM_HITTYPE_SYND . "','$cm_synd_url','$cm_synd_title',null,'$cm_pub_date','$cm_old_date',$cm_synd_ttl,$cm_synd_autodl,$cm_synd_showinhome,$cm_synd_maxitems,'$cm_rdf_content')") or db_die(); fcm_add_logentry ("", $user_kurz, CM_APPLOG_EDIT_SYND, "Added syndication newsfeed $cm_synd_title"); fcm_message ($cm_text["synd-addedsynd"], CM_MSGSTYLE_INFORMATION); } fcm_display_selform (); } else { fcm_display_selform (); } } else { echo "

{$cm_text["synd-welcome"]}

"; echo "

{$cm_text["setup-currentuser"]} $user_kurz
"; echo "{$cm_text["setup-superuseris"]} $cm_superuser

"; fcm_message ($cm_text["synd-nosuperuser"], CM_MSGSTYLE_ERROR); fcm_add_logentry ("", $user_kurz, CM_APPLOG_ERROR, "Error when editing syndication newsfeeds. Not enough permissions."); } if ($cmru) { echo "

{$cm_text["setup-return"]}

"; } echo $cm_html_footer; ?>