Commit b736fef6d862fb703f812baf8deebd5b03b4807f

Authored by conradverm
1 parent 294e2812

KTS-1687

"Double quote to single quote conversion"
Fixed.
Reviewed by: Kevin Fourie

git-svn-id: https://kt-dms.svn.sourceforge.net/svnroot/kt-dms/trunk@6215 c91229c3-7414-0410-bfa2-8a42b809f60b
Showing 1 changed file with 41 additions and 41 deletions
browse.php
... ... @@ -28,27 +28,27 @@
28 28 */
29 29  
30 30 // main library routines and defaults
31   -require_once("config/dmsDefaults.php");
32   -require_once(KT_LIB_DIR . "/templating/templating.inc.php");
33   -require_once(KT_LIB_DIR . "/templating/kt3template.inc.php");
34   -require_once(KT_LIB_DIR . "/dispatcher.inc.php");
35   -require_once(KT_LIB_DIR . "/util/ktutil.inc");
36   -require_once(KT_LIB_DIR . "/browse/DocumentCollection.inc.php");
37   -require_once(KT_LIB_DIR . "/browse/BrowseColumns.inc.php");
38   -require_once(KT_LIB_DIR . "/browse/PartialQuery.inc.php");
39   -require_once(KT_LIB_DIR . "/browse/browseutil.inc.php");
40   -
41   -require_once(KT_LIB_DIR . "/foldermanagement/Folder.inc");
42   -require_once(KT_LIB_DIR . "/documentmanagement/DocumentType.inc");
43   -require_once(KT_LIB_DIR . "/documentmanagement/Document.inc");
44   -require_once(KT_LIB_DIR . "/documentmanagement/DocumentField.inc");
45   -
46   -require_once(KT_LIB_DIR . "/widgets/portlet.inc.php");
  31 +require_once('config/dmsDefaults.php');
  32 +require_once(KT_LIB_DIR . '/templating/templating.inc.php');
  33 +require_once(KT_LIB_DIR . '/templating/kt3template.inc.php');
  34 +require_once(KT_LIB_DIR . '/dispatcher.inc.php');
  35 +require_once(KT_LIB_DIR . '/util/ktutil.inc');
  36 +require_once(KT_LIB_DIR . '/browse/DocumentCollection.inc.php');
  37 +require_once(KT_LIB_DIR . '/browse/BrowseColumns.inc.php');
  38 +require_once(KT_LIB_DIR . '/browse/PartialQuery.inc.php');
  39 +require_once(KT_LIB_DIR . '/browse/browseutil.inc.php');
  40 +
  41 +require_once(KT_LIB_DIR . '/foldermanagement/Folder.inc');
  42 +require_once(KT_LIB_DIR . '/documentmanagement/DocumentType.inc');
  43 +require_once(KT_LIB_DIR . '/documentmanagement/Document.inc');
  44 +require_once(KT_LIB_DIR . '/documentmanagement/DocumentField.inc');
  45 +
  46 +require_once(KT_LIB_DIR . '/widgets/portlet.inc.php');
47 47 require_once(KT_LIB_DIR . '/actions/folderaction.inc.php');
48 48 require_once(KT_DIR . '/plugins/ktcore/KTFolderActions.php');
49 49  
50   -require_once(KT_LIB_DIR . "/permissions/permissionutil.inc.php");
51   -require_once(KT_LIB_DIR . "/permissions/permission.inc.php");
  50 +require_once(KT_LIB_DIR . '/permissions/permissionutil.inc.php');
  51 +require_once(KT_LIB_DIR . '/permissions/permission.inc.php');
52 52  
53 53 require_once(KT_LIB_DIR . '/users/userhistory.inc.php');
54 54  
... ... @@ -56,14 +56,14 @@ require_once(KT_LIB_DIR . '/browse/columnregistry.inc.php');
56 56 require_once(KT_LIB_DIR . '/actions/entitylist.php');
57 57 require_once(KT_LIB_DIR . '/actions/bulkaction.php');
58 58  
59   -$sectionName = "browse";
  59 +$sectionName = 'browse';
