The XML Transform module enables you to store XML content in a node body and use the drupal built-in filter system to transform it with a pre configured XSLT stylesheet of your choice. It also provides optional XML input (on-submit) checks for well-formedness and schema-validation.

XML Transform

CommentFileSizeAuthor
#11 xml_transform.txt13.65 KBweebpal

Comments

donpwinston’s picture

Title: Plee Review XML Transform » Please Review XML Transform
donpwinston’s picture

patrickd’s picture

Title: Please Review XML Transform » XML Transform
Status: Needs review » Needs work

welcome,

we got about 150 applications in the queue, all of them want a review, you don't have to put it into the title ;-)

You are working in the "master" branch in git. You should really be working in a version specific branch. The most direct documentation on this is Moving from a master branch to a version branch. For additional resources please see the documentation about release naming conventions and creating a branch in git.

Please take a moment to make your project page follow tips for a great project page.

Please remove the LICENSE.txt file. Drupal will add the appropriate version automatically during packaging so your repository should not include it.

while waiting for an in-depht review of your module you can start out fixing some coding style issues detected by automated tools:
http://ventral.org/pareview/httpgitdrupalorgsandboxdonpwinston1476774git

You can also get a review bonus and we will come back to your application sooner.

regards

patrickd’s picture

Assigned: donpwinston » Unassigned

oh, yes and only reviewers should assign themselfs (so 2 reviewers won't do the same work twice).

donpwinston’s picture

ok.

thanks

donpwinston’s picture

Done.

donpwinston’s picture

Status: Needs work » Needs review

First time, so might have missed a few things..

donpwinston’s picture

Status: Needs review » Needs work

I'm not saving the filter settings properly although it sort of works as is.

donpwinston’s picture

Status: Needs work » Postponed (maintainer needs more info)

I think I've found some Drupal documentation that will help me code the filter settings properly. I'll resubmit it for review later.

donpwinston’s picture

Status: Postponed (maintainer needs more info) » Needs review

Figured out how to code the admin settings for a filter properly. It's a little different then the ordinary admin settings. Unlike the Drupal 6 version you do not use the variable_set/get functions! Also, had to make significant changes from the Drupal 6 version to implement xml validation. I think it's ok now. (I will test it some more over the next couple of days)

I could not find any other modules that do this. I think this could be very useful if you had a lot of xml content to load into Drupal. You just load it and create a stylesheet for each kind of xml data. Or you could have different formats for the same kind of data for whatever reason (like a summary or selections of specific item(s)).

weebpal’s picture

Status: Needs review » Needs work
StatusFileSize
new13.65 KB

Review of the 7.x-1.x branch:

This automated report was generated with PAReview.sh, your friendly project application review script. You can also use the online version to check your project. Get a review bonus and we will come back to your application sooner.

donpwinston’s picture

Status: Needs work » Fixed

prefixed all function names with the module name.

The so called code "style" issues are silly and defeat the purpose of using PHP. I'm not doing most of these. (It looks like many of the "ERRORS" in the automated error checker are not correct for whatever reason. For example it complains about tabs and whitespace after an end of line character).

klausi’s picture

You need to set the status to needs review if you want to get a review, see http://drupal.org/node/532400

You have not listed any reviews of other project applications in your issue summary as strongly recommended here: http://drupal.org/node/1011698

patrickd’s picture

Status: Fixed » Needs review
donpwinston’s picture

Status: Needs review » Closed (works as designed)

"You have not listed any reviews of other project applications in your issue summary as strongly recommended here:"

Don't know what this means. Why I should I "list reviews of other project applications"? I don't believe I have any to list.

This is "finished".

patrickd’s picture

You have not listed any reviews of other project applications in your issue summary as strongly recommended here

We have a huge lack of reviewers, this sentence only says that we recommend reviewing other application so yours get higher priority.

Are you closing because your giving up on this ? :(
I'm very sorry for delay, hope you come another time

donpwinston’s picture

Status: Closed (works as designed) » Needs review

No, I'm not complaining about a delay. I just didn't understand what they're talking about. I think this is more or less "done".

donatasp’s picture

Status: Needs review » Needs work

donpwinston, your project looks good, but if you want an in-depth review and approval, you'll have to fix indentation, comments, and other syntax issues described in http://ventral.org/pareview/httpgitdrupalorgsandboxdonpwinston1476774git . Drupal has codings standards and contributed modules are expected to follow them if they are to be hosted on drupal.org.

You should also expand your README file (see https://drupal.org/node/447604 ), follow tips ( https://drupal.org/node/997024 ) to make your sandbox project page better.

patrickd’s picture

Status: Needs work » Needs review

Note that many of the issues found are minor and should not be required for approval, therefore please do not insist on having them fixed and do not switch the issue to needs work if there are no major issues found.

donpwinston’s picture

ok, maybe when I get some time I'll polish this up. I'm not big on "indentation" and other code presentation things.

misc’s picture

Assigned: Unassigned » misc

Doing a manual review, and assigning this to myself, will get back soon.

misc’s picture

Issue tags: +PAreview: security

Manual review:

.gitignore
Please remove the .gitignore file form the repo
Minor: Avoid adding HTML to t()
In the xml_transform_help you adding a lot of html-tags and runt them through t(), you should avoid that
Minor: Implements, not Implementation of
It should be Implements hook_filter_info, not Implementation of hook_filter_info
Minor: Coding style make it hard to read
Your coding style make it hard to read the code and manually validate it, you should really follow the coding standards - if you do so it will be much easier to find security issues and get users to contribute with patches etc.
Defaults to language none?
In xml_transform_node_validate, you have $format = $node->body['und'][0]['format'], why?
Untranslated strings
In xml_transform_libxml_errors_html, you have strings which are not run though t().
Minor: New line is missing
Missing new line in the end of .module could be a problem, please add a finishing new line

And one important issue here, how are you handling the security? There are some big security risks here. You are not adding any permissions, and you do not filter the xml file, or am I missing something?

misc’s picture

Status: Needs review » Needs work

Forgot to change status.

misc’s picture

Assigned: misc » Unassigned

And unassigning myself...

donpwinston’s picture

Should I use some function to get the appropriate language?

field_language()?

It's just validating the xml/xsl. The actual content does not matter.

klausi’s picture

Status: Needs work » Closed (won't fix)

Closing due to lack of activity. Feel free to reopen if you are still working on this application.