| Author |
Message |
laprank
Nuke Soldier


Joined: Jul 03, 2003
Posts: 19
|
Posted:
Thu Apr 08, 2004 1:14 pm |
  |
okay i'm basicly trying to make the encyclopedia Googletap with the NukeCop Version...
now most of the path are converted but i can't get them to show the .html links on the site once i'm in the encyclopedia so in other words when your in the http://www.laprank.com/encyclopedia.html site you can see everything normaly but the path arn't converted 2 .html there still .php
this is the code i have used:
| Code: |
#Encyclopedia
RewriteRule ^encyclopedia-([0-9]*)-page([0-9]*)-([a-zA-Z0-9_-]*).html modules.php?name=Encyclopedia&op=content&tid=$1&page=$2&query=$3
RewriteRule ^encyclopedia-([0-9]*)-page([0-9]*).html modules.php?name=Encyclopedia&op=content&tid=$1&page=$2
RewriteRule ^encyclopedia-([0-9]*)-([a-zA-Z0-9_-]*).html modules.php?name=Encyclopedia&op=content&tid=$1&query=$2
RewriteRule ^encyclopedia-([0-9]*).html modules.php?name=Encyclopedia&op=content&tid=$1
RewriteRule ^encyclopedia-list-([0-9]*).html modules.php?name=Encyclopedia&op=list_content&eid=$1
RewriteRule ^encyclopedia-terms([0-9]*)-([A-Z]*).html modules.php?name=Encyclopedia&op=terms&eid=$1<r=$2
RewriteRule ^encyclopedia-search-([a-zA-Z0-9_-]*).html modules.php?name=Encyclopedia&file=search&query=$1
RewriteRule ^encyclopedia-search.html modules.php?name=Encyclopedia&file=search
RewriteRule ^encyclopedia.html modules.php?name=Encyclopedia
|
|
_________________ http://www.dollarbuddy.com/index.php?id=jdh06@hotmail.com
http://www.allgoodgames.com
http://www.laprank.com |
|
    |
 |
laprank
Nuke Soldier


Joined: Jul 03, 2003
Posts: 19
|
Posted:
Sat Apr 10, 2004 12:10 am |
  |
|
    |
 |
Evaders99
Site Admin


Joined: Aug 17, 2003
Posts: 12397
|
Posted:
Sat Apr 10, 2004 10:31 pm |
  |
|
     |
 |
laprank
Nuke Soldier


Joined: Jul 03, 2003
Posts: 19
|
Posted:
Tue Apr 13, 2004 9:11 pm |
  |
|
    |
 |
Evaders99
Site Admin


Joined: Aug 17, 2003
Posts: 12397
|
Posted:
Tue Apr 13, 2004 9:56 pm |
  |
Find the line that ends:
| Code: |
"'(?<!/)modules.php\?name=Web_Links'"
);
|
(assuming the base is standard GT from NukeCops)
You want to add your code so you get
| Code: |
"'(?<!/)modules.php\?name=Web_Links'",
"'(?<!/)modules.php\?name=Encyclopedia&op=content&tid=([0-9]*)&page=([0-9]*)"
);
|
and so forth. Every line you add must have a comma at the end, except for the last one.
Second, find the code that ends
(again assuming standard NukeCop GT base)
Edit the following links like:
| Code: |
"links.html",
"encyclopedia-\\1-\\2.html"
);
|
(again, the comma after every line but the last)
It is a good idea to check out the code in header.php, so you can get a good example of how to convert these. |
|
|
     |
 |
laprank
Nuke Soldier


Joined: Jul 03, 2003
Posts: 19
|
Posted:
Thu Apr 15, 2004 7:00 pm |
  |
| Code: |
"'(?<!/)modules.php\?name=Web_Links'",
"'(?<!/)modules.php\?name=Encyclopedia&op=content&tid=([0-9]*)&page=([0-9]*)"
);
|
and so forth. Every line you add must have a comma at the end, except for the last one.
Second, find the code that ends
(again assuming standard NukeCop GT base)
Edit the following links like:
| Code: |
"links.html",
"encyclopedia-\\1-\\2.html"
);
|
yea i did what you told me but i couldn't figure out how 2 add the rest... i'm not really a scripter. but i did ad the code you gave in and i didn't see any difference.. :S |
_________________ http://www.dollarbuddy.com/index.php?id=jdh06@hotmail.com
http://www.allgoodgames.com
http://www.laprank.com |
|
    |
 |
foxyfemfem
Support Staff


Joined: Jan 23, 2003
Posts: 668
Location: USA
|
Posted:
Thu Apr 15, 2004 7:21 pm |
  |
Hello,
You need to give each mod_rewrite code a html format.
Here is an example.
For the .htaccess file:
RewriteRule ^encyclopedia-([0-9]*)-page([0-9]*)-([a-zA-Z0-9_-]*).html modules.php?name=Encyclopedia&op=content&tid=$1&page=$2&query=$3
Therefore, something like this...
$urlin = array(
"'(?<!/)modules.php\?name=Encyclopedia&op=content&tid=([0-9]*)&page=([0-9]*)&query=([a-zA-Z0-9_-]*)'",
$urlout = array(
"encyclopedia-\\1-page\\2-\\3.html",
.....should go inside your header.php file |
_________________ If you shoot for the moon and miss, you'll still be amongst the stars. |
|
   |
 |
Evaders99
Site Admin


Joined: Aug 17, 2003
Posts: 12397
|
Posted:
Thu Apr 15, 2004 9:54 pm |
  |
You wrote the .htaccess file right? Follow that pattern:
([0-9]*) represents an entry that is a number
([a-zA-Z0-9_-]*) represents an entry that can be characters, numbers, and underscore
These are used in the first part of header.php
You want that to sync with the second part of header.php. Thus you if you add a row in the first part, you must add a row in the same position in the seoncd part.
Each entry is numbered, so you replace them inside the .html string that you want.
\\1 first entry
\\2 second entry
and so forth |
|
|
     |
 |
laprank
Nuke Soldier


Joined: Jul 03, 2003
Posts: 19
|
Posted:
Thu Apr 22, 2004 11:12 pm |
  |
|
    |
 |
Imago
Captain


Joined: Jan 17, 2003
Posts: 629
Location: Europe
|
Posted:
Sun May 16, 2004 10:43 pm |
  |
|
    |
 |
laprank
Nuke Soldier


Joined: Jul 03, 2003
Posts: 19
|
Posted:
Thu May 20, 2004 4:34 pm |
  |
|
    |
 |
Imago
Captain


Joined: Jan 17, 2003
Posts: 629
Location: Europe
|
Posted:
Thu Nov 04, 2004 2:58 am |
  |
|
    |
 |
mikeshields
Sergeant


Joined: Feb 21, 2004
Posts: 101
|
Posted:
Sun Nov 14, 2004 5:51 am |
  |
|
    |
 |
Imago
Captain


Joined: Jan 17, 2003
Posts: 629
Location: Europe
|
Posted:
Sun Nov 14, 2004 8:40 am |
  |
|
    |
 |
mikeshields
Sergeant


Joined: Feb 21, 2004
Posts: 101
|
Posted:
Sun Nov 14, 2004 8:49 am |
  |
|
    |
 |
|
|