60 60  
61 61 class BrowseDispatcher extends KTStandardDispatcher {
62 62  
63 63 var $sName = 'ktcore.actions.folder.view';
64 64  
65 65 var $oFolder = null;
66   - var $sSection = "browse";
  66 + var $sSection = 'browse';
67 67 var $browse_mode = null;
68 68 var $query = null;
69 69 var $resultURL;
... ... @@ -78,7 +78,7 @@ class BrowseDispatcher extends KTStandardDispatcher {
78 78 }
79 79  
80 80 function check() {
81   - $this->browse_mode = KTUtil::arrayGet($_REQUEST, 'fBrowseMode', "folder");
  81 + $this->browse_mode = KTUtil::arrayGet($_REQUEST, 'fBrowseMode', 'folder');
82 82 $action = KTUtil::arrayGet($_REQUEST, $this->event_var, 'main');
83 83 $this->editable = false;
84 84  
... ... @@ -92,7 +92,7 @@ class BrowseDispatcher extends KTStandardDispatcher {
92 92  
93 93 // folder browse mode
94 94 if ($this->browse_mode == 'folder') {
95   - $in_folder_id = KTUtil::arrayGet($_REQUEST, "fFolderId");
  95 + $in_folder_id = KTUtil::arrayGet($_REQUEST, 'fFolderId');
96 96 if (empty($in_folder_id)) {
97 97 $oConfig = KTConfig::getSingleton();
98 98 if ($oConfig->get('tweaks/browseToUnitFolder')) {
... ... @@ -146,7 +146,7 @@ class BrowseDispatcher extends KTStandardDispatcher {
146 146 'ignorepermissions' => KTBrowseUtil::inAdminMode($this->oUser, $oFolder),
147 147 );
148 148 $this->oQuery = new BrowseQuery($oFolder->getId(), $this->oUser, $aOptions);
149   - $this->resultURL = KTUtil::addQueryString($_SERVER['PHP_SELF'], sprintf("fFolderId=%d", $oFolder->getId()));
  149 + $this->resultURL = KTUtil::addQueryString($_SERVER['PHP_SELF'], sprintf('fFolderId=%d', $oFolder->getId()));
150 150  
151 151 // and the portlets
152 152 $portlet = new KTActionPortlet(sprintf(_kt('About this folder')));
... ... @@ -183,7 +183,7 @@ class BrowseDispatcher extends KTStandardDispatcher {
183 183  
184 184 $this->oQuery = new ValueBrowseQuery($oField, $oValue);
185 185 $this->resultURL = KTUtil::addQueryString($_SERVER['PHP_SELF'],
186   - sprintf("fBrowseMode=lookup_value&fField=%d&fValue=%d", $field, $value));
  186 + sprintf('fBrowseMode=lookup_value&fField=%d&fValue=%d', $field, $value));
187 187  
188 188 // setup breadcrumbs
189 189 $this->aBreadcrumbs =
... ... @@ -193,7 +193,7 @@ class BrowseDispatcher extends KTStandardDispatcher {
193 193 array('name' => $oField->getName(),
194 194 'url' => KTUtil::addQueryString($_SERVER['PHP_SELF'], 'action=selectLookup&fField=' . $oField->getId())),
195 195 array('name' => $oValue->getName(),
196   - 'url' => KTUtil::addQueryString($_SERVER['PHP_SELF'], sprintf("fBrowseMode=lookup_value&fField=%d&fValue=%d", $field, $value))));
  196 + 'url' => KTUtil::addQueryString($_SERVER['PHP_SELF'], sprintf('fBrowseMode=lookup_value&fField=%d&fValue=%d', $field, $value))));
197 197  
198 198  
199 199  
... ... @@ -215,7 +215,7 @@ class BrowseDispatcher extends KTStandardDispatcher {
215 215 $this->aBreadcrumbs[] = array('name' => _kt('Document Types'), 'url' => KTUtil::addQueryString($_SERVER['PHP_SELF'], 'action=selectType'));
216 216 $this->aBreadcrumbs[] = array('name' => $oDocType->getName(), 'url' => KTUtil::addQueryString($_SERVER['PHP_SELF'], 'fBrowseMode=document_type&fType=' . $oDocType->getId()));
217 217  
218   - $this->resultURL = KTUtil::addQueryString($_SERVER['PHP_SELF'], sprintf("fType=%s&fBrowseMode=document_type", $doctype));;
  218 + $this->resultURL = KTUtil::addQueryString($_SERVER['PHP_SELF'], sprintf('fType=%s&fBrowseMode=document_type', $doctype));;
219 219  
220 220  
221 221 } else {
... ... @@ -248,10 +248,10 @@ class BrowseDispatcher extends KTStandardDispatcher {
248 248 $aBulkActions = KTBulkActionUtil::getAllBulkActions();
249 249  
250 250 $oTemplating =& KTTemplating::getSingleton();
251   - $oTemplate = $oTemplating->loadTemplate("kt3/browse");
  251 + $oTemplate = $oTemplating->loadTemplate('kt3/browse');
252 252 $aTemplateData = array(
253   - "context" => $this,
254   - "collection" => $collection,
  253 + 'context' => $this,
  254 + 'collection' => $collection,
255 255 'browse_mode' => $this->browse_mode,
256 256 'isEditable' => $this->editable,
257 257 'bulkactions' => $aBulkActions,
... ... @@ -277,10 +277,10 @@ class BrowseDispatcher extends KTStandardDispatcher {
277 277 $_REQUEST['fBrowseMode'] = 'lookup_value';
278 278  
279 279 $oTemplating =& KTTemplating::getSingleton();
280   - $oTemplate = $oTemplating->loadTemplate("kt3/browse_lookup_selection");
  280 + $oTemplate = $oTemplating->loadTemplate('kt3/browse_lookup_selection');
281 281 $aTemplateData = array(
282   - "context" => $this,
283   - "fields" => $aFields,
  282 + 'context' => $this,
  283 + 'fields' => $aFields,
284 284 );
285 285 return $oTemplate->render($aTemplateData);
286 286 }
... ... @@ -298,11 +298,11 @@ class BrowseDispatcher extends KTStandardDispatcher {
298 298 $aValues = MetaData::getByDocumentField($oField);
299 299  
300 300 $oTemplating =& KTTemplating::getSingleton();
301   - $oTemplate = $oTemplating->loadTemplate("kt3/browse_lookup_value");
  301 + $oTemplate = $oTemplating->loadTemplate('kt3/browse_lookup_value');
302 302 $aTemplateData = array(
303   - "context" => $this,
304   - "oField" => $oField,
305   - "values" => $aValues,
  303 + 'context' => $this,
  304 + 'oField' => $oField,
  305 + 'values' => $aValues,
306 306 );
307 307 return $oTemplate->render($aTemplateData);
308 308 }
... ... @@ -319,10 +319,10 @@ class BrowseDispatcher extends KTStandardDispatcher {
319 319 }
320 320  
321 321 $oTemplating =& KTTemplating::getSingleton();
322   - $oTemplate = $oTemplating->loadTemplate("kt3/browse_types");
  322 + $oTemplate = $oTemplating->loadTemplate('kt3/browse_types');
323 323 $aTemplateData = array(
324   - "context" => $this,
325   - "document_types" => $aTypes,
  324 + 'context' => $this,
  325 + 'document_types' => $aTypes,
326 326 );
327 327 return $oTemplate->render($aTemplateData);
328 328 }
... ... @@ -345,7 +345,7 @@ class BrowseDispatcher extends KTStandardDispatcher {
345 345 // log this entry
346 346 $oLogEntry =& KTUserHistory::createFromArray(array(
347 347 'userid' => $this->oUser->getId(),
348   - 'datetime' => date("Y-m-d H:i:s", time()),
  348 + 'datetime' => date('Y-m-d H:i:s', time()),
349 349 'actionnamespace' => 'ktcore.user_history.enable_admin_mode',
350 350 'comments' => 'Admin Mode enabled',
351 351 'sessionid' => $_SESSION['sessionID'],
... ... @@ -389,7 +389,7 @@ class BrowseDispatcher extends KTStandardDispatcher {
389 389 // log this entry
390 390 $oLogEntry =& KTUserHistory::createFromArray(array(
391 391 'userid' => $this->oUser->getId(),
392   - 'datetime' => date("Y-m-d H:i:s", time()),
  392 + 'datetime' => date('Y-m-d H:i:s', time()),
393 393 'actionnamespace' => 'ktcore.user_history.disable_admin_mode',
394 394 'comments' => 'Admin Mode disabled',
395 395 'sessionid' => $_SESSION['sessionID'],
... ...