Author Topic: URL Mappings syntax  (Read 8884 times)

RobFreundlich

  • Community Member
  • Posts: 47
  • Hero Points: 2
URL Mappings syntax
« on: July 02, 2007, 12:31:52 PM »
I'm trying to set up URL mappings so that SE doesn't have to go out to the web every time I open an XML file.  I can't seem to get the syntax right in the dialog, though.  Suppose I've got an XML file with the following:

<web-app version="2.4"
         xmlns="http://java.sun.com/xml/ns/j2ee"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">

and I've got web-app_2_4.xsd in my c:\dev\tools\dtd directory.  What are the correct From and To values in the URL Mappings dialog?



Suppose I've got this:

<!DOCTYPE tiles-definitions PUBLIC
      "-//Apache Software Foundation//DTD Tiles Configuration 1.1//EN"
      "http://struts.apache.org/dtds/tiles-config_1_1.dtd">

with the dtd in my c:\dev\tools\dtd directory.  Again, what's the correct values?


Is there any way I can just say "look in c:\dev\tools\dtd" for all dtd's and xsd's?

Matthew

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 990
  • Hero Points: 44
Re: URL Mappings syntax
« Reply #1 on: July 05, 2007, 01:33:51 PM »
Quote
What are the correct From and To values in the URL Mappings dialog?
Two ways:

Quote
Is there any way I can just say "look in c:\dev\tools\dtd" for all dtd's and xsd's?
I've wanted this myself, and it's in our feature planning for v.next.

And since you asked, how would you like the feature to work? I've been thinking that you just drop your .xsd files in a directory, and SE would just scan each file for the targetNamespace="url" attribute to determine the mappings.

buggyfunbunny

  • Senior Community Member
  • Posts: 233
  • Hero Points: 4
Re: URL Mappings syntax
« Reply #2 on: July 05, 2007, 04:58:38 PM »
For dtd(s), one directory is OK, likely (assuming that one isn't defining them in an application).  xsd(s) are another matter, since applications can have them of the same name, but different versions.  Most of ours do now.

RobFreundlich

  • Community Member
  • Posts: 47
  • Hero Points: 2
Re: URL Mappings syntax
« Reply #3 on: July 05, 2007, 08:14:04 PM »
Quote
Is there any way I can just say "look in c:\dev\tools\dtd" for all dtd's and xsd's?
I've wanted this myself, and it's in our feature planning for v.next.

And since you asked, how would you like the feature to work? I've been thinking that you just drop your .xsd files in a directory, and SE would just scan each file for the targetNamespace="url" attribute to determine the mappings.

That'd work great for me - I put all of mine in a specific directory, so being able to just name that directory would be perfect.