• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Dealing with URLs length
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Dealing with URLs length


  • Subject: Re: Dealing with URLs length
  • From: Chuck Hill <email@hidden>
  • Date: Tue, 10 Oct 2006 13:07:31 -0700


On Oct 9, 2006, at 9:06 AM, Cantin Benoit wrote:

Dear WO users,

I am dealing with my applications URL length. For different reasons, it can't be longer than 100 characters. So I am wondering how to shorten my URLs but :
- without using Apache rewrite_mod ;
- and without modifying my Direct Actions names.

Those are some severe restrictions.

Is there a way to remove /cgi-bin/WebObjects/my_app_name.woa from WebObjects applications default URL with these constraints ?

You can't remove all of it. You can shorten /cgi-bin/ and / my_app_name.woa to something like
/w/WebObjects/a.woa



I have read that you can change cgi-bin in /System/Library/ WebObjects/Adaptors/Apache/apache.conf, but that you can't remove / WebObjects/. Is that true ? Are there any other ways to do it ?

You can do it, but you need to edit the adaptor source to do so. That might be more effort than it is worth to get rid of 9 characters.
/w/o/a.woa
You would also need to create a WOContext subclass or use some other method to generate the URLs.


Some other ideas:

1. Make aliases for direct actions:

public WOActionResults mrlnAction() {
    return myRatherLongNameAction();
}

So you can use a.woa/wa/mrln instead of a.woa/wa/myRatherLongName but both will still work

2. Use cookies to store the session ID and instance number if you are not doing this already.


Chuck


--

Practical WebObjects - for developers who want to increase their overall knowledge of WebObjects or who are trying to solve specific problems. http://www.global-village.net/products/practical_webobjects





_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: Dealing with URLs length
      • From: Miguel Arroz <email@hidden>
References: 
 >Dealing with URLs length (From: Cantin Benoit <email@hidden>)

  • Prev by Date: Re: Detecting eo changes when they happen
  • Next by Date: Re: Dealing with URLs length
  • Previous by thread: Dealing with URLs length
  • Next by thread: Re: Dealing with URLs length
  • Index(es):
    • Date
    • Thread