Skip to content

Commit

Permalink
Split Class-Package into its two classes.
Browse files Browse the repository at this point in the history
Signed-off-by: Norv <a.w.norv@gmail.com>
  • Loading branch information
norv committed Jan 19, 2013
1 parent c1eae05 commit 0ebe024
Show file tree
Hide file tree
Showing 6 changed files with 490 additions and 467 deletions.
2 changes: 1 addition & 1 deletion Sources/admin/Admin.php
Original file line number Diff line number Diff line change
Expand Up @@ -937,7 +937,7 @@ function AdminSearchOM()

// Otherwise we simply walk through the XML and stick it in context for display.
$context['search_results'] = array();
require_once($sourcedir . '/Package.class.php');
require_once($sourcedir . '/subs/XmlArray.class.php');

// Get the results loaded into an array for processing!
$results = new xmlArray($search_results, false);
Expand Down
2 changes: 1 addition & 1 deletion Sources/admin/ManageLanguages.php
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ function list_getLanguagesList()
$url = 'http://download.elkarte.net/fetch_language.php?version=' . urlencode(strtr($forum_version, array('ELKARTE ' => '')));

// Load the class file and stick it into an array.
require_once($sourcedir . '/Package.class.php');
require_once($sourcedir . '/subs/XmlArray.class.php');
$language_list = new xmlArray(fetch_web_data($url), true);

// Check that the site responded and that the language exists.
Expand Down
6 changes: 3 additions & 3 deletions Sources/admin/PackageServers.php
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ function action_servers()
{
if (isset($_POST['ftp_username']))
{
require_once($sourcedir . '/Package.class.php');
require_once($sourcedir . '/subs/FTPConnection.class.php');
$ftp = new ftp_connection($_POST['ftp_server'], $_POST['ftp_port'], $_POST['ftp_username'], $_POST['ftp_password']);

if ($ftp->error === false)
Expand All @@ -145,7 +145,7 @@ function action_servers()
{
if (!isset($ftp))
{
require_once($sourcedir . '/Package.class.php');
require_once($sourcedir . '/subs/FTPConnection.class.php');
$ftp = new ftp_connection(null);
}
elseif ($ftp->error !== false && !isset($ftp_error))
Expand Down Expand Up @@ -256,7 +256,7 @@ function action_browseserver()
@set_time_limit(600);

// Read packages.xml and parse into xmlArray. (the true tells it to trim things ;).)
require_once($sourcedir . '/Package.class.php');
require_once($sourcedir . '/subs/XmlArray.class.php');
$listing = new xmlArray(fetch_web_data($_GET['package']), true);

// Errm.... empty file? Try the URL....
Expand Down
Loading

0 comments on commit 0ebe024

Please sign in to comment.