Lines Matching defs:dst

29      * @param $dst
32 public function checkPage($src, $dst) {
53 if($src == $dst) {
59 if(page_exists($dst)) {
60 msg(sprintf($this->getLang('exists'), $src, $dst), -1);
65 if(auth_quickaclcheck($dst) < AUTH_CREATE) {
66 msg(sprintf($this->getLang('notargetperms'), $dst), -1);
77 * @param $dst
80 public function checkMedia($src, $dst) {
92 if($src == $dst) {
98 if(@file_exists(mediaFN($dst))) {
99 msg(sprintf($this->getLang('mediaexists'), $src, $dst), -1);
104 if(auth_quickaclcheck($dst) < AUTH_UPLOAD) {
105 msg(sprintf($this->getLang('nomediatargetperms'), $dst), -1);
110 if (pathinfo(mediaFN($src), PATHINFO_EXTENSION) !== pathinfo(mediaFN($dst), PATHINFO_EXTENSION)) {
122 * @param string $dst new ID
125 public function movePage($src, $dst) {
126 if(!$this->checkPage($src, $dst)) return false;
139 $affected_pages[] = $dst; // the current page is always affected, because all relative links may have changed
144 $dst_ns = getNS($dst);
145 $dst_name = noNS($dst);
158 'dst_id' => $dst,
173 if(($idx_msg = $Indexer->renamePage($src, $dst)) !== true
174 || ($idx_msg = $Indexer->renameMetaValue('relation_references', $src, $dst)) !== true
192 $summary = $this->symbol . ' ' . sprintf($this->getLang($lang_key), $src, $dst);
200 saveWikiText($dst, $text, $summary);
203 if(@file_exists(wikiFN($dst))) {
215 $Rewriter->setMoveMeta($id, $src, $dst, 'pages');
235 * @param string $dst new ID
238 public function moveMedia($src, $dst) {
239 if(!$this->checkMedia($src, $dst)) return false;
246 $dst_ns = getNS($dst);
247 $dst_name = noNS($dst);
260 'dst_id' => $dst,
275 if(($idx_msg = $Indexer->renameMetaValue('relation_media', $src, $dst)) !== true) {
285 io_createNamespace($dst, 'media');
288 if(!io_rename(mediaFN($src), mediaFN($dst))) {
304 $Rewriter->setMoveMeta($id, $src, $dst, 'media');