Installing Joomla on 5.0-Nano: Difference between revisions

m
no edit summary
mNo edit summary
Line 1: Line 1:
<span id="top"></span>
<span id="top"></span>
{| cellpadding="2"
{| cellpadding="2"
|__TOC__||'''Installing Joomla on 5.0-Nano'''
|__TOC__||'''Installing Joomla on 5-Nano Series'''
|}
|}
'''Introduction'''
'''Introduction'''


This step-by-step guide shows how to install Joomla on Uniform Server V5.0-Nano Uniform Server is inherently portable however Joomla uses absolute paths preventing true portability this is easily resolved after installation see [[#Portability | '''portability section''']].
This step-by-step guide shows how to install Joomla on Uniform Server V5-Nano Uniform Server is inherently portable however Joomla uses absolute paths preventing true portability this is easily resolved after installation see [[#Portability | '''portability section''']].


Copy the above to a USB memory stick and run on another PC. If a host PC is currently running another server it will prevent UniServer from running. To resolve this situation either stop, the host servers or preferably install your UniServer on different ports by moving the server. Before installing Joomla its worth reading how to [[#Move Servers |'''move servers''']].   
Copy the above to a USB memory stick and run on another PC. If a host PC is currently running another server it will prevent UniServer from running. To resolve this situation either stop, the host servers or preferably install your UniServer on different ports by moving the server. Before installing Joomla its worth reading how to [[#Move Servers |'''move servers''']].   
Line 17: Line 17:


# '''A)''' Create a new folder named '''joomla_b''' (Can be any name)
# '''A)''' Create a new folder named '''joomla_b''' (Can be any name)
# Extract a new copy of Uniform Server V5-Nano to this folder
# Extract a new copy of Uniform Server V5.5-Nano to this folder
# '''Start''' Uniform Server.  
# '''Start''' Uniform Server.  


Line 223: Line 223:


Joomla’s configuration file is a list of variables contained in a '''class''' named '''Jconfig''' to set these variables dynamically we use the class constructor as follows:
Joomla’s configuration file is a list of variables contained in a '''class''' named '''Jconfig''' to set these variables dynamically we use the class constructor as follows:
{|
|-
|
<pre>
<pre>
//=== Constructor JConfig for Joomla class ===================================
//=== Constructor JConfig for Joomla class ===================================
  function JConfig() {
  function JConfig() {
  $splitArray    = explode("\\www",__DIR__);     // Split at folder www to
 
  $base          = "$splitArray[0]";             // give absolute path to
// === Set base path ======================================================
   $this->log_path = $base."\\www\\joomla\\logs";  // www. Create new paths to
$path_array = explode("www", dirname( __FILE__ )); // Split pat at www
   $this->tmp_path = $base."\\www\\joomla\\tmp";    // folders logs and temp  
$base          = "$path_array[0]";       // absolute path to ..UniServer/
  }                                                 // and set class variables.
// ================================================== End Set base path ===
 
  // Set class variables.
   $this->log_path = $base."www\\joomla\\logs";  // Create new paths to
   $this->tmp_path = $base."www\\joomla\\tmp";    // folders logs and temp  
  }                                              
  //=============================== END Constructor JConfig for Joomla class ===
  //=============================== END Constructor JConfig for Joomla class ===
</pre>
</pre>
|}
Add this to the end of the class (just above the last curly brace) hence when the class is instantiated new paths are calculated and appropriate variables updated.
Add this to the end of the class (just above the last curly brace) hence when the class is instantiated new paths are calculated and appropriate variables updated.


Line 276: Line 285:


Use the port number that matches your server start the servers. Pages are accessible as mentioned above just remember to use the port number that matches your server.
Use the port number that matches your server start the servers. Pages are accessible as mentioned above just remember to use the port number that matches your server.
   
 
'''''Note 2'':'''
 
The plugin V55_Joomla_1_5_15a.exe automatically tracks the MySQL port hence no need to manually configure this when moving the servers. Plugin uses the following constructor:
{|
|-
|
<pre>
//=== Constructor JConfig for Joomla class ===================================
  function JConfig() {
 
// === Set base path ==========================================================
$path_array = explode("www", dirname( __FILE__ ));  // Split pat at www
$base          = "$path_array[0]";            // absolute path to ..UniServer/
// ====================================================== End Set base path ===
 
// === Get MYSQL port =========================================================
// Use port from configuration file - because user can change this file
$file_conf  = $base.'usr\\local\\mysql\\my.ini'; // Config file
 
if ($filearray=file($file_conf)) {              // read file into array
foreach ($filearray as $txt) {                // scan array for port
  if(preg_match("/^\s*port\s*=\s*(\d+)/", $txt,$match)){ // check save matches
  $mysql_port =  $match[1];                    // match found save port number
  break;                                      // give up nothing else to do
  }
}
}
else {                                      // failed to read file
echo "Cannot read the file";
}
// ===================================================== END Get MySQL Port ===
  // // Set class variables.
  $this->host = "localhost:$mysql_port";        // Add port to localhost
  $this->log_path = $base."www\\joomla\\logs";  // Create new paths to
  $this->tmp_path = $base."www\\joomla\\tmp";    // folders logs and temp
}                                               
//=============================== END Constructor JConfig for Joomla class ===
</pre>
|}
'''''[[#top | Top]]'''''
'''''[[#top | Top]]'''''


Line 285: Line 333:
* Under '''Plugins'''
* Under '''Plugins'''
* Navigate to sub-folder '''Uniform Server 5-Nano Plugins'''
* Navigate to sub-folder '''Uniform Server 5-Nano Plugins'''
* Download file [http://sourceforge.net/projects/miniserver/files/Plugins/UniServer%2055-Nano%20Plugins/Applications/V55_Joomla/V55_Joomla_1_5_15.exe/download V55_Joomla_1_5_15.exe]
* Download file [http://sourceforge.net/projects/miniserver/files/Plugins/UniServer%2055-Nano%20Plugins/Applications/V55_Joomla/V55_Joomla_1_5_15a.exe/download V55_Joomla_1_5_15a.exe]


Save this to folder UniServer, to install double click on file. Joomla is pre-configured and ready to go. Check out the read me file for latest information.
Save this to folder UniServer, to install double click on file. Joomla is pre-configured and ready to go. Check out the read me file for latest information.