Closed nilshoerrmann closed 12 years ago
I assume you want to be able to select the view as well?
for instance by using ?xml=data
and ?xml=result
What the XML result? The output after the XSL transformation?
yes, indeed. Basically the same as the current available XML and Result views.
Is there a way to assign an issue to a non-member of a project / repository?
CC: @brendo, @nickdunn
Alright, so here is an initial implementation.
Instead of creating the ?xml
parameter, I've added a small box in the upper right corner and some javascript to enable switching between views.
Raw XML view:
Code Highlighted view:
Right now the styling of the raw view is the same as the highlighted, but I guess this should change to white background, black letters, no highlighting.
I've also added support for the XPath and Tag matchers, but perhaps this is not necessary in XML view mode?
BTW: while working on this issue I began to wonder what is the use case.. At first I thought it would be to enable easy copy-paste of XML, but this is already possible in the current highlighted view. Why would you want to have a basic non-formated XML view?
I think this is a misunderstanding: I was talking about the plain XML source sent with an XML mime type and no surrounding UI. If this source was accessible under a direct link, it would be possible to remotely load the data into a desktop application that offers your syntax highlighting of choice and enables code folding.
yeah, after rereading the inital feature request I indeed saw where I went wrong... I will add the ?xml
option with correct mime-type.
That's very kind. Thanks!
Sorry it's taken so long to review this.
@remie Your implementation slightly breaks the convention. The Debug/Profile Devkits operate under the same $_GET
namespace and use parameter values to determine the content (eg. ?debug=params
shows the parameters). This commit adds a new one, ?xml
, which is not a reserved $_GET
variable from Symphony's point of view and may cause some issues in other parts of the system. The convention would be ?debug=xml
(but that's taken), so how about ?debug=raw
?
I'm also uncertain about the idea of displaying the result, (xml + xslt) as XML as my feeling is that this can be accomplished with the XML
page type and shouldn't be part of the Debug Devkit.
@brendo: I'm fine with the ?debug=raw
, I was just following the feature request made by Nils. Do you want me to adjust this?
Yes please.
Bump @remie :) Would love to have this ready for the 2.3 Beta 3 this weekend.
If you won't be able to get to it that's fine just let me know and I'll jump on it.
@brendo: I'll be happy to do this!
It's my feature request day (sorry!): It would be nice if this devkit would return the plain XML source of the current page when appending
?xml
to the URL (no UI and highlighting, just XML).