コード例 #1
0
ファイル: pso_service.form.php プロジェクト: aliihaidar/pso
     $obj->DeleteFile($fileFieldName, array('se_id' => $se_id), true, true);
     if ($obj->ErrorMsgs) {
         $_SESSION['errorMsgs'] = $obj->ErrorMsgs;
         $error = '&error=1';
     }
     goToURL($actScript . "?recordId={$se_id}&in2Action=editRecord&frmAction=edit{$error}");
     break;
 case 'edit':
     $_REQUEST['se_mduser'] = $_SESSION['us_id'];
     $_REQUEST['se_mddate'] = $_SESSION['us_id'];
     $notification .= formatFormErrors($obj->ErrorMsgs);
     $obj->UpdateRequest(false);
     foreach ($_FILES as $uploadedFile) {
         $Extention = explode('.', $uploadedFile['name']);
         $uploadedFile['filename'] = 'se_img_' . $_REQUEST['se_id'] . '.' . $Extention[1];
         $fileObj = new file2($uploadedFile);
         $fileObj->manipImageUpload('pso_service', $_REQUEST['se_id'], SERVICE_PHOTO_SML, SERVICE_PHOTO_MED, SERVICE_PHOTO_BIG, true, false, SERVICE_PHOTO_MEDBIG, SERVICE_PHOTO_LRG, SERVICE_PHOTO_BO);
         $fileObj = null;
     }
     $in2Action = 'edit';
     $frmAction = 'edit';
     goToURL($actScript . "?recordId=" . $_REQUEST['se_id'] . "&in2Action=editRecord&frmAction=edit{$error}");
 case 'editRecord':
     if ($recordId) {
         $id = $recordId;
     } elseif ($se_id) {
         $id = $se_id;
     } else {
         $id = null;
     }
     if ($id) {
コード例 #2
0
ファイル: pso_portfolio.form.php プロジェクト: aliihaidar/pso
     $obj->DeleteFile($fileFieldName, array('po_id' => $po_id), true, true);
     if ($obj->ErrorMsgs) {
         $_SESSION['errorMsgs'] = $obj->ErrorMsgs;
         $error = '&error=1';
     }
     goToURL($actScript . "?recordId={$po_id}&in2Action=editRecord&frmAction=edit{$error}");
     break;
 case 'edit':
     $_REQUEST['po_mduser'] = $_SESSION['us_id'];
     $_REQUEST['po_mddate'] = $_SESSION['us_id'];
     $notification .= formatFormErrors($obj->ErrorMsgs);
     $obj->UpdateRequest(false);
     foreach ($_FILES as $uploadedFile) {
         $Extention = explode('.', $uploadedFile['name']);
         $uploadedFile['filename'] = 'po_img_' . $_REQUEST['po_id'] . '.' . $Extention[1];
         $fileObj = new file2($uploadedFile);
         $fileObj->manipImageUpload('pso_portfolio', $_REQUEST['po_id'], FPORTFOLIO_PHOTO_SML, PORTFOLIO_PHOTO_MED, PORTFOLIO_PHOTO_BIG, true, false, PORTFOLIO_PHOTO_MEDBIG, PORTFOLIO_PHOTO_LRG, PORTFOLIO_PHOTO_BO);
         $fileObj = null;
     }
     $in2Action = 'edit';
     $frmAction = 'edit';
     goToURL($actScript . "?recordId=" . $_REQUEST['po_id'] . "&in2Action=editRecord&frmAction=edit{$error}");
 case 'editRecord':
     if ($recordId) {
         $id = $recordId;
     } elseif ($po_id) {
         $id = $po_id;
     } else {
         $id = null;
     }
     if ($id) {
コード例 #3
0
ファイル: index.php プロジェクト: skaligotla/kplaylist
 function xml_link($sid, $encode = false)
 {
     $f2 = new file2($sid, true);
     if ($f2->ifexists()) {
         $fd = new filedesc($f2->fname);
         if ($fd->found && $fd->m3u) {
             $url = httpstreamheader3($fd->fid, $sid, $f2, UTF8MODE);
             if (strlen($url) > 0) {
                 $id3 = $f2->getid3();
                 $title = '';
                 if (is_numeric($id3['track']) && $id3['track'] > 0) {
                     $title .= lzero($id3['track']) . '. ';
                 }
                 $title .= $f2->gentitle(array('title'));
                 $imgurl = '';
                 $ci = new coverinterface();
                 $ci->setartist($f2->id3['artist'], $f2->id3['album']);
                 $ci->setlocation($f2->drive, $f2->relativepath);
                 if ($ci->coverexists()) {
                     $ci->geturl($imgurl, true, true);
                 }
                 $this->items[] = array($imgurl, $url, $title, $fd->extension, $id3['length']);
             }
         }
     }
 }
コード例 #4
0
ファイル: usr.form.php プロジェクト: aliihaidar/pso
     if ($obj->ErrorMsgs) {
         $_SESSION['errorMsgs'] = $obj->ErrorMsgs;
         $error = '&error=1';
     }
     goToURL($actScript . "?recordId={$us_id}&in2Action=editRecord&frmAction=edit{$error}");
     break;
 case 'edit':
     $_REQUEST['us_mduser'] = $_SESSION['us_id'];
     $_REQUEST['us_mddate'] = date('Y-m-d H:i:s');
     $_REQUEST['us_password'] = md5($_REQUEST['us_password']);
     $notification .= formatFormErrors($obj->ErrorMsgs);
     $obj->UpdateRequest(false);
     foreach ($_FILES as $uploadedFile) {
         $Extention = explode('.', $uploadedFile['name']);
         $uploadedFile['filename'] = 'us_img_' . $_REQUEST['us_id'] . '.' . $Extention[1];
         $fileObj = new file2($uploadedFile);
         $fileObj->manipImageUpload('usr', $_REQUEST['us_id'], FEATURED_PHOTO_SML, FEATURED_PHOTO_MED, FEATURED_PHOTO_BIG, true, false, FEATURED_PHOTO_MEDBIG, FEATURED_PHOTO_LRG, FEATURED_PHOTO_BO);
         $fileObj = null;
     }
     $in2Action = 'edit';
     $frmAction = 'edit';
     goToURL($actScript . "?recordId=" . $_REQUEST['us_id'] . "&in2Action=editRecord&frmAction=edit{$error}");
 case 'editRecord':
     if ($recordId) {
         $id = $recordId;
     } elseif ($us_id) {
         $id = $us_id;
     } else {
         $id = null;
     }
     if ($id) {
コード例 #5
0
ファイル: pso_request.form.php プロジェクト: aliihaidar/pso
     $obj->DeleteFile($fileFieldName, array('re_id' => $re_id), true, true);
     if ($obj->ErrorMsgs) {
         $_SESSION['errorMsgs'] = $obj->ErrorMsgs;
         $error = '&error=1';
     }
     goToURL($actScript . "?recordId={$re_id}&in2Action=editRecord&frmAction=edit{$error}");
     break;
 case 'edit':
     $_REQUEST['re_mduser'] = $_SESSION['us_id'];
     $_REQUEST['re_mddate'] = $_SESSION['us_id'];
     $notification .= formatFormErrors($obj->ErrorMsgs);
     $obj->UpdateRequest(false);
     foreach ($_FILES as $uploadedFile) {
         $Extention = explode('.', $uploadedFile['name']);
         $uploadedFile['filename'] = 're_img_' . $_REQUEST['re_id'] . '.' . $Extention[1];
         $fileObj = new file2($uploadedFile);
         $fileObj->manipImageUpload('pso_request', $_REQUEST['re_id'], REQUEST_PHOTO_SML, REQUEST_PHOTO_MED, REQUEST_PHOTO_BIG, true, false, REQUEST_PHOTO_MEDBIG, REQUEST_PHOTO_LRG, REQUEST_PHOTO_BO);
         $fileObj = null;
     }
     $in2Action = 'edit';
     $frmAction = 'edit';
     goToURL($actScript . "?recordId=" . $_REQUEST['re_id'] . "&in2Action=editRecord&frmAction=edit{$error}");
 case 'editRecord':
     if ($recordId) {
         $id = $recordId;
     } elseif ($re_id) {
         $id = $re_id;
     } else {
         $id = null;
     }
     if ($id) {
コード例 #6
0
ファイル: pso_slider.form.php プロジェクト: aliihaidar/pso
     $obj->DeleteFile($fileFieldName, array('sl_id' => $sl_id), true, true);
     if ($obj->ErrorMsgs) {
         $_SESSION['errorMsgs'] = $obj->ErrorMsgs;
         $error = '&error=1';
     }
     goToURL($actScript . "?recordId={$sl_id}&in2Action=editRecord&frmAction=edit{$error}");
     break;
 case 'edit':
     $_REQUEST['sl_mduser'] = $_SESSION['us_id'];
     $_REQUEST['sl_mddate'] = $_SESSION['us_id'];
     $notification .= formatFormErrors($obj->ErrorMsgs);
     $obj->UpdateRequest(false);
     foreach ($_FILES as $uploadedFile) {
         $Extention = explode('.', $uploadedFile['name']);
         $uploadedFile['filename'] = 'sl_img_' . $_REQUEST['sl_id'] . '.' . $Extention[1];
         $fileObj = new file2($uploadedFile);
         $fileObj->manipImageUpload('pso_slider', $_REQUEST['sl_id'], SLIDEHOME_PHOTO_SML, SLIDEHOME_PHOTO_MED, SLIDEHOME_PHOTO_BIG, true, false, SLIDEHOME_PHOTO_MEDBIG, SLIDEHOME_PHOTO_LRG, SLIDEHOME_PHOTO_BO);
         $fileObj = null;
     }
     $in2Action = 'edit';
     $frmAction = 'edit';
     goToURL($actScript . "?recordId=" . $_REQUEST['sl_id'] . "&in2Action=editRecord&frmAction=edit{$error}");
 case 'editRecord':
     if ($recordId) {
         $id = $recordId;
     } elseif ($sl_id) {
         $id = $sl_id;
     } else {
         $id = null;
     }
     if ($id) {
コード例 #7
0
     $obj->DeleteFile($fileFieldName, array('sp_id' => $sp_id), true, true);
     if ($obj->ErrorMsgs) {
         $_SESSION['errorMsgs'] = $obj->ErrorMsgs;
         $error = '&error=1';
     }
     goToURL($actScript . "?recordId={$sp_id}&in2Action=editRecord&frmAction=edit{$error}");
     break;
 case 'edit':
     $_REQUEST['sp_mduser'] = $_SESSION['us_id'];
     $_REQUEST['sp_mddate'] = $_SESSION['us_id'];
     $notification .= formatFormErrors($obj->ErrorMsgs);
     $obj->UpdateRequest(false);
     foreach ($_FILES as $uploadedFile) {
         $Extention = explode('.', $uploadedFile['name']);
         $uploadedFile['filename'] = 'sp_img_' . $_REQUEST['sp_id'] . '.' . $Extention[1];
         $fileObj = new file2($uploadedFile);
         $fileObj->manipImageUpload('pso_staticpage', $_REQUEST['sp_id'], STATICPAGE_PHOTO_SML, STATICPAGE_PHOTO_MED, STATICPAGE_PHOTO_BIG, true, false, STATICPAGE_PHOTO_MEDBIG, STATICPAGE_PHOTO_LRG, STATICPAGE_PHOTO_BO);
         $fileObj = null;
     }
     $in2Action = 'edit';
     $frmAction = 'edit';
     goToURL($actScript . "?recordId=" . $_REQUEST['sp_id'] . "&in2Action=editRecord&frmAction=edit{$error}");
 case 'editRecord':
     if ($recordId) {
         $id = $recordId;
     } elseif ($sp_id) {
         $id = $sp_id;
     } else {
         $id = null;
     }
     if ($id) {
コード例 #8
0
ファイル: pso_client.form.php プロジェクト: aliihaidar/pso
     $obj->DeleteFile($fileFieldName, array('cl_id' => $cl_id), true, true);
     if ($obj->ErrorMsgs) {
         $_SESSION['errorMsgs'] = $obj->ErrorMsgs;
         $error = '&error=1';
     }
     goToURL($actScript . "?recordId={$cl_id}&in2Action=editRecord&frmAction=edit{$error}");
     break;
 case 'edit':
     $_REQUEST['cl_mduser'] = $_SESSION['us_id'];
     $_REQUEST['cl_mddate'] = $_SESSION['us_id'];
     $notification .= formatFormErrors($obj->ErrorMsgs);
     $obj->UpdateRequest(false);
     foreach ($_FILES as $uploadedFile) {
         $Extention = explode('.', $uploadedFile['name']);
         $uploadedFile['filename'] = 'cl_img_' . $_REQUEST['cl_id'] . '.' . $Extention[1];
         $fileObj = new file2($uploadedFile);
         $fileObj->manipImageUpload('pso_client', $_REQUEST['cl_id'], CLIENT_PHOTO_SML, CLIENT_PHOTO_MED, CLIENT_PHOTO_BIG, true, false, CLIENT_PHOTO_MEDBIG, CLIENT_PHOTO_LRG, CLIENT_PHOTO_BO);
         $fileObj = null;
     }
     $in2Action = 'edit';
     $frmAction = 'edit';
     goToURL($actScript . "?recordId=" . $_REQUEST['cl_id'] . "&in2Action=editRecord&frmAction=edit{$error}");
 case 'editRecord':
     if ($recordId) {
         $id = $recordId;
     } elseif ($cl_id) {
         $id = $cl_id;
     } else {
         $id = null;
     }
     if ($id) {
コード例 #9
0
     $obj->DeleteFile($fileFieldName, array('pocat_id' => $pocat_id), true, true);
     if ($obj->ErrorMsgs) {
         $_SESSION['errorMsgs'] = $obj->ErrorMsgs;
         $error = '&error=1';
     }
     goToURL($actScript . "?recordId={$pocat_id}&in2Action=editRecord&frmAction=edit{$error}");
     break;
 case 'edit':
     $_REQUEST['pocat_mduser'] = $_SESSION['us_id'];
     $_REQUEST['pocat_mddate'] = date('Y-m-d H:i:s');
     $notification .= formatFormErrors($obj->ErrorMsgs);
     $obj->UpdateRequest(false);
     foreach ($_FILES as $uploadedFile) {
         $Extention = explode('.', $uploadedFile['name']);
         $uploadedFile['filename'] = 'pocat_img_' . $_REQUEST['pocat_id'] . '.' . $Extention[1];
         $fileObj = new file2($uploadedFile);
         $fileObj->manipImageUpload('pso_portfolio_cat', $_REQUEST['pocat_id'], PROJECTS_CAT_PHOTO_SML, PROJECTS_CAT_PHOTO_MED, PROJECTS_CAT_PHOTO_BIG, true, false, PROJECTS_CAT_PHOTO_MEDBIG, PROJECTS_CAT_PHOTO_LRG, PROJECTS_CAT_PHOTO_BO);
         $fileObj = null;
     }
     $in2Action = 'edit';
     $frmAction = 'edit';
     goToURL($actScript . "?recordId=" . $_REQUEST['pocat_id'] . "&in2Action=editRecord&frmAction=edit{$error}");
 case 'editRecord':
     if ($recordId) {
         $id = $recordId;
     } elseif ($pocat_id) {
         $id = $pocat_id;
     } else {
         $id = null;
     }
     if ($id) {
コード例 #10
0
ファイル: index.php プロジェクト: Git-Host/AMPPS
 function xml_link($sid, $encode = false)
 {
     $f2 = new file2($sid, true);
     if ($f2->ifexists()) {
         $fd = new filedesc($f2->fname);
         if ($fd->found && $fd->m3u) {
             $url = httpstreamheader3($fd->fid, $sid, $f2);
             if (strlen($url) > 0) {
                 $title = $f2->gentitle(array('title'));
                 $creator = $f2->id3['artist'];
                 $kpi = new kpimage(false, $f2->drive, $f2->relativepath);
                 if ($kpi->find()) {
                     $kpi->resize();
                     $imgurl = $kpi->geturl(true);
                 } else {
                     $imgurl = '';
                 }
                 if ($encode) {
                     $imgurl = urlencode($imgurl);
                     $url = urlencode($url);
                 }
                 $this->data .= '<track>' . $this->crlf;
                 $this->data .= '<title>' . $title . '</title>' . $this->crlf;
                 $this->data .= '<creator>' . $creator . '</creator>' . $this->crlf;
                 $this->data .= '<image>' . $imgurl . '</image>' . $this->crlf;
                 $this->data .= '<location>' . $url . '</location>' . $this->crlf;
                 $this->data .= '</track>' . $this->crlf;
             }
         }
     }
 }