clean-urls

Gernerate custom urls within Magento

给你一囗甜甜゛ 提交于 2019-11-30 06:29:22
问题 I am currently looking at trying to generate custom urls/routing using magento, currently I have set a default route in config.xml within the local module. <frontend> <routers> <portfolios> <use>standard</use> <args> <module>Custom_Portfolios</module> <frontName>portfolios</frontName> </args> </portfolios> </routers> <default> <router>portfolios</router> </default> </frontend> This currently works with the url path of /portfolios/index/action/custom-string which is the magento default route.

How do I turn off viewstate for good?

╄→尐↘猪︶ㄣ 提交于 2019-11-30 05:08:57
Coming from a PHP background I love using clean URLs to grab data from one service to another. However, on some of my ASP.NET projects I get the horrible ViewState parameter in my URLs. Is there a way to turn this off globally? What affect will this have on my ASP.NET app? You can turn off viewstate for the whole site like this: <system.web> <pages enableViewState="false" /> That said, you shouldn't be getting it on the url. ViewState is a hidden field that is sent to the server with a postback (which normally uses post). It keeps the state of the controls when the page was rendered to the

How can I use Weblogic (12 C) without the application context in the URL?

僤鯓⒐⒋嵵緔 提交于 2019-11-29 14:32:38
I am working on a web project that requires Weblogic server and the only way I can view the site after deploying (on my Macbook Pro) is by specifying the application name as a prefix to the entire site. E.g. http://localhost:7001/myapp-weblogic/ This breaks a ton of styling and JavaScript code that access resources with root URLs (e.g. /images/example.png) While I can programmatically add "/my-app" to content in a .jsp, I can't do that in my .css files. I tried setting the "Default WebApp Context Root:" in Weblogic > console > Environment > Servers > myserver > Protocols > HTTP - But that did

How to remove controller name from url making it clean in codeigniter

非 Y 不嫁゛ 提交于 2019-11-29 13:41:19
I have the following url.. http://localhost/ci/site_controller/home I want to remove site_controller controller from url resulting in.. http://localhost/ci/home How can I do this in CodeIgniter ? Note: If you'll ask what I've tried than I've just done searching over Google as I don't know how to use mod_rewrite. EDIT I have this in my routes.php $route['default_controller'] = "site_controller/home"; $route['ci/home'] = 'ci/site_controller/home'; $route['404_override'] = ''; but still not working! .htaccess RewriteEngine On RewriteBase /ci/ RewriteCond %{REQUEST_URI} ^system.* RewriteRule ^(.*)

how to remove url (/web/index.php) yii 2 and set route with parameter with clean url?

99封情书 提交于 2019-11-29 07:49:54
first question: i already remove index.php , but i want remove /web also. this is my .htaccess RewriteEngine on # If a directory or a file exists, use it directly RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d # Otherwise forward it to index.php RewriteRule . index.php and this is config/web.php 'urlManager' => [ 'class' => 'yii\web\UrlManager', // Disable index.php 'showScriptName' => false, // Disable r= routes 'enablePrettyUrl' => true, 'rules' => array( '<controller:\w+>/<id:\d+>' => '<controller>/view', '<controller:\w+>/<action:\w+>/<id:\d+>' => '<controller>/

How do I turn off viewstate for good?

巧了我就是萌 提交于 2019-11-29 03:03:31
问题 Coming from a PHP background I love using clean URLs to grab data from one service to another. However, on some of my ASP.NET projects I get the horrible ViewState parameter in my URLs. Is there a way to turn this off globally? What affect will this have on my ASP.NET app? 回答1: You can turn off viewstate for the whole site like this: <system.web> <pages enableViewState="false" /> That said, you shouldn't be getting it on the url. ViewState is a hidden field that is sent to the server with a

MOD_REWRITE for URL variables, removing empty parameters and using more than 1field for the first and second variables

旧街凉风 提交于 2019-11-29 02:34:46
I have a previous question that was answered very well but requires an amendment and I was unable to reply so have created a new question. I required a mod_rewrite that made the following: www.example.com?page=var1&cat=var2&subcat=var3&subsubcat=var4 into this: www.example.com/var1/var2/var3/var4/ but that also covered the optional use of var2, var3 and var4 so if those variables were empty, it would still work. The question was answered very well but it requires an amendment to work with different field options for var2, var3 and var4. The code I have is: RewriteEngine on Options

Gernerate custom urls within Magento

本小妞迷上赌 提交于 2019-11-28 18:57:23
I am currently looking at trying to generate custom urls/routing using magento, currently I have set a default route in config.xml within the local module. <frontend> <routers> <portfolios> <use>standard</use> <args> <module>Custom_Portfolios</module> <frontName>portfolios</frontName> </args> </portfolios> </routers> <default> <router>portfolios</router> </default> </frontend> This currently works with the url path of /portfolios/index/action/custom-string which is the magento default route. What I am trying to achieve is to have /portfolios/custom-string.html I have attempted to use a mod

Handle $_GET requests with Clean URLs

試著忘記壹切 提交于 2019-11-28 14:46:56
I am have a clear URL based system so the categories will be shown like this http://www.mysite.com/category/23/cat-name Inside the categories page I have some sorting and pages options such as sorting by latests and lower price. Also, I have a pages navigation system The problem is when the request is happening inside the page the $_GET[] doesn't show the variables I need. However it shows in the URL as http://www.mysite.com/category/23/cat-name?page=3 The $_GET variable only shows the id of the category which is in our case now = 23 and ignored the page number which is in the url. .htaccess

How to remove controller name from url making it clean in codeigniter

↘锁芯ラ 提交于 2019-11-28 07:32:35
问题 I have the following url.. http://localhost/ci/site_controller/home I want to remove site_controller controller from url resulting in.. http://localhost/ci/home How can I do this in CodeIgniter ? Note: If you'll ask what I've tried than I've just done searching over Google as I don't know how to use mod_rewrite. EDIT I have this in my routes.php $route['default_controller'] = "site_controller/home"; $route['ci/home'] = 'ci/site_controller/home'; $route['404_override'] = ''; but still not