This forum has been moved here:
Helicon Tech Community Forum

Helicon Ape (Forum Locked Forum Locked)
 Helicon Tech : Helicon Ape
Subject Topic: retrieve page value in asp.net RewriteRul
Author
Message |
davidbni
Newbie


Joined: 08 December 2011
Location: United Kingdom
Posts: 4
Posted: 09 December 2011 at 3:42am

if i have a redirect in ape that is for
# Turn rewriting on
Options +FollowSymLinks
RewriteEngine On
# Redirect requests to index.php
RewriteRule .* /default.aspx

My question is how do i get the value of say
www.mysite.com/mypage how do i get the my page part from
.net to serve the pages
Back to Top
 
Anton
Admin Group


Joined: 30 January 2007
Location: Ukraine
Posts: 10519
Posted: 09 December 2011 at 4:09am

Sorry, not quite clear...
Could you please show the sample request you want to make and what you want to retrieve from it and what should be done to this next.

__________________
Regards,
Anton
Back to Top
 
davidbni
Newbie


Joined: 08 December 2011
Location: United Kingdom
Posts: 4
Posted: 09 December 2011 at 4:58am

Hi I am developing a cms with the help of ape so I am
wanting all page requests to go to page.aspx so all
sections like about home etc will go to page aspx and be
lifted from the database but how do i get the value after
mydomain.com/about/ how do i retreieve the about in coode
behind c#
Back to Top
 
Anton
Admin Group


Joined: 30 January 2007
Location: Ukraine
Posts: 10519
Posted: 12 December 2011 at 7:39am

Please have a look at this article about tuning WordPress with Ape.
It might be helpful: http://www.helicontech.com/articles/tuning-wordpress-with-helicon-ape-on-iis7-permalinks-browserserver-caching-
compression/

__________________
Regards,
Anton
Back to Top
 
davidbni
Newbie


Joined: 08 December 2011
Location: United Kingdom
Posts: 4
Posted: 12 December 2011 at 1:29pm

this is not to do with worpdress this is a .net system
Back to Top
 
Anton
Admin Group


Joined: 30 January 2007
Location: Ukraine
Posts: 10519
Posted: 14 December 2011 at 5:34am

I believe you need the following rules in .htaccess:

RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule (.*) /page.aspx [NC,L]

And as for this question "but how do i get the value after mydomain.com/about/ how do i retreieve the about in code behind c#":
- you can use one of the following variables X-REQUEST-URI or X_REWRITE_URL.

__________________
Regards,
Anton
Back to Top
 

Sorry, you can NOT post a reply.
This forum has been locked by a forum administrator.

Printable version Printable version