Conflicting Files ? Success

User tests: Successful: Unsuccessful:

avatar tkuschel
tkuschel
6 Apr 2016

Pull Request for:

  • With Eclipse IDE, it throws an error and a notice too
  • No need to escape apostrophes, and no concatenation in php
  • Opening and Closing
    will be found

since 3.5.0/3.5.1

Summary of Changes

1.) Moved a <div> out of php, so any editor finds the associated </div>
2.) Moved some strings out of a concatenation, then the tag <a> is closed properly.

Testing Instructions

Review the code

avatar tkuschel tkuschel - open - 6 Apr 2016
avatar tkuschel tkuschel - change - 6 Apr 2016
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 6 Apr 2016
Labels Added: ?
avatar brianteeman brianteeman - change - 6 Apr 2016
Category Code style
avatar tkuschel tkuschel - change - 6 Apr 2016
The description was changed
avatar tkuschel tkuschel - change - 6 Apr 2016
The description was changed
avatar RonakParmar
RonakParmar - comment - 25 Feb 2017

@tkuschel Please fix mentioned comment in PR and at the end there is an error of "No newline at end of file", fix this too.
So we can test it.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/9753.

avatar tkuschel tkuschel - change - 27 Feb 2017
The description was changed
avatar joomla-cms-bot joomla-cms-bot - change - 27 Feb 2017
Category Code style Layout Code style
avatar tkuschel
tkuschel - comment - 27 Feb 2017

I've merged this PR to the staging and did fix the mentioned comments above. I'm a little confused about "No newline at end of file", because in the actual Joomla coding standard, you'll find a "Files should always end with a blank new line." see 3rd paragraph in https://developer.joomla.org/coding-standards/php-code.html

avatar tkuschel tkuschel - change - 27 Feb 2017
Status Pending Closed
Closed_Date 0000-00-00 00:00:00 2017-02-27 08:03:28
Closed_By tkuschel
avatar tkuschel tkuschel - close - 27 Feb 2017
avatar tkuschel tkuschel - close - 27 Feb 2017
avatar tkuschel tkuschel - change - 27 Feb 2017
Status Closed New
Closed_Date 2017-02-27 08:03:28
Closed_By tkuschel
avatar tkuschel tkuschel - change - 27 Feb 2017
Status New Pending
avatar tkuschel tkuschel - reopen - 27 Feb 2017
avatar tkuschel tkuschel - reopen - 27 Feb 2017
avatar tkuschel
tkuschel - comment - 27 Feb 2017

@zero-24 : I already deleted the spaces on line 170, with the second update today. Please check again 3649bb1

avatar tkuschel
tkuschel - comment - 3 Mar 2017

@zero-24 please test again, I already did your requested changes, thank you.

avatar oe1tkt
oe1tkt - comment - 18 May 2017

This behavior still exists in Joomla 3.7.1

avatar Heggi93 Heggi93 - test_item - 21 Aug 2017 - Tested unsuccessfully
avatar Heggi93
Heggi93 - comment - 21 Aug 2017

I have tested this item ? unsuccessfully on a40b01e

The warnings/errors mentioned above are not shown any more but there are some warnings which may create errors for some reasons. Every attribute of a <div> should be distanced with a wide space from the others, e.g. in line 140 should be a space between _preview_img" and '. In line 141 is the same problem.

In common it is more comfortable to separate php and HTML-Code. Please avoid echo"<div>...</div>" or something like this. For example line 160-163 should stand in php-brackets instead of using echo. If this is not an option because you need the value of a php-variable you can use the shorter form of echo which is <?= $variable ?>. Line 160 to 163 can look like:

?>
<div class="media-preview add-on" style="height:auto">
<?= ' ' . $previewImgEmpty ?>
<?= ' ' . $previewImg ?>
</div>
<?php

If you try to write your code like this, you'll see that errors will be found more easily because HTML is clearly separated.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/9753.

avatar brianteeman
brianteeman - comment - 21 Aug 2017

@Heggi93 please read the code style rules before giving that advice

avatar SamuelSchepp SamuelSchepp - test_item - 22 Aug 2017 - Tested successfully
avatar SamuelSchepp
SamuelSchepp - comment - 22 Aug 2017

I have tested this item successfully on a40b01e

Without patch:

  • phpcs: Generic.Files.LineLength.TooLong: Line exceeds 150 characters; contains 217 characters
  • phpcs: Generic.WhiteSpace.ScopeIndent.IncorrectExact: Line indented incorrectly; expected 1 tabs, found 0
  • phpcs: Generic.Files.EndFileNewline.NotFound: File must end with a newline character
  • Start tag () not closed properly, expected '>'.

With patch:
Warnings from above are resolved.

But no merge possible. Tested via com_patchtester.
@icampus


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/9753.

avatar franz-wohlkoenig
franz-wohlkoenig - comment - 26 Oct 2017

@Heggi93 can you please retest?


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/9753.

avatar infograf768
infograf768 - comment - 26 Oct 2017

There are obvious errors in this patch.

avatar franz-wohlkoenig
franz-wohlkoenig - comment - 26 Oct 2017

@infograf768 you mean conflicting Files?

avatar infograf768
infograf768 - comment - 26 Oct 2017

Not only. See comment above.

avatar brianteeman
brianteeman - comment - 8 May 2018

It has been a year since the last update and there are conflicts. I am going to close this at this time - it can always be reopened if updated

avatar brianteeman brianteeman - change - 8 May 2018
Status Pending Closed
Closed_Date 0000-00-00 00:00:00 2018-05-08 22:31:57
Closed_By brianteeman
Labels Added: Conflicting Files
avatar brianteeman brianteeman - close - 8 May 2018

Add a Comment

Login with GitHub to post a comment