Getting rid of ugly URLs in MediaWiki

Hey guys,
I've been at it all weekend but no joy. I recently 'upgraded' from Snow Leopard Server to Mountain Lion and I'm in the process of rebuilding everything that is dependent on MySQL.
I've hit a roadblock with setting up MediaWiki and 'pretty URLs'. The installation has worked fine but it now sits at wiki.domain.com/index.php/Main_Page instead of the 'pretty URL' setup of wiki.domain.com/wiki/main_page
Has anyone had any success in configuring Apache on OS X Mountain Lion Server to allow for the use of 'pretty URLs'?
Any help in this matter would be most appreciated.

Hi everyone,
I finally figured it out so I thought I would share it here.
The Website Root was set as /Volumes/Data/MediaWiki/
MediaWiki was installed at /Volumes/Data/MediaWiki/w/
(Change according to your setup)
After creating a fresh MySQL database I then ran though the MediaWiki installation wizard which could be reached at http://wiki.domain.com/w/
At this point the URL looks ridiculous not don't worry! Just run through the installation and put the localsettings.php file that is generated into the /w/ folder.
Then what you wanna do is open up your favourite text editor which is capable of being authenticated as admin (this is important as we are working with a .htaccess file). I use SubEthaEdit with "hidden files" turn on in terminal. Google Search for "show hidden files in finder" to do this and then run the command in Terminal. Finder will restart then hidden files will be visible.
Put this code into a new document:
## http://www.mediawiki.org/wiki/Manual:Short_URL/Apache
# Enable the rewrite engine
RewriteEngine On
# Short url for wiki pages
RewriteRule ^/?wiki(/.*)?$ %{DOCUMENT_ROOT}/w/index.php [L]
# Redirect / to Main Page
RewriteRule ^/*$ %{DOCUMENT_ROOT}/w/index.php [L]
Save it as a .htaccess in /Volumes/Data/MediaWiki/
Important to note that you are NOT saving it in the MediaWiki installation which I have in:
/Volumes/Data/MediaWiki/w/
Once you have done this, go into the /w/ folder where MediaWiki actually is and open up the localsettings.php document.
Find this:
## The URL base path to the directory containing the wiki;
## defaults for all runtime URL paths are based off of this.
## For more information on customizing the URLs
## (like /w/index.php/Page_title to /wiki/Page_title) please see:
## http://www.mediawiki.org/wiki/Manual:Short_URL
And change the settings directly below it to reflect this:
$wgScriptPath = "/w";
$wgArticlePath= "/wiki/$1";
$wgScriptExtension = ".php";
And Voila! You have done it!!!!
If you need any help, find me on Twitter @FlyingSquidwolf.

Similar Messages

  • Getting rid of ugly background behind rounded input button

    I have saved a rounded input button as png8 with alpha transparency. However, as there are different background colors, choosing a matte becomes problematic. It looks decent in IE7, but has an ugly dark squared background in Safari. The easy solution would be to square the button, but it is a design feature, so..... Any ideas? I tried adding a "transparent" to the background in addition to the image, but all that did was get rid of the background image as well...
    http://www.miobambinoshop.com/myaccount.php

    I see the hard corners in FF (Win), too. It is not as dark as in Safari, though.
    That button graphic is small enough to save as a 32bit png. In fact, when I did an export from FireWorks, the 32bit png is 910 bytes - just over half the size of your 8bit file.
    [Edit: Deleted graphic. Not my file to post]
    Mark A. Boyd
    Keep-On-Learnin' :-)

  • Get rid of predictive urls while hovering mouse over link in firefox 6

    I hate movement on my desktop as it is distracting. If something moves, it should need my attention. While hovering my cursor over URLs, I now see the URL in the lower left, and I can't stop that from showing.
    I don't need to proofread URLs, so there is NO reason to have that on my computer, it's highly distracting.
    How do I stop it? I've played with about:config for a while, but it seems there is no clear option to toggle off.
    I realize the status bar is gone, great, but again, there is no reason for me to proofread my URLs that I'm hovering over, so please, tell how to stop this distraction, thank you.

    hello evilelf, you have various malicious addons present. please try to [[Reset Firefox – easily fix most problems|reset firefox]] (this will keep your bookmarks and passwords).
    [[Troubleshoot Firefox issues caused by malware]]

  • Any way to get rid of the awful white background in grid view?

    The old dark background was infinitely easier on the eyes, and more attractive. When I look at stuff in grid view now it gives me a headache. Any chance of changing this back via terminal or something?

    I would also like to know how to get rid of ugly *** white background. It ****** me off every time I have to look at it. There is nothing that I see here as being an improvement over the last itunes.

  • Any way to get rid of the unread count in the lock screen?

    Hi,
    I am new to the Z10 and i was wondering if i could remove the unread count or even the new mail icon from the lock screen. 
    On the old 9780, i was able to change the notification in a manner that only signaled a new email arrive but without the number. 
    This is my work email and when i am out of the office i don't want to be greeted with the number of emails that accumulated in my inbox while i dared to stop working..
    I wouldn't mind removing the new mail icon completly if that the only valid option.. 
    Thanks!

    I would also like to know how to get rid of ugly *** white background. It ****** me off every time I have to look at it. There is nothing that I see here as being an improvement over the last itunes.

  • In ical edit, can you get rid of invitees, availability, url, notes?

    in ical edit, can you get rid of invitees, availability, url, notes?

    in ical edit, can you get rid of invitees, availability, url, notes?

  • My default search engine is Google and I deleted Bing. Whenever I open a new tab, Bing is displayed and it takes the focus so if I am trying to type a URL in the new tab, it is entered in the damn bing search box. HOW DO I GET RID OF THAT ACCURSED BING?

    My default search engine is Google and I deleted Bing from the Search Providers. Facebook is set as my home page. Whenever I open a new tab, a Bing search box is displayed on the page and it takes the focus so when I am trying to type a URL in the new tab, it is entered in the damn bing search box. HOW DO I GET RID OF THAT ACCURSED BING

    Swarnava, thank you very much! that did it and I am Bing-less . . . OH HAPPY DAY!! WOOHOO!!!! thank you, thank you, thank you!

  • I am stuck with a google theme behind the bookmark tab bar and url box. How do I get rid of it? changing themes isn't the issue - it's just all stuck in back!

    I set a theme on igoogle - but it seems to now be embedded in my firefox as it is behind the url box, behind the bookmark tab bar and at the bottom of the page. How do I get rid of it. I can still change themes but they stay on the google page as they should. this has nothing to do with my screen saver and my desktop screens - they are different and ok - seems to be stuck in Firefox particularly.
    == This happened ==
    Every time Firefox opened
    == a month ago when I changed themes on google

    @<b>gobby</b>
    Please do not use existing threads to ask a question, but [/questions/new start a new thread] instead.
    Then you also can provide troubleshooting information like your operating system and installed plugins (about:plugins), and extensions (Tools > Add-ons) and we will be better able to help you.<br />
    See [[Deleting bookmarks]]

  • Personal Domain - Can I get rid of my iWeb site's name in the URL?

    Hey everyone,
    I just set up my iWeb site (called "This is Out of Context") to point to a personal domain name (www.thisisoutofcontext.com). Problem is, now my homepage URL reads: http://www.thisisoutofcontext.com/THISIS_OUT_OFCONTEXT/HOME.html
    Is there any way to "get rid" of the second "THISIS_OUT_OFCONTEXT" so that my URL simply reads: http://www.thisisoutofcontext.com/HOME.html ? You know...short 'n sweet...like a "normal" website?
    Any thoughts or tips would be much appreciated (please go easy on me, I'm a total newbie here...)
    Cheers!

    does this work with iweb 08?
    my site was running fine until i upgraded to iweb 08 and redsigned my site. i have a godaddy account for my domain name and i have it masked and forwarded but my apple url still appears at the top of the browser bar while in safari and firefox. my site is www.louislemoine.com
    if you go there you will see what i mean. maybe what you are talking about will solve this problem. i am at work so i can not check to see if what you talk about will work. i am hoping that you are onto something.

  • How to get rid of #widget extension in URL

    Hi there,
    Couldn't find an answer to this anywhere on the web - hope you can help me out.
    I created a webpage with in-page navigation options. So you click a link on the page and are redirected to another section of that same page, like for instance a 'back to top' option. I used simple HTML snippets to achieve this and it works fine.
    However, and here's my question, when clicking for instance a back to top button the URL actually displays the widget's details. It'll say for instance blablabla.com/home.html#widget8 in the URL bar.
    Is there a way of getting rid of this #widget extension displaying as a URL ?
    I know there's domain masking, but I don't want to mask my entire site, I just want to get rid of the #widget stuff.
    All suggestions are appreciated, thanks.

    I don't think you should worry about what's in the URL because the appearance and content of your site will certainly bring them back. The different anchors can be bookmarked so the individual URLs don't need to be memorized, only your domain name.
    However, using non Web Safe Fonts in your text boxes has converted them to images that that will prevent search engines from indexing your site/page. You could create small image files of the country titles and insert them into the text box. That way they would stay in register with the wine lists but not cause the text box to convert to an image.
    OT

  • Get rid of intrusive HUGE and UGLY dark bands behind HUGE icons on Home Screen

    How do I get rid of the intrusive, huge and ugly dark bands behind the huge icons, and reduce the size of the icons on the Home Screen?
    On my 8320 I can use pictures of my kids for wallpaper. On the 8900 they have wasted half of the beautiful screen with these huge ugly icons and dark bands - cuts right through two of my kids eyes and two of my kids mouths and below.
    What were they thinking? They advertise the 8900 (and the 8520) by emphasizing a full screen picture - but when you actulally buy the phones, they have inserted these cursed screenscape hogs. Any firmware fixes yet? Or, now that Nokia has released their E71 that not only handles email as well as my BB, but also allows me to create and edit docx, should I abandon the 8900 as a lost cause and buy the E71? And, as long as we are discussing RIM's myopic short sightedness, why no 3G on this device?
    Please hurry, my buyers remorse clock is ticking and I need to send this thing back to the carrier if it can't be fixed.
    Thanks in advance.

    Hello, to change the size (I have six icons per row not five) go to options>advanced options>accessability and change the amount on the grid. Default 6x6, then 4x4 3x3 etc., you can also change the colours. Hope I`m not barking up the wrong tree but have bbn of help! Regards Kew

  • I have a pop up which I can't get rid of which states: "There is no application set to open the URL ximadpzl://save_ximad_token----/"

    I can't get rid of a message which keeps popping up which says:
    There is no application set to open the URL ximadpzl://save_ximad_token/(etc)
    I have no idea to what they are referring and I can find no application which satisfy this requirement. How do I get rid of this message? It won't go away. I have tried turning off the computer, closing Safari, etc.

    All of these suggestions (delete caches, restart, terminal commands, etc) do nothing to actually LOCATE the problem. They are just standard purging processes, and they have all failed to achieve resolution.  And it is NOT Little Snitch either (tried turning that off and nothing changed).  All these forums on this matter have been speculative and useless.
    Ladies and Gents... I have found and isolated the ACTUAL PROBLEM.  It is a Safari Extension that is doing it... specifically "VideoCatcher 5.3.8" which for me was installed with MovieSherlock.  The extension adds the ability to download YouTube movies directly from Safari (by showing a small download button next to any embedded movie). When I remove that extension, all the annoying pop-ups go away.
    MovieSherlock is not the only utility that does this however. There are several YouTube downloaders out there that ALL install an extension that detects YouTube videos on the page. I bet my hat that many (if not all) of you who are experiencing this pop-up issue... have installed one of those downloader utilities.
    So, the solution is simple: disable that extension. If you need to download a YouTube video from a page, either temporarily enable that extension again as needed, or leave the Safari integration disabled and launch the actual utility itself and enter the URL into it for your download.
    I would expect that MovieSherlock and the other YouTube downloading utilities will need to update their extensions (soon?) to deal with Yosemite's new browser script management.
    PROBLEM SOLVED.

  • How do I get rid of the ugly yellow that is on Mozilla desk top now? I hate it

    how do I get rid of the ugly yellow on my desk top now with mozilla it is so ugly and annyoying? Can I change the color?

    See my second reply here:
    *[[/questions/1038807#answer-670671]] Who took a pee on Foxfire Start page; how get rid of yellow color?
    Mozilla shows snippets on the about:home page to run different campaigns and that changes regularly.
    If you prefer not to see snippets on the about:home page or if there are problems with a snippet then you can set the <b>browser.aboutHomeSnippets.updateUrl</b> pref to an empty string on the <b>about:config</b> page.
    Delete the <b>storage\persistent\moz-safe-about+home</b> folder in the Firefox profile folder with Firefox closed ("3-bar" Firefox menu button > Exit/Quit) to remove snippets stored in IndexedDB and make Firefox use a default snippet set.
    You can reset the browser.aboutHomeSnippets.updateUrl pref via the right-click context menu to the default value to re-enable the snippets and make Firefox recreate the moz-safe-about+home folder.
    Close and restart Firefox after changing the value of the browser.aboutHomeSnippets.updateUrl pref.

  • I have a Yahoo search bar next to the Url location bar. I would like to get rid of it. How?

    When I downloaded Firefox 4 this morning, I ended up with a Yahoo option for search on the tool bar next to the URL location space. I don't want the Yahoo search option and can't figure out how to get rid of it. I have read all the suggestions without help. I am running Windows 7.

    Reply: Cor-el > Excellent!! Thank You. In Tools, Add Ons, Extensions there was a Default Tab enntry which was the culprit. Am running W7 so the XP Tools, Options, Advanced , Use Hardware acceleration when available, wasn't of much help here, however I did fix a problem on another computer running XP with that same fix. Thank You very much! HD

  • Ugly blue loading boxes... how do I get rid?

    My uploaded pages on internet open with ugly blue boxes while they load on PC. this looks very unprofessional and I am hoping there is a way to simply change the colour or get rid of them all together. I haven't found any thing on the forum so maybe this is a rare problem which is easiy fixed...? hope so - Thanks in advance x
    imac G5 and ibook G4   Mac OS X (10.4.9)  

    As varkgirl mentioned IE does not play well with png files. Here are some tips I've collected from this forum on making iWeb sites more compatible with the darkside. Maybe one or two will be of help to you.1 - do not use and frames or borders, etc. around photos.
    2 - don't use any reflections.
    3 - create your own navigation bar with linked text* and turn of the iWeb Navigation bar.
    The nav bar is all png based.
    *Put your linked text directly under the Navigation bar. Then turn off the nav bar in the Inspector window. The nav bar will disappear and the linked text will move up to the top of the page.
    4 - use only the web safe fonts from the Font pane.
    5 - do not use drop shadow on fonts.
    6 - turn off smart quotes.
    The above will reduce the number and size of files associated with a web page quite a bit. Photos with fancy frames and reflections can generate a thumbnail png of around 110KB whereas the plain version will be a jpg of only 28KB. Although it doesn't sound like a lot, it will speed up loading of the page and be more darkside (i.e. PC) friendly.
    Run a test with a test site and publish to a folder. Then follow the hints above and publish to another folder and compare folders.
    Do you Twango?

Maybe you are looking for

  • Kernel 2.6.18 beyond?

    I'm using the beyond 2.6.17 kernel. Is there gonna be a 2.6.18 beyond kernel, or are the improvements in beyond already in 2.6.18 vanilla? Should I just switch to vanilla?

  • Why is "edit in Audition" greyed out in Premiere Pro and After Effects?

    Since the CC 2014 launch, the option in in Premiere Pro and After Effects to "edit in Audition" is greyed out. Right-clicking a clip in Premiere Pro doesn't have an option for Audition. I cannot send my compositions, sequences or clips to Audition fo

  • Requesting certificate problem ( SRV 2008 R2 )

    Dears, I have problem with requesting the certificate on server 2008 R2 , I create some template and I enable supply on the request but I couldn't enter the credential and customize the cert information like we had on 2003 . and when I put the root h

  • Photoshop 7.0 opens in too large to be seen

    I loaded 7.0 on a PC with XP. When it loads, only half the Photoshop window is visible and there is no scroll bar to allow access to the portion that is cut off. I've tried all of the options available under "properties" on the photoshop thumbnail bu

  • Action script.. help with using components

    i need help using the list component for my text in animation. i want the component to allow viewers to scroll and view text.