IPlanet WS : URL rewrite rules

Is it possible to rewrite URL automatically with Iplanet WS 6.0 sp1 ?
What I would like to do this :
Catch URL like this : http://www.hello.com/page/P/rub/...
And rewrite it like this :
http://www.hello.com/page.jsp?P=rub/...
Note : Apache can do this with mod_rewrite.
What solutions do you think I can use ?

Hi,
Please check out the below link which will tell about "Mapping URLs and URL Forwarding".
http://docs.sun.com/source/816-5691-10/essearch.htm#25618
http://docs.sun.com/source/816-5691-10/escontnt.htm#1002112
For more info. check out Sun ONE webserver6.1 NSAPI guide.
Hope this helps.
Regards,
Dakshin.
Developer Technical Support
Sun Microsystems
http://www.sun.com/developers/support.

Similar Messages

  • URL Rewrite Rule: HTTP to HTTPS Not Working

    Here is my problem. I cannot get HTTP to HTTPS redirect to work using the URL Rewrite module. I am using version 2, by the way, which I understand is the latest version. I've also enabled the "Proxy Server" and Application Request Routing"
    features.
    I've trolled through the Internet for 2 days now for solutions to my problem, including the ones provided by the TechNet forums and by MVP Scott Forsyth. I've tried over 30 solutions, and none have resolved my issue. Granted some of the solutions I've tried
    may have been repeats of others. After trying so many, I have had a hard time discerning the differences. Does it really matter, for instance if the pattern match for the {HTTPS} input is specified as
    "^off$" or just "off"? I see this discrepancy (among others) everywhere. It seems like there are so many variations out there. It is quite confusing for the uninitiated and the newbies like myself to the
    URL Rewrite technology. I have enabled and consulted my "Failed Request Tracing Rules" logs but cannot make any sense of the cryptic information it is providing.
    I just cannot get my reverse proxy server to redirect http requests from the Internet to https to my internal web server. When a user specifies "https://server1.xxxxx.com". he is able to access the internal server via the reverse proxy (IIS) server.
    But when he specifies "http://server1.xxxxx.com" he receives "Server Error 500 - Internal server error.There is a problem with the resource you are looking for, and it cannot be displayed."
    At this point I am at my wits end, and am even considering configuring the protocol translation on our firewall. But this not my preference as it presents another layer of complexity, and device to troubleshoot later on. Below I've pasted my entire web.config
    file with my most current version of the rule in question (in bold) for your review. I started to paste just the specific rule, but thought you might need to see the entire file in case something else may be conflicting with the rule.
    Thank you in advance for your help.
    Dave Robinson
    <?xml version="1.0" encoding="UTF-8"?>
    <configuration>
        <system.webServer>
            <rewrite>
                  <rules>
                    <clear />
    <rule name="HTTP to HTTPS Redirect" enabled="true" stopProcessing="true">
                    <match url="(.*)" />
                   <conditions>
                      <add input="{HTTPS}" pattern="off" />
                    </conditions>
                      <action type="Redirect" url="https://{HTTP_HOST}/{REQUEST_URI}" redirectType="Found" />
                    </rule>
    <rule name="ReverseProxyInboundRule1" stopProcessing="true">
                        <match url="(.*)" />
                        <conditions logicalGrouping="MatchAll" trackAllCaptures="false">
                            <add input="{CACHE_URL}" pattern="^(https?)://" />
                        </conditions>
                        <serverVariables>
                            <set name="HTTP_X_ORIGINAL_ACCEPT_ENCODING" value="{HTTP_ACCEPT_ENCODING}" />
                            <set name="HTTP_ACCEPT_ENCODING" value="" />
                    </serverVariables>
                        <action type="Rewrite" url="{C:1}://server1.xxxxx.com/{R:1}" />
                    </rule>
                </rules>
                <outboundRules>
                    <rule name="RestoreAcceptEncoding" preCondition="NeedsRestoringAcceptEncoding">
                    <match serverVariable="HTTP_ACCEPT_ENCODING" pattern="^(.*)" />
                    <action type="Rewrite" value="{HTTP_X_ORIGINAL_ACCEPT_ENCODING}" />
                    </rule>
                    <rule name="ReverseProxyOutboundRule1" preCondition="ResponseIsHtml1">
                        <match filterByTags="A, Form, Img" pattern="^http(s)?://server1.xxxxx.com/(.*)" />
                        <action type="Rewrite" value="http{R:1}://server1.xxxxx.local/{R:2}" />
                    </rule>
                    <preConditions>
                        <preCondition name="ResponseIsHtml1">
                            <add input="{RESPONSE_CONTENT_TYPE}" pattern="^text/html" />
                        </preCondition>
                        <preCondition name="NeedsRestoringAcceptEncoding">
                            <add input="{HTTP_X_ORIGINAL_ACCEPT_ENCODING}" pattern=".+" />
                        </preCondition>
                    </preConditions>
                </outboundRules>
            </rewrite>
            <tracing>
                <traceFailedRequests>
                    <add path="*">
                        <traceAreas>
                            <add provider="ASP" verbosity="Verbose" />
                            <add provider="ISAPI Extension" verbosity="Verbose" />
                            <add provider="WWW Server" areas="Authentication,Security,Filter,StaticFile,CGI,Compression,Cache,RequestNotifications,Module,FastCGI,WebSocket"
    verbosity="Verbose" />
                        </traceAreas>
    <failureDefinitions timeTaken="00:00:00" statusCodes="404" />
                    </add>
                </traceFailedRequests>
            </tracing>
            <httpErrors errorMode="Custom" />
            <httpRedirect enabled="false" destination="" exactDestination="false" childOnly="false" httpResponseStatus="Permanent" />
        </system.webServer>
    </configuration>

    On Wed, 28 Jan 2015 17:53:41 +0000, dwrobins2000 wrote:
    Here is my problem. I cannot get HTTP to HTTPS redirect to work using the URL Rewrite module. I am using version 2, by the way, which I understand is the latest version. I've also enabled the "Proxy Server" and Application Request Routing"
    features.
    Web/IIS related issues are better posted where the IIS experts are:
    http://forums.iis.net
    Paul Adare - FIM CM MVP
    "The equivalent of treating dandruff by decapitation"
    -- Frank Zappa on the Parents Music Resource Center' censorship plans

  • URL Rewrite Rules in 10.1.4

    Hi,
    I am having some trouble rewriting the urls, I can't make it work ...
    What I want is to change the url:
    http://www.mycompany.com/portal/page/portal/portal_sverige/
    to
    http://www.mycompany.com/sverige
    Where "portal_sverige" is the page group.
    What I did was:
    Configure the properties in the page group:
    Search pattern: /portal/page/portal/portal_sweden/
    Replace pattern: /sweden/
    And I went to enterprise manager, MT, http server, administration, advanced server properties, httpd.conf, and put in the lines:
    RewriteEngine On
    RewriteRule ^/sweden/(.*)$/portal/page/portal/portal_sweden/$1 [PT]
    However, when I try to use navigator to edit a page in that group, I get:
    http://www.mycompany.com/sweden/pagename?_mode=16
    Returns:
    Object not found. (WWC-50003)
    And just typing in www.mycompany.com/sweden returns 404 error instead of the root page as I would have liked.
    Any ideas about what to do? I can't really find any information ... is the change made in the MT ? IM ? Do I have to do it in some specific order? Is the syntax wrong?
    Appreciate any help, thanks

    Hello Sayeeas,
    I posted an answer to this question a couple months back... check out the thread
    Re: Portal URL Rewrite
    Here is the answer:
    In this example the name of the page group is "www":
    Our rewrite rule is also set up in a virtual host section of the httpd.conf file as well so some of the options may not be required for your set up:
    RewriteEngine on
    RewriteOptions inherit
    RewriteCond %{REQUEST_URI} !^/(portal|pls|images).*$
    RewriteRule ^(.+) /portal/page/portal/www$1 [PT]
    The rewrite condition allows us to ignore the rewrite for certain items in the path. This allows the portal navigator to work. There may be a couple more items that need to be added to the condition because I recently noticed that the help pages dont function properly.
    In the portal configuration for the rewrite rule we specify:
    Search pattern: /portal/page/portal/www
    Replace pattern:
    Thats right, the replace pattern is blank.
    To see it in action check out http://www.sagelogix.com
    -sean
    Solutions Architect
    http://www.sagelogix.com

  • Web dispatcher url Rewritting to several sap systems

    Hello SAP NW Community,
    we need a reverse Proxy to achieve   application of different SAP System via Internet. We desided to use web Dispatcher.
    The host names of sap systems should not be visible,  because of this we create the following URL Rewritting rules.
    For example:
    AAA, BBB and CCC are sap System SIDs;
    "wdisp.company.com" is the FQDN fron webdispatcher
    The "icm_filter" Looks like this:
    if% {HTTP_HOST} RegIMatch "wdisp.company.com"[and]
    If% {PATH} RegIMatch "AAA"
    RegIRewriteUrl ^/AAA/(.*)  /$1 [noescape]
    SetHeader x-sap-webDisp-target-sid AAA [break]
    the next rules are the same but for BBB and CCC.
    The idea is to rewrite in background all URLs such as:
    http(s)://wdisp.company.com/AAA/...
    to :
    http(s)://<FQDN from AAA>/...
    The result is always the same: the rewritting for AAA works fine but for BBB and CCC we get -http error 404.
    The results are independent from web browser(IE or Firefox).
    The http trace Tools- HttpWatch Basis or Firebug show also no rewritting  for BBB und CCC.
    According the documentation is web Dispatcher able to support  many "stateful" and "stateless"  connection to different backend sap System.
    Do you have any ideas why the rewritting works only for the first sap System?
    We tested with different browser and Browser sessions but the resul was the same.
    BR,
    Rumen

    Hi,
    Instead of PATH , use different pots like this, you can get the URL redirection,
    icm_filter.txt :
    if %{HTTP_HOST} regimatch wdhost.company.com* 
    SetHeader x-sap-webdisp-target-sid AAA [break]
    if %{HTTP_HOST} regimatch wdhost.company.com*
    SetHeader x-sap-webdisp-target-sid BBB [break]
    if %{HTTP_HOST} regimatch wdhost.company.com*
    SetHeader x-sap-webdisp-target-sid CCC [break]
    In Instance profile :
    wdisp/system_0 = SID=AAA,MSHOST= AAA.HostNane ,MSPORT=8111
    wdisp/system_1 = SID=BBB,MSHOST= BBB.Hostname ,MSPORT=8100
    wdisp/system_2 = SID=CCC,MSHOST= CCC.Hostname ,MSPORT=8101
    URL :
    http://wdhost.company.com:8111 --- goes to AAAhost and so on.
    regards
    Vagesan

  • CF9, IIS7.5, CFImage, /CFFileservlet/, Handler Mapping, URL Rewrite

    I am trying to figure out how to enable the default handler in II7 like it was done in IIS6, with the "Verify file exisits" option turned off.
    In IIS7 I have been lead to "Invoke handler only if request is mapped to:" however if that is unchecked, no static files (css, js, etc)  are served.

    Are you sure that your tag meets all of the requirements?  Check out the documentation here: http://help.adobe.com/en_US/ColdFusion/9.0/CFMLRef/WSc3ff6d0ea77859461172e0811cbec22c24-79 45.html
    Specifically for captcha that article mentions:
    For the CAPTCHA image to display, the width value must be greater than: fontSize times the number of characters specified in text times 1.08.
    ColdFusion supports CAPTCHA images in PNG format only.
    I believe the images generated from the cfimage tag are also served up from a differently location than your web-root.
    Is your server allowing the PNG file extension?  With your URL rewrite rule are you still seeing the request reach IIS (iis log)?  Is it reaching ColdFusion (coldfusion log)?  Is your server allowing access to the directory where the generated image is stored (view the browser source code when it works to see where the image is actually stored)?

  • URL Rewriting Session ID Length in iPlanet Application Server

    Hi there,
    Does anyone know what the maximum length of the session ID value is when
    using URL rewriting/encoding for session tracking (i.e.: ";jessionid=1234"
    appended to the end of the URL) with iPlanet Application Server 6.0's
    servlet container (or any previous versions)?
    Does the length vary or is it fixed? And does WebSphere encode server or
    failover information into the ID? WebLogic for instance, encodes the
    primary and secondary failover servers into the ID when running in a
    cluster)?
    And finally, is there any way to restrict or specify the maximum length of
    the session ID?
    I ask this due to a limitation with some WAP clients & gateways which
    prevents the URL from exceeding 128 characters.
    Any info on this issue from iPlanet staff or anyone else is much
    appreciated.
    <background-info>
    Please see the following links if you'd like some additional background:
    http://e-docs.bea.com/wls/docs60/////wap/wapdev.html#1024984
    under the heading "Session Tracking" at the bottom
    http://groups.google.com/groups?hl=en&safe=off&th=eb7f38aa5086972e,13&seekm=
    8gaki8%247d5%241%40newsgroups.bea.com#p
    </background-info>
    Regards,
    Sasha Haghani

    Sasha Haghani wrote:
    Hi there,
    Does anyone know what the maximum length of the session ID value is when
    using URL rewriting/encoding for session tracking (i.e.: ";jessionid=1234"
    appended to the end of the URL) with iPlanet Application Server 6.0's
    servlet container (or any previous versions)?
    I'm fairly certain that it is fixed. 18 for the attibute, 16 for the value, plus
    1 for the equals. (Plus 1 for the ? if it didn't already exist.)
    So 35 or 36 depending on how you count it. Someone needs to verify this and
    check my counting though.
    >
    Does the length vary or is it fixed? And does WebSphere encode server or
    failover information into the ID? WebLogic for instance, encodes the
    primary and secondary failover servers into the ID when running in a
    cluster)?I don't know what WebSphere does. iAS does not encode failover information in
    the ID. Because of the way session is propogated, no server information needs to
    be embedded in the id.
    >
    And finally, is there any way to restrict or specify the maximum length of
    the session ID?No.

  • Warning: No patterns found. Skipping rewrite rules creation for Meet simple URLs.

    Hi 
    It feels like a have tested the most that I can Google, but im new on Lync..
    I have a lync multitennant 2013 server.
    But when I run enable-cscomputer I get the following
    WARNING: No patterns found. Skipping rewrite rules creation for Meet simple URLs.
    WARNING: No patterns found. Skipping rewrite rule creation for dial-in conferencing.
    WARNING: No patterns found. Skipping rewrite rule creation for Web Scheduler.
    WARNING: No patterns found. Skipping rewrite rule creation for dial-in conferencing.
    WARNING: No patterns found. Skipping rewrite rule creation for Web Scheduler.
    WARNING: "Enable-CsComputer" processing has completed with warnings. "5" warnings were recorded during this run.
    WARNING: Detailed results can be found at "C:\Users\xxx\AppData\Local\Temp\Enable-CsComputer-26374787-f6b5-4a07-b8f4-7bd819d3ffc3.html".
    Im not sure what to test? And what to do to verify that the settings is correct. Im new on Lync.. So all tips are greatly appreciated.

    To set the DNS name for the simple URL for multitenant Lync Server, run the following cmdlets:
    $BaseURL = "https://meet.litwareinc.com/"
    set-CsProvisionServiceConfiguration -SimpleUrlDnsName $BaseURL
    To verify that the DNS name was set, run the following cmdlet:
    (Get-CsProvisionServiceConfiguration).SimpleUrlDNSName
    The following is a similar thread you can refer to:
    http://social.technet.microsoft.com/Forums/lync/en-US/dfa064d8-5c53-4a69-aecd-ffe487a353d1/lync-meet-now-not-working
    Lisa Zheng
    TechNet Community Support

  • Apache rewrite rule working with whitespaces in portal URL

    Hello,
    we have a portal with several page groups. These are accessed through different virtual hosts in Apache. The rewrite rules look like:
    RewriteRule ^/website1(.*)$ /portal/page/portal/website1/$1 [PT]
    The problem is, it does not work when there is more than one space in URL (fe.: website1/subpage 1/subpage 2). The result is http error 413.
    I guess, it is related to PT flag and escaping URI.
    RewriteRule flag B would probably do the trick, but it is available in Apache 2.2 only.
    We have tried following, as well:
    RewriteMap escapemap int:escape
    RewriteRule ^/website1(.*)$ /portal/page/portal/website1/${escapemap:$1} [PT]
    That works for any number of spaces! On the other hand side, it does not work for Czech (accented; URI escaped) characters any more. :-(
    Does anyone have a working rewrite rule? Any hints?
    Thank you!
    ViNiL

    Hi Pratap
    Check SAP Note 698329 this note give details for logon fails
    U Need to enable SAPGUI for html
    goto se80 give internet services (in the drop down box)
    Below drop down give SYSTEM publish these service by right clicking system publish--complete service.
    and also publish same way WEBGUI
    and also enter ur server ip address and hostname in C:\WINDOWS\system32\drivers\etc-->hosts
    Hope this helps you.
    Regards
    Krishna.

  • URL rewrite in iplanet sun web server 6.0

    HI,
    I've been using SunONE web server 6.0 for a while.
    Our website is changing to adapt URL rewrite. Can you please show me how or where to get such information about how to do URL rewrite in web server 6.0?
    http://domain.com/index.php?=c2345 ----> to this nice-looking URL http://domain.com/index/mainsite
    thanks so much!

    This would be non-trivial in WS6.0. Additionally, WS6.0 is end-of-lifed, and has known security problems that are NOT going to be fixed. You should consider upgrading.
    URL re-writing (and much more) is a native feature of WS7.0.

  • Apache URL rewrite

    Hi,
    To make iPlanet work with apache, documentation ask me to change
    httpd.conf so that all request comes into apache will forward to
    iPlanet.
    But I need to use URL rewrite module of apache contains the rewrite rule
    RewriteRule ^/lmp
    /NASApp/delivery/servlet/delivery;jsessionid=%{QUERY_STRING} [PT,NS]
    which means if URL contains /lmp then rewrite to iPlanet handler
    /NASApp/...etc
    any one had successfully configure apache mod_rewrite works with
    iPlanet?
    In my pervious experience with Tomcat apache. I realize I have to load
    the web-server-plugin module before module rewrite module. But if I do
    that with iAS. then i get 404 not found on request to servlet.
    thanks

    We use iPlanet and apache with mode_rewrite
    Try this:
    RewriteEngine On
    RewriteLog /usr/local/apache/logs/rewrite.log
    RewriteLogLevel 1
    # Rewrite Rules for App1
    RewriteCond %{HTTP_HOST} ^app1.company.de$
    RewriteRule ^/ https://myiWS.company.de:8011/NASApp/app1/mystartup.jsp

  • IIS 7.5 URL Rewrite: Hit specific page of a web application but should be redirected to another application's page

    I have deployed 2 different web application on IIS 7.5 running on Windows Server 2008 R2 but on different port numbers i.e. one application deployed on port no. 1776 and another on 8091. I want to rewrite URL in such a way that if i hit any page of first
    application such as default.aspx then it will be redirected to particular page of another application along with some changes in url.
    Example: if i access any page from first application like:
    http://g2wv126rbsc:1776/sites/main/commercial/commercial-solutions/financing/default1.aspx
    then it should redirect to specific page of another application along with some changes in url:
    http://g2wv126rbsc:8091/main/commercial/commercial-solutions/financing/default2.aspx
    Note: In above mentioned url, also removed "sites".
    I tried to create a inbound rule through URL Rewrite module (installed on IIS 7.5) by selecting Action as "Rewrite" but didn't find any success.
    I need some examples if anyone has come across same kind of issue.
    Thanks in advance.

    Please post ASP.NET questions in the ASP.NET forums (http://forums.asp.net ).

  • ColdFusion with IIS URL Rewrite - Page never finishes loading

    I am running CF10 on IIS 7.5 with URL Rewrite module installed.
    All the rewrite rules work perfectly and ColdFusion is returning the correct pages. In order to get the page displayed in the browser I have to manually set the 'content-length' value in Application.cfc like this:
    <cfcomponent>
    <cffunction name="onRequestEnd">
    <cfheader name="Content-Length" value="#getPageContext().getCFOutput().getBuffer().size()#" />
    </cffunction>
    </cfcomponent>
    Without this code the browser does not display the page. However, even though it is now displaying the page, it is not doing it correctly. The page never finishes loading fully and not all of the HTML content seems to be on the page.
    I have tried to add a <cfflush> tag after setting the 'content-length' but it makes no difference. I don't understand why this is happening but I know that it has happened to someone else who was using htaccess: http://forums.devshed.com/coldfusion-development-84/page-not-finishing-loading-coldfusion- and-htaccess-bug-575906.html
    Can anyone please help?

    Hi guys,
    I would like to do url rewriting on our CF app but am worried I'll break something if I try and do it myself - is there anyone who would be interested in a bit of consultancy to help us achieve this?
    I want to turn http://www.allchichesterjobs.com/search-results.cfm?sector=21&q=part-time-jobs
    into http://www.allchichesterjobs.com/part-time-jobs
    I've tried this using IIS and URL Rewrite, when I browsed to http://www.allchichesterjobs.com/search-results.cfm?sector=21&q=part-time-jobs
    my browser was redirected to http://www.allchichesterjobs.com/part-time-jobs ok - but then I got a 404 error
    I'm wondering if I can pay someone to remote view my screen while we talk on skype and tell me what to do?
    Hope it's ok to post this sort of request on here
    Thanks very much indeed.
    Nick

  • IIS Reverse Proxy with URL rewrite.

    Hi all, hoping to leverage the wealth of knowledge contained here.
    Any assistance would be very welcome.
    I'm having an issue getting a reverse proxy and URL rewrite working in IIS 7.0.
    I need to redirect all requests with a specific virtual directory suffix only.
    ie; https://domain.test.com/outbound/Content/query_etc
    With /Outbound/ being the trigger.
    This should be redirected to http://10.10.10.10/inbound/Content/query_etc
    While at the same time, requests without the /outbound/ suffix should be handled locally.
    I have configured the reverse proxy as described in a few articles, and have had no luck.
    Here's a snippet from my (sanitized) web.config at the site level.
    <rewrite>
    <outboundRules>
    <rule name="ReverseProxyOutboundRule1" preCondition="ResponseIsHtml1">
    <match filterByTags="A" pattern="^http(s)?://10.10.10.10/inbound/(.*)" />
    <action type="Rewrite" value="https://domain.test.com/outbound/{R:2}" />
    </rule>
    <preConditions>
    <preCondition name="ResponseIsHtml1">
    <add input="{RESPONSE_CONTENT_TYPE}" pattern="^text/html" />
    </preCondition>
    </preConditions>
    </outboundRules>
    <rules>
    <rule name="ReverseProxyInboundRule1" stopProcessing="true">
    <match url="^outbound/(.*)" />
    <action type="Rewrite" url="http://10.10.10.10/inbound/{R:1}" appendQueryString="true" logRewrittenUrl="false" />
    </rule>
    </rules>
    </rewrite>
    To me, this looks correct, yet it doesn't work.
    With this, I get the normal 404 - Error Code 0x80070002, with the text indicating the local directory doesn't exist, so.... not being picked up by the filter for redirection.

    Hi Andrew,
    Looking at your requirements it appears you need Reverse Proxy To Another Site/Server.
    By using URL Rewrite Module together with
    Application Request Routing module you can have IIS 7 act as a
    reverse proxy.
    It seems like URL Rewrite can't re-route the request somewhere else out of the server.
    Even when you rewrite the url the actual connection remains with the server. Hence if your original server doesn't have /inbound/Content/query_etc  it will fail with 404.
    Hosting multiple domain names under a single account using URL Rewrite.
    It’s a common desire to have a single IIS website that handles multiple sites with different domain names.
    References:
    How to create a url alias using IIS URL Rewrite:
    http://blogs.technet.com/b/mspfe/archive/2013/11/27/how-to-create-a-url-alias-using-iis-url-rewrite.aspx
    Reverse Proxy with URL Rewrite v2 and Application Request Routing:
    http://www.iis.net/learn/extensions/url-rewrite-module/reverse-proxy-with-url-rewrite-v2-and-application-request-routing
    Regards,
    Satyajit
    Please“Vote As Helpful”
    if you find my contribution useful or “MarkAs Answer” if it does answer your question. That will encourage me - and others - to take time out to help you.

  • Rewrite rules: mod_rewrite vs. SJWS 7

    Hi,
    I migrate some application which uses mod_rewrite. And I have a serious problems with write correct rules in obj.conf.
    I need to implement two task (below):
    1. some like below
    RewriteRule ^/$ http://test1.domain.com/index.dhtml [R=301,L]
    RewriteRule !\.(html|php|jpg|png|css|png|xls|xdoc|xsl|xlsx|pdf|dhtml) http://test2.domain.com%{REQUEST_URI}? [R,L]2. some simple redirect from
    http://test1.domain.com/name.surname
    to
    http://test1.domain.com/employees.dhtml?where=all&search=name+surname
    I try to write some rules but I still have errors. I hope there are some people who know SJSW and can help.
    thanks
    Irek

    References
    [http://blogs.sun.com/elving/entry/regular_expression_redirects_in_7]
    [http://blogs.sun.com/dzm/entry/web_server_7_0_gallery2]
    [http://blogs.sun.com/dzm/entry/playing_with_pattern_matching]
    [http://docs.sun.com/app/docs/doc/819-2614/6n4t239c4?a=view]
    [http://docs.sun.com/app/docs/doc/820-4848/gduun?a=view]
    [http://forums.sun.com/thread.jspa?threadID=5312149]
    [http://forums.sun.com/thread.jspa?threadID=5343970]
    I do not know much details about mod_rewrite but let me try to guess. I have not tested it.
    For
    RewriteRule ^/$ http://test1.domain.com/index.dhtml [R=301,L]you can try
    <If not $internal and  $uri =~ "^/$>
    NameTrans fn="redirect" $url="http://test1.domain.com/index.dhtml"
    </If>
    {code}
    For
    {code}RewriteRule !\.(html|php|jpg|png|css|png|xls|xdoc|xsl|xlsx|pdf|dhtml) http://test2.domain.com%{REQUEST_URI}? [R,L]{code}
    (note that you have png twice)
    you can try
    {code}
    <If not ($type =~ "html" or $type =~ "php" or $type =~ "jpg"  or $type =~ "png" or
             $type =~ "css" or $type =~ "xls" or $type =~ " xdoc" or $type =~ "xsl" or
             $type =~ "xlsx" or $type =~ "pdf" or $type =~ "dhtml" ) >
    NameTrans fn="redirect" url="http://test2.domain.com/$uri"
    </If>
    {code}
    where $type is and Alias for $srvhdrs{'content-type'}
    If you have to do URL rewriting (on the same server) then you could have used restart function.
    {code}<If not $internal and $uri =~ "^/$">
    NameTrans fn="restart" uri="/index.dhtml"
    </If>{code}
    Let us know if it worked for you.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • URL  Rewriting

    Hi,
    I got a problem in URL rewriting:
    original source:
    <script language="JavaScript" src="/javascript/resselect.js"></script>
    after rewrite:
    <script language="JavaScript" src="http://gate way:89/http://xxx.com/javascript/resselect.js?scriptReferrer=http://xxx.com/"></script>
    How can I remove "scriptReferrer=http://xxx.com/"?
    Thanks in advance.
    Rick.

    I had a similar problem (Portal 6.1) and it ended up being a javascript function that was not rewriting properly. I had to add a rule to my default_gateway_ruleset.
    The function being called was Select() so the rule I added was this:
    <Function type="URL" name="Select" paramPatterns=",y" />
    Refer to the portal documentation about "Rules for JavaScript Content" rewriting:
    http://docs.sun.com/source/816-6732-10/rewriter.html
    Hope that helps you.

Maybe you are looking for

  • How To Connect My PB To An iBook...

    My cousin just bought a new ibook - I'll be going to over to help him set it up and it would be nice to transfer some of the family pics / files I have on my powerbook over to his machine to load up into iphoto etc. I'd like to find a way of connecti

  • How to play the music in a HIFI system using bluetooth or WIFI

    How to throw music from Sony Xperia Tablet S to another device, I have tried without success to throwthe music to Windows Media Player 11 (in a Windows Vista and in a Windows 7 computer), using DLNA/DRM, and also to Bluetooth. What I want is to liste

  • Validating a Date field in ADF which only contains a time

    Hi, I'm having problems in JDeveloper 10121 validating a "time" field in a jsp. * I have this field: <html:text property="InterviewTime" size="4" maxlength="4" /> which is a date. I want the user to enter a date in 24 hour format. I.e. 0000 to 2400.

  • IOS4 Upgrade Wiped iPod Contents

    Over the years I have never had a problem with any Apple software downloads until now. I just upgraded to iOS4 and find that all my music, photos & audiobooks are gone! Apps and Calendar are OK. Since iTunes said it was backing up the iPod before the

  • My Internal HD is full

    My internal HD (13gigs) is full. I've attached a 40 gig external. I would like to bypass the internal HD and use the external as my main HD. Is there a way to do that? Can I easily migrate what I have on the Internal drive to the external? Answers ar