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