mirror of
				https://git.code.sf.net/p/seeddms/code
				synced 2025-10-31 05:11:27 +00:00 
			
		
		
		
	intialize $index even if action != show
This commit is contained in:
		
							parent
							
								
									b5fad8ddec
								
							
						
					
					
						commit
						b4bcb94b6c
					
				|  | @ -37,24 +37,27 @@ if(!$settings->_enableFullSearch) { | |||
| 	UI::exitError(getMLText("admin_tools"),getMLText("fulltextsearch_disabled")); | ||||
| } | ||||
| 
 | ||||
| if(!isset($_GET['action']) || $_GET['action'] == 'show') | ||||
| if(isset($_GET['create']) && $_GET['create'] == 1) { | ||||
| 	if(isset($_GET['confirm']) && $_GET['confirm'] == 1) { | ||||
| 		$index = $indexconf['Indexer']::create($settings->_luceneDir); | ||||
| if(!isset($_GET['action']) || $_GET['action'] == 'show') { | ||||
| 	if(isset($_GET['create']) && $_GET['create'] == 1) { | ||||
| 		if(isset($_GET['confirm']) && $_GET['confirm'] == 1) { | ||||
| 			$index = $indexconf['Indexer']::create($settings->_luceneDir); | ||||
| 			if(!$index) { | ||||
| 				UI::exitError(getMLText("admin_tools"),getMLText("no_fulltextindex")); | ||||
| 			} | ||||
| 			$indexconf['Indexer']::init($settings->_stopWordsFile); | ||||
| 		} else { | ||||
| 			header('Location: out.CreateIndex.php'); | ||||
| 			exit; | ||||
| 		} | ||||
| 	} else { | ||||
| 		$index = $indexconf['Indexer']::open($settings->_luceneDir); | ||||
| 		if(!$index) { | ||||
| 			UI::exitError(getMLText("admin_tools"),getMLText("no_fulltextindex")); | ||||
| 		} | ||||
| 		$indexconf['Indexer']::init($settings->_stopWordsFile); | ||||
| 	} else { | ||||
| 		header('Location: out.CreateIndex.php'); | ||||
| 		exit; | ||||
| 	} | ||||
| } else { | ||||
| 	$index = $indexconf['Indexer']::open($settings->_luceneDir); | ||||
| 	if(!$index) { | ||||
| 		UI::exitError(getMLText("admin_tools"),getMLText("no_fulltextindex")); | ||||
| 	} | ||||
| 	$indexconf['Indexer']::init($settings->_stopWordsFile); | ||||
| 	$index = null; | ||||
| } | ||||
| 
 | ||||
| if (!isset($_GET["folderid"]) || !is_numeric($_GET["folderid"]) || intval($_GET["folderid"])<1) { | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue
	
	Block a user
	 Uwe Steinmann
						Uwe Steinmann