1: <?php
2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14:
15: defined('CON_FRAMEWORK') || die('Illegal call: Missing framework initialization - request aborted.');
16:
17: 18: 19: 20: 21: 22: 23:
24: class cUpgradeJob_0016 extends cUpgradeJobAbstract {
25:
26: public $maxVersion = "4.9.5";
27:
28: public function _execute() {
29: global $db, $cfg;
30:
31: if ($_SESSION['setuptype'] == 'upgrade') {
32:
33:
34: $groupColl = new cApiGroupCollection();
35:
36:
37: $groupColl->select();
38:
39: while ($group = $groupColl->next()) {
40:
41: $groupname = stripcslashes(preg_replace("/\"/", "", ($group->get('groupname'))));
42: $description = stripcslashes(preg_replace("/\"/", "", ($group->get('description'))));
43:
44: $group->set('groupname', $groupname);
45: $group->set('description', $description);
46:
47:
48: $group->store();
49:
50: }
51:
52:
53: $metaColl = new cApiMetaTagCollection();
54:
55:
56: $metaColl->select();
57:
58: while ($meta = $metaColl->next()) {
59:
60: $metavalue = stripcslashes(preg_replace("/\"/", "", ($meta->get('metavalue'))));
61: $meta->set('metavalue', $metavalue);
62:
63:
64: $meta->store();
65:
66: }
67:
68:
69: $uplColl = new cApiUploadMetaCollection();
70:
71:
72: $uplColl->select();
73:
74: while ($upl = $uplColl->next()) {
75:
76: $medianame = stripcslashes(preg_replace("/\"/", "", ($upl->get('medianame'))));
77: $description = stripcslashes(preg_replace("/\"/", "", ($upl->get('description'))));
78: $keywords = stripcslashes(preg_replace("/\"/", "", ($upl->get('keywords'))));
79: $internal_notice = stripcslashes(preg_replace("/\"/", "", ($upl->get('internal_notice'))));
80: $copyright = stripcslashes(preg_replace("/\"/", "", ($upl->get('copyright'))));
81:
82: $upl->set('medianame', $medianame);
83: $upl->set('description', $description);
84: $upl->set('keywords', $keywords);
85: $upl->set('internal_notice', $internal_notice);
86: $upl->set('copyright', $copyright);
87:
88:
89: $upl->store();
90:
91: }
92:
93: }
94: }
95:
96: }
97: