Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
systems:joomla:audina_website_v3 [2012/11/15 11:54]
smayr [Apache mod_rewrite Setup]
systems:joomla:audina_website_v3 [2013/02/27 15:25] (current)
smayr [User Registration (Component)]
Line 89: Line 89:
   * Point the browser to website URL, and test.   * Point the browser to website URL, and test.
 == Search Engine Optimization == == Search Engine Optimization ==
-  * Home page Title should have keywords+  * Home page Title should have keywords.
   * Description Metatag should have relevant site summary for Google to display it.   * Description Metatag should have relevant site summary for Google to display it.
   * Images in Home page should have descriptive ''alt'' descriptions.   * Images in Home page should have descriptive ''alt'' descriptions.
-  * Switch on Search Engine Friendly URLs +  * Switch on Search Engine Friendly URLs (Global Configuration). 
-  * Switch on Apache mod_rewrite +  * Switch on Apache mod_rewrite (Global Configuration).
 === Apache mod_rewrite Setup === === Apache mod_rewrite Setup ===
   * Install mod_rewrite support for apache.   * Install mod_rewrite support for apache.
-  * Create test script. Test ''.htaccess'' content:<code bash>+    * Enable it: <code bash>% sudo a2enmod rewrite</code> or <code bash>% cd /etc/apache2/mods-enabled 
 +% ln -s ../mods-available/rewrite.load rewrite.load</code> 
 +    * Enable AllowOverride for apache: Edit file ''/etc/apache2/sites-available/default'' (or whatever the virtual site is using) and set it to ''AllowOverride All''. Eg:<code bash><Directory /var/www/> 
 +    Options Indexes FollowSymLinks MultiViews 
 +    #AllowOverride None 
 +    AllowOverride All 
 +    Order allow,deny 
 +    allow from all 
 +    # Uncomment this directive is you want to see apache2'
 +    # default start page (in /apache2-default) when you go to / 
 +    #RedirectMatch ^/$ /apache2-default/ 
 +</Directory></code> 
 +    * Restart apache: <code bash>% /etc/init.d/apache2 restart</code> 
 +  * Create test script. Sample test ''.htaccess'' file:<code bash>
 RewriteEngine On RewriteEngine On
 Options +FollowSymLinks Options +FollowSymLinks
 RewriteRule ^joomla\.html http://www.joomla.org/? [R=301,L] RewriteRule ^joomla\.html http://www.joomla.org/? [R=301,L]
 RewriteRule ^link([^/]*).html$ rewrite.php?link=$1 [L] RewriteRule ^link([^/]*).html$ rewrite.php?link=$1 [L]
-</code>Test script ''rewrite.php'':<code php>+</code>Test script ''rewrite.php'' (open in browser, and test links being displayed):<code php>
 <html> <html>
 <body> <body>
Line 109: Line 121:
 if($_GET['link']==1) if($_GET['link']==1)
 { {
-  echo"You are not using mod_rewrite";+  echo"You are NOT using mod_rewrite";
 } }
 elseif($_GET['link']==2) elseif($_GET['link']==2)
Line 117: Line 129:
 else else
 { {
-  echo"Linux Apache mod_rewrite Test Tutorial";+  echo"Apache mod_rewrite Test Tutorial";
 } }
 ?> ?>
Line 124: Line 136:
 <p><a href="rewrite.php?link=1">LINK1</a> = rewrite.php?link=1</p> <p><a href="rewrite.php?link=1">LINK1</a> = rewrite.php?link=1</p>
 <p><a href="link2.html">LINK2</a> = link2.html</p> <p><a href="link2.html">LINK2</a> = link2.html</p>
-<p>How this works: both links are for this same page, except they both are different.</p>+<p>How this works: both links are for this same page, but each calls the page differently:</p
 +<ul> 
 +<li>Link1 is without the mod_rewrite. It shows the php file.</li>  
 +<li>Link2 is using mod_rewrite. </li> 
 +</ul>
 <p> <p>
-Link1 is without the mod_rewrite, and Link2 is using mod_rewrite. Link1 shows the php file.</p> +With mod_rewrite, we are mascarading the php file into an html file. Any extension can be used (eg: .htm.shtml etc.)Make sure it is reflected in the .htaccess file</p>
-<p> +
- With mod_rewrite we are mascarading the php file into html file. You can use whatever type of extension you want, you can change it to .htm or .shtml etc... All you have to do is to make sure you also change it in the .htaccess file</p>+
 </body> </body>
 </html> </html>
Line 219: Line 233:
      * Go to Joomla > Components > CP Event Calendar.      * Go to Joomla > Components > CP Event Calendar.
      * For calendar 'Events', click on 'Admin Data' to edit calendar and to add/delete events.      * For calendar 'Events', click on 'Admin Data' to edit calendar and to add/delete events.
 +== User Registration (Component) ==
 +  * Edit file ''<//joomla_root>///components/com_user/views/register/default.php'' to include this at the top:<code php>
 +<?php // no direct access
 +defined('_JEXEC') or die('Restricted access');
 +
 +// coastline wayne code added for forms url
 +$urlBase =  $this->baseurl;
 +
 +$mainframe->redirect($urlBase.'/index.php?option=com_chronocontact&chronoformname=Registration');
 +
 +// end wayne
 +?>
 +<script type="text/javascript">
 +. . .
 +</code>
  
 +== ChronoContact (Component) ==
 +  * Look for revised ''if'' statement on this plugin called ''$wayneFix'' that cuts off the e-mail from being sent.  See file ''<//joomla_root//>/components/com_chronocontact/plugins/cf_joomla_registration.php''.
 = Backup Files = = Backup Files =
   * A copy of the webserver files can be found in ''/data/backup/www''   * A copy of the webserver files can be found in ''/data/backup/www''