News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

Pretty URLs

Started by SMFHacks.com Team, January 31, 2007, 10:56:43 AM

Previous topic - Next topic

Frozt

the problem is that

www.mydomain.com/stats/ is using by my hosting for show the stats of the hosting, so when I click in [More Stats] in the Info Center not show the stast of the forum

Frozt

yes, if I use:

/index.php?action=stats

I can access my forum stats

Dannii

Add this rule before the others in .htaccess:
RewriteRule ^stats/?$ ./stats/index.php [L,QSA]
Replace index.php with index.html or whatever..
"Never imagine yourself not to be otherwise than what it might appear to others that what you were or might have been was not otherwise than what you had been would have appeared to them to be otherwise."

Frozt

I put that line after the:

#   Rules for: actions

in .htaccess but happen the same

Frozt

is possible change it to display other word?
instead /stast/ to show /more_stast/ or other

all url that start with stats/ show the stasts o hosting




Dannii

#2625
Oh wait, I misread your problem.

Try this:
RewriteRule ^forum-stats/?$ ./index.php?action=stats [L,QSA]

You can change forum-stats to whatever you want.
"Never imagine yourself not to be otherwise than what it might appear to others that what you were or might have been was not otherwise than what you had been would have appeared to them to be otherwise."

Frozt

with that code I can see the forum stats if I go to:

www. mydomain .com/forum-stats/

but the problem is that in the Info Center the [More Stats] link continue using the same link /stats/

Frozt

#2627
I edit the link in the smf_pretty_urls_cache table, for show

.../forum-stats/

instead

.../stats/

and work  :)


thanks for all the help

Assistance

trying to toss out some ssi_boardNews
can't seem to get pretty urls to work, they work fine in ssi_examples
works fine in a frame(test)
but include shows non pretty urls

Version: 2.0 Beta 3 Public
Pretty URLs - Base      0.8.4
~playing poker~

Dannii

Try including this line in your code:

ob_start('ob_sessrewrite');

And are you just using the normal ssi_boardNews output, or are you customising it?
"Never imagine yourself not to be otherwise than what it might appear to others that what you were or might have been was not otherwise than what you had been would have appeared to them to be otherwise."

Assistance

<?php
ob_start
('ob_sessrewrite');
ssi_boardNews($board = 1.0, $limit = 2, $start = null, $length = 250, $output_method = 'echo');
?>


perfect, thank you
~playing poker~

genieuk

QuoteI dont' get what you mean exactly but my theme use normal SMF URLs, if that makes sence and what your asking.
Your templates are producing URLs like this: index.php?action=help;page=profile
They need to be full URLs like: http://www.foreverlastingfriends.com/index.php?action=help;page=profile

So does this mean i cannot use the mod with my custom theme? really want to use this mod. To my knowledge and looking at my URLS they are full URLS like you have shown.

Mathew

Dannii

Most of the URLs are full ones, except the ones in the menu.

<div class="sub">
<ul>
<li><a href="index.php?action=help;page=registering">Register</a></li>
  <li><a href="index.php?action=help;page=loginout">Logging In</a></li>
  <li><a href="index.php?action=help;page=profile">Your Profile</a></li>

<li><a href="index.php?action=help;page=post">How to Post</a></li>
<li><a href="index.php?action=help;page=pm">Personal Message</a></li>
<li><a href="index.php?action=help;page=searching">The Search Function</a></li>
</ul>
<div class="btm-bg"></div>
</div>
"Never imagine yourself not to be otherwise than what it might appear to others that what you were or might have been was not otherwise than what you had been would have appeared to them to be otherwise."

genieuk

ok thanks, anything i can do to make them full urls ???

sorry if i sound thick but prefer to ask as i dont want to jump ahead and cause myself problems, prefer to get the appropriate help from people who knows what they talking about.

Thanks
Mathew

Dannii

Just change the PHP code to use $scripturl. Or even add the full domain in without using the variable. It's really very simple...
"Never imagine yourself not to be otherwise than what it might appear to others that what you were or might have been was not otherwise than what you had been would have appeared to them to be otherwise."

genieuk

I sound thick i know, but what file do i edit to change that and what do i actually need to do put? i mean what code.

Thanks
Mathew

Dannii

Probably index.template.php
"Never imagine yourself not to be otherwise than what it might appear to others that what you were or might have been was not otherwise than what you had been would have appeared to them to be otherwise."

brianjw

If you want to display the $scripturl string in HTML, use it like this:
', $scripturl, '
', $scripturl, '

- Brian

dangerboy

help got an loop error redirection. cant open threads.

MacX

#2639
Difficult to search in 133 pages...

I have installed the mod for version 1.1.6.
My problem? i use a non default theme and i cant see the botton to access to the settings in my admin panel.

Finaly i have changed my forum language to english insted of spanish and i could do it.
I think it would be nice to say it in some place....

And well, my question.
In spanish we use this to accentuate characteres: ( á é í ó ú ).
where must i put some code to:
- first, delete the accents (á é í ó ú = a e i o u)
-and then to pass the title string to the code.

Thank you.
Thank you.

PD: great job dani ;)

Advertisement: