<httpModules>
<add type="Intelligencia.UrlRewriter.RewriterHttpModule,
Intelligencia.UrlRewriter" name="UrlRewriter" />
</httpModules>
<rewrite url="~/mytest.aspx" to="~/productdetails.aspx?product=1" />
</rewriter>
**********************************************************
Has any one else tried 'Rewrite' successfully ?
Venkatesh
> I am trying to do a url rewrite in a delphi eco asp.net application
> with urlRewriter.How ever it is not working & no rewrite is taking
> place
Hi Venkatesh,
Is there documentation for this other than in the readme ?
urlrewriter.net doesn't seem to work and I can't find anything at
sourceforge.
Cheers,
John
--
Blog: http://blog.moshine.com/
> I find lot of people using it effectively in C#.Does it mean that it
> does not work in Delphi asp.net. How does one do rewrite in delphi
> asp.net ?
It should work its just that the url in the readme
http://www.urlrewriter.net/ doesn't seem to.
Have you got a link to a csharp example ?
> It should work its just that the url in the readme
> http://www.urlrewriter.net/ doesn't seem to.
>
> Have you got a link to a csharp example ?
>
>
>
> Cheers,
> John
>
>
>
Hi John
Now it works in delphi too
Venkatesh
"VT Venkatesh" <ve...@vsnl.com> wrote in message
news:487c...@newsgroups.borland.com...
Now write the friendly url & the real url as under(as many as required)
*******************************************************
<rewriter>
<rewrite url="/Path/Friendly.aspx"
to="/Path/ProductDetails.aspx?product=1" />
********************************************************
(Friendly.aspx is the link in your web page &
ProductDetails.aspx?product=1 is the actual link.In the web page the
user will see Friendly.aspx & not ProductDetails.aspx?product=1 since
friendly.aspx is more search engine friendly)
Now add (under httpModules )
*********************************
<httpModules>
<add name="UrlRewriter"
type="Intelligencia.UrlRewriter.RewriterHttpModule,
Intelligencia.UrlRewriter"/>
</httpModules>
**********************************
Now when you run the application & click the link you will see
friendly.aspx as the url
See the nice article
http://weblogs.asp.net/scottgu/archive/2007/02/26/tip-trick-url-rewriting-with-asp-net.aspx
The only change i have to make was to remove ~ in
<rewrite url="~/products/books.aspx"
to="~/products.aspx?category=books" />
For me it was
<rewrite url="/products/books.aspx" to="/products.aspx?category=books"
I am yet to test in my shared host .I am running it my local machine
where there is path.In the server i will be running it directly under
root(/)
Venkatesh
> Care to share?
>
>
>
Thanks. I wanted to do something like this a long time ago when I
started doing my ISAPI dll. Maybe I will eventually look and see if that
will work for ISAPI too somehow.
So far, I have stayed away from ASP.NET. It seemed to complicated to me.
The ISAPI model is pretty darn simple, but covers the bases. After all,
ASP.NET is just ISAPI under the covers so I figure if it is good enough for
it, then it is good enough for me. And I don't have to have any extra
layer. And not much of what ASP.NET has would apply to me anyway. My main
app just generates SVG into a few frames. No data entry, grids of data
etc... Just visual stuff.
Thanks again. I wasn't sure when you said it was solved if you had used
the link or found something else...
"VT Venkatesh" <ve...@vsnl.com> wrote in message
news:487d5ed7$1...@newsgroups.borland.com...
>
> Thanks. I wanted to do something like this a long time ago when I
> started doing my ISAPI dll. Maybe I will eventually look and see if
> that will work for ISAPI too somehow.
>
> So far, I have stayed away from ASP.NET. It seemed to complicated to
> me. The ISAPI model is pretty darn simple, but covers the bases.
> After all, ASP.NET is just ISAPI under the covers so I figure if it
> is good enough for it, then it is good enough for me. And I don't
> have to have any extra layer. And not much of what ASP.NET has would
> apply to me anyway. My main app just generates SVG into a few
> frames. No data entry, grids of data etc... Just visual stuff.
>
Hi Mark,
I'm guessing svg is xml ? You don't need to use webpages with asp.net
controls. You can create "generic handlers". They are just classes with
a single method in which you compose your markup and write it out to
the response.
For example
procedure THandler1.ProcessRequest(Context: HttpContext);
begin
Context.Response.ContentType := 'text/html';
Context.Response.Write('<head>');
Context.Response.Write('<title>Handler1</title>');
Context.Response.Write('</head>');
Context.Response.Write('<body>');
Context.Response.Write('Hello World!');
Context.Response.Write('</body>');
Context.Response.Write('</html>');
end;
If you just use those you can still leverage the dotnet framework
serverside. I've done projects where the client side is all html and
I'm generated json in handlers for the UI.
What benefits does the ASP.NET offer versus my ISAPI app? ISAPI seems to
give me everything I want. I have very little html and a lot of generated
xml (svg). It seemed to me that the main thing ISAPI missed was "session"
which I have an object for since I don't want to rely on cookies.
Sorry if this seems like a dumb question.
>
> What benefits does the ASP.NET offer versus my ISAPI app? ISAPI
> seems to give me everything I want. I have very little html and a
> lot of generated xml (svg). It seemed to me that the main thing
> ISAPI missed was "session" which I have an object for since I don't
> want to rely on cookies.
>
In addition to what Venkatesh said, I find the depth of the framework
very beneficial. Not only can you do alot with it but there are usually
plenty of 3rd party libraries or snippets of code that you can make use
of.
Also if you start using something like Eco for data access then that
gives you another advantage.
I assume your using webbroker, at its core asp.net is very similar.
"John Moshakis" <jo...@moshakis.com> wrote in message
news:4880ddac$1...@newsgroups.borland.com...
> Mark Tiede wrote:
>
> In addition to what Venkatesh said, I find the depth of the framework
> very beneficial. Not only can you do alot with it but there are usually
> plenty of 3rd party libraries or snippets of code that you can make use
> of.
>
> Also if you start using something like Eco for data access then that
> gives you another advantage.
>
> I assume your using webbroker, at its core asp.net is very similar.
Yep. Using webbroker, which really, I like a lot. It is a VERY simple
framework that allows great flexibility. Currently, my web user interface
is SVG with a thin veneer of Javascript, html and frames. I am about to
embark on completely redoing my suite of applications. I intend to switch
to Eco which reduce some of my code by 70% or more and do more and do it
better. For the user interfacing on the web, I am considering replacing the
SVG pieces/parts with XAML and Silverlight. My user interface is primarily
pictures with navigation controls. So all those third party controls which
I assume would be perhaps some sort of data aware controls don't apply. But
there is lots of cool stuff I could do with XAML. Not quite sure at the
moment how that XAML stuff will fit in with Webbroker and I'm a little
concerned about the move away from webbroker (or at least an emphasis on
newer technology).
Still in the evaluation process. Hence the questions.