Configuring Bolt CMS for pretty URLs on IIS - bolt-cms

I have installed the Bolt CMS using IIS on Windows Server 2008 R2, and the site home page and all of the admin pages work fine, but any other pages that have been created within the admin are displaying a fatal error with the following message: •Class: Symfony\Component\HttpKernel\Exception\HttpException •Message: The page could not be found, and there is no 'notfound' set in 'config.yml'. Sorry about that.
I have the rewrite module installed in IIS and tried importing the .htaccess file so that the PHP handler will process extensionless URL's, but that did not resolve this problem.
Any assistance with resolving this would be greatly appreciated.
Thanks.
Todd

I also had this problem recently. Here are the settings I am using. First, go to your site in IIS Manager, open "URL Rewrite" and add a new rule.
Match URL
Requested URL: Matches the Pattern
Using: Regular Expressions
Pattern: I used ^cms/ since I have it in a subfolder. You may want just ^/
Conditions
Logical grouping: Match All
Add condition "Is Not a File" and "Is Not a Directory"
Action
Action type: Rewrite
Rewrite URL: cms/index.php (again you may want to remove the cms and just have index.php)
Tick "Append query string"
Tick "Stop processing of subsequent rules"

Related

¿How can i add a url path in html withoout a server, when click on about. Exist a meta name?

I need to change url with a click, without a server because i have in githubpages and domain in netlify, i know that maybe using npm and deploy a build but i want something more easy because the site is deploy and we don't want conflicts :( thanks community i try with meta property but cant, i have the hosting in github and just a index.html
I solve it in netlify,going to build and deploy then to Post processing and finally to Asset Optimization, the enable pretty urls, the engine read de href that have a html and clean a pretty url.

404 error on the default page on my Gitlab repository

This is my first time using Gitlab.
My repository url is myusername.gitlab.io/myrepo.
Opening that page gives me a 404 error, however when I open myusername.gitlab.io/myrepo/myindex.html, I get my index page.
Can someone tell me how I can set it so myusername.gitlab.io/myrepo loads myusername.gitlab.io/myrepo/myindex.html.
On a second note, I have seen other projects that use username.gitlab.iowithout the need for the/therepo` suffix.
Can anyone tell me how I can remove the suffix and just use the domain to access my repo.
Your server may prefer a default 'index' file to be loaded. In some cases, it may not handle the default file at all.
Rename you index file from myindex.html to index.html
First, to start, you can fork a pre-set project, with the right files in it (including an index.html): see gitlab.com/pages for examples, and "Getting started" for the steps
.
I really want to have myusername.github.io only
Second, that is a user website: make sure your repo (where you have forked/cloned the project example) is named after your GitLab login: <you>.gitlab.io.

PhpStorm mutualized deployment conflicting server root URL

How to set an absolute project URL, different from the root server URL ?
I look for solutions other than:
Settings: seems out of date (I run PS-181)
leaving server root url empty, tip from Jason Lotito.
The second works for me but the GUI keeps yelling that the server root URL is not specified.
But no longer works if the
Did anyone came with a proper, better solution?
EDIT: How to set the project URL
File
Settings
Build, Execution, Deployment
Deployment
tab Connection: set "web server root URL"
tab Mappings: set "web path on server"
EDIT 2:
So you are sharing the same deployment entry between multiple projects... Why not just make it visible to current project only ... so it become project specific and you enter any data you want without any hacks (as it will have no influence on another project). P.S. The ticket you have mentioned was created long time ago when there were shared entries only. project-specific entries are available for quite few years now... –
I precisely use the same deployment between multiple projects: I have multiple mutualized servers. The only difference between projects of the same server belongs to the "mappings" tab.
Moreover, if I set the Web server root URL to my project domain, I have to hack again the Web path on server ... but putting something (like a /), which is a crappy solution.
Clicking Visible only for this project means that I have to create new deployment for each project (which becomes tedious after 30 copy/paste).
As said in the old ticket, if the Project URL of the mappings tab were an editable text field, all would be much simpler.

PhpStorm remove port from localhost URL

When I run my files it takes me to: http://localhost:63342/leadmandist/index.php
I want it to take me to:http://localhost/leadmandist/index.php
How do I remove this :63342 from the URL as it is causing a "Bad Gateway" error? I want this to apply to all of my files.
I tried removing the port in the settings but it won't allow an empty value and just reverts back to 63342.
I am using WAMPServer. If there is a better solution than what I want then I'd love to know.
The URL you are seeing there is PhpStorm's own simple built-in web server. If you want to use your own web server (Apache/IIS/nginx/whatever) then you have to tell IDE about it:
Settings/Preferences | Build, Execution, Deployment | Deployment
Create and configure new entry (In Place type should do; as long as your files are already located in a place where Apache will be able to serve them from)
The key here is to provide your desired URL here
Mark this entry as Default for this project
Now when you will use "Run" or "Open in Browser" the IDE will use URL defined there as a base for constructing full URLs.

How to configure Netbeans code entry point when you use mod-rewriting

I am developing a website in PHP and I am using mod-rewrite rules. I want to use the Netbeans Run Configuration (under project properties) to set code entry points that looks like http://project/news or http://project/user/12
It seems Netbeans have a problem with this and needs an entry point to a physical file like http://project/user.php?id=12
Has anyone found a good way to work around this?
I see your question is a bit old, but since it has no answer, I will give you one.
What I did to solve the problem, was to give netbeans what it wants in terms of a valid physical file, but provide my controller (index.php in this case) with the 'data' to act correctly. I pass this data using a query parameter. Using your example of project being the web site domain and user/12 as the URL, use the following in the NetBeans Run Configuration and arguments boxes. netbeans does not need the ? as it inserts that automatically, see the complete url below the input boxes
Project URL: http://project
Index File: index.php *(put your controller name here)*
Arguments: url=user/12
http://project/index.php?url=user/12
Then in your controller (index.php in this example), test for the url query param and if it exists parse it instead of the actual Server Request, as you would do normally.
I also do not want the above URL to be publically accessible. So, by using an IS_DEVELOPER define, which is true only for configured developer IP addresses, I can control who has access that special url.
If you are trying to debug specific pages, alternatively, you can set the NetBeans run configuration to:
http://project/
and debug your project, but you must run through your home page once and since the debugger is now active, just navigate to http://project/user/12 in your browser and NetBeans will debug at that entry point. I found passing through my home page every time a pain, so I use the technique above.
Hopefully that provides enough insight to work with your project. It has worked good for me and if you need more detail, just ask.
EDIT: Also, one can make the Run Configuration Project URL the complete url http://project/user/12 and leave the Index File and Arguments blank and that works too without any special code in controller. (tested in NetBeans 7.1). I think I will start using this method.