| Zadając pytanie dotyczące PHPNuke podaj jego wersje!! |
| View Single Post #19826 |
Topic: |
| Author |
Message |
Lio85 ~user

|
Posted: 23 Jan 2007 01:01:53 Post subject: |
|
|
ok dzięki
Dodane po: 53 minutach:
faktycznie... ściągnołem to co podałeś w załączniku i nie działa zbyt rewelacyjnie... czy mógłbyś podać taki kodzik w skrócie i mniej więcej objaśnić o co w nim chodzi (chodzi o kodzik względem nuka) żebym mógł mniej więcej zaczaić o co w tym chodzi bo czytałem tego na ten temat dość dużo i troszke się jeszcze motam.
A i jeszcze coś:
w tym co podałeś jest coś takiego:
| Code: |
2. Open header.php
-> Find
if (stristr($_SERVER['SCRIPT_NAME'], "header.php")) {
Header("Location: index.php");
die();
}
-> Add After
//php2html MemHT.com Mod Rewrite - START
ob_start();
function replace_for_mod_rewrite(&$s) {
$urlin = array(
"'(?<!/)modules.php\?name=News&file=article&sid=([0-9]*) &mode=([a-z]*)&order=([0-9]*)&thold=([0-9]*)'",
"'(?<!/)modules.php\?name=News&file=article&sid=([0-9]*)'",
"'(?<!/)modules.php\?name=News&file=article&sid=([0-9]*)'",
"'(?<!/)modules.php\?name=News&new_topic=([0-9]*)'",
"'(?<!/)modules.php\?name=Forums&file= viewforum&f=([0-9]+)&topicdays =([0-9]+)&start=([0-9]+)'",
"'(?<!/)modules.php\?name=Forums&file=viewforum&f=([0-9]*)& (mark|start)=([a-zA-Z0-9_]*)'",
"'(?<!/)modules.php\?name=Forums&file=viewforum&f=([0-9]*)'",
"'(?<!/)modules.php\?name=Forums&file=viewtopic&t=([0-9]+)&start= ([0-9]+)&postdays=([0-9]+)&postorder=asc&highlight='",
"'(?<!/)modules.php\?name=Forums&fil e=viewtopic&t=([0-9]+)&postdays=([0-9]+)& amp;postorder=asc&start=([0-9]+)'",
"'(?<!/)modules.php\?name=Forums&fil e=viewtopic&t=([0-9]*)&(start|view|highlight)=([/:\-\'(){}.&=_a-zA-Z0-9 ]*)'",
"'(?<!/)modules.php\?name=Forums&file =viewtopic&t=([0-9]*)&([a-zA-Z0-9]*)=topic&start=0'",
"'(?<!/)modules.php\?name=Forums&file=viewtopic&(p|t)=([0-9]*)'",
"'(?<!/)modules.php\?name=Forums&file =profile&mode=register&agreed=true&coppa=([a-zA-Z0-9_]*)'",
"'(?<!/)modules.php\?name=Forums&file =profile&mode=register&agreed=([a-zA-Z0-9_]*)'",
"'(?<!/)modules.php\?name=Forums&file =modcp&mode=([a-zA-Z0-9_]*)&p= ([0-9_&]*)&t=([a-zA-Z0-9_&=\.\;]*)'",
"'(?<!/)modules.php\?name=Forums&file =modcp&t=([0-9]*)&mode=([a-zA-Z0-9]*)'",
"'(?<!/)modules.php\?name=Forums&file =([a-zA-Z0-9_]*)&mode=([a-zA-Z0-9_]*)&t=([0-9]*)&popup=([0-9]*)'",
"'(?<!/)modules.php\?name=Forums&file =([a-zA-Z0-9_]*)&mode=([a-zA-Z0-9_]*)&(p|t|f|u|popup)=([0-9]*)'",
"'(?<!/)modules.php\?name=Forums&file= ([a-zA-Z0-9_]*)&mode=([a-zA-Z0-9_]*)&(p|t|f|u|popup)=([0-9]*)'",
"'(?<!/)modules.php\?name=Forums&file= ([a-zA-Z0-9_]*)&mode=([a-zA-Z0-9_]*)&(p|t|f|u|popup)=([0-9]*)'",
"'(?<!/)modules.php\?name=Forums&file=( [a-zA-Z0-9_]*)&mode=([a-zA-Z0-9_]*)'",
"'(?<!/)modules.php\?name=Forums&file= search&([a-zA-Z0-9_]*)=([a-zA-Z0-9_]*)&([a-z A-Z0-9_]*)=([a-zA-Z0-9_]*)'",
"'(?<!/)modules.php\?name=Forums&file= ([a-zA-Z0-9_]*)&([a-zA-Z0-9_]*)=([a-zA-Z0-9_]*)'",
"'(?<!/)modules.php\?name=Forums &file=([a-zA-Z0-9_]*)'",
"'(?<!/)modules.php\?name=Forums'",
"'(?<!/)modules.php\?name=Your_Account&op=useri nfo&username=([a-zA-Z0-9_-]*)'",
"'(?<!/)modules.php\?name=Your_Account& op=userinfo&username=([a-zA-Z0-9_-]*)'",
"'(?<!/)modules.php\?name=Downloads&cid =([0-9]*)&orderby=(titleA|titleD)'",
"'(?<!/)modules.php\?name=Downloads&am p;cid=([0-9]*)'",
"'(?<!/)modules.php\?name=Downloads&o p=getit&lid=([0-9]*)'",
"'(?<!/)modules.php\?name=Downloads&o p=modifydownloadrequest&lid=([0-9]*)'",
"'(?<!/)modules.php\?name=Downloads&op =NewDownloads&newdownloadshowdays=(7|14|30)'",
"'(?<!/)modules.php\?name=Downloads&o p=NewDownloadsDate&selectdate=([0-9]*)'",
"'(?<!/)modules.php\?name=Downloads&o p=MostPopular&ratenum=(1|5|10|25|50)&ratetype=(num|percent)'",
"'(?<!/)modules.php\?name=Downloads&op=NewDownloads'",
"'(?<!/)modules.php\?name=Downloads&op=MostPopular'",
"'(?<!/)modules.php\?name=Downloads'",
"'(?<!/)modules.php\?name=Topics'",
"'(?<!/)modules.php\?name=Downloads&op=gfx& random_num=([0-9]*)'",
);
$urlout = array(
"article-\\1-\\2-\\3-\\4.html",
"article\\1.html",
"article\\1.html",
"article-topic-\\1.html",
"forumx\\1-\\2-\\3.html",
"forum\\1-\\2\\3.html",
"forum\\1.html",
"postx\\1-\\2-\\3.html",
"postxf\\1-\\2-\\3.html",
"posts\\1-\\2\\3.html",
"topic\\1-\\2.html",
"post\\1\\2.html",
"register-coppa-\\1.html",
"register-\\1.html",
"poster\\1-\\2_\\3.html",
"modcp\\1-\\2.html",
"forums-\\1-\\2-\\3-\\4.html",
"forums-\\1-\\2-\\3-\\4.html",
"forums-\\1-\\2-\\3-\\4.html",
"forums-\\1-\\2-\\3-\\4.html",
"forums-\\1-\\2.html",
"forum\\1-\\2-\\3-\\4.html",
"forums\\1-\\2-\\3.html",
"forum-\\1.html",
"forums.html",
"userinfo-\\1.html",
"userinfo-\\1.html",
"downloads-order-\\1-\\2.html",
"downloads-cat-\\1.html",
"downloads-getit-\\1.html",
"downloads-modify-\\1.html",
"downloads-new-days-\\1.html",
"downloads-new-date-\\1.html",
"downloads-pop-\\1-\\2.html",
"downloads-new.html",
"downloads-pop.html",
"downloads.html",
"topics.html",
"downloads-gfx-\\1.html",
);
$s = preg_replace($urlin, $urlout, $s);
return $s;
}
//php2html MemHT.com Mod Rewrite - END
3. Open footer.php
-> Find
foot();
-> Add Before
//php2html MemHT.com Mod Rewrite - START
$contents = ob_get_contents();
ob_end_clean();
echo replace_for_mod_rewrite($contents);
//php2html MemHT.com Mod Rewrite - END
|
tego też nie rozumiem za bardzo ( znaczy się, jak dodać to wiem i już to zrobiłem, tylko funkcjonowanie tego nie rozumiem. Dla ciebie to pewnie drobnostka tak że bardzo bym prosił żebyś taki mały kodzik zrobił względem nuka żeby można było obczaić do czego jest (to co podałem wyżej) i do czego jest (plik .htaccess)
Pozdrawiam i wielkie dzięki za pomoc;-)
Dodane po: 2 minutach:
tam gdzieniegdzie dąłem spacje bo rozszerzyło forum.
Dodane po: 54 minutach:
no za pierona nie moge tego zrozumieć. Gdy zmieniam coś w pliku htaccess to nic się nie dzieje ale jak zmieniam w header to wtedy się dzieje.
Nie wiem o co w tym wszystkim chodzi tak że żeby sobie nie namieszać bardziej, poczekam aż ktoś mądrzejszy odemnie (lub lepiej obeznany) napisze mi co i jak się z czym je. |
|
|
|
| |
|
|
|
|
|