This repository was archived by the owner on Dec 15, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 124
This repository was archived by the owner on Dec 15, 2022. It is now read-only.
Extremely long lines followed by HTML breaks highlighting #362
Copy link
Copy link
Open
Description
Prerequisites
- [ X ] Put an X between the brackets on this line if you have done all of the following:
- Reproduced the problem in Safe Mode: https://flight-manual.atom.io/hacking-atom/sections/debugging/#using-safe-mode
- Followed all applicable steps in the debugging guide: https://flight-manual.atom.io/hacking-atom/sections/debugging/
- Checked the FAQs on the message board for common solutions: https://discuss.atom.io/c/faq
- Checked that your issue isn't already filed: https://github.com/issues?utf8=✓&q=is%3Aissue+user%3Aatom
- Checked that there is not already an Atom package that provides the described functionality: https://atom.io/packages
Description
The syntax of some parts of php code is not highlighted correctly, specifically it highlights the html code contained in the string and not the string itself
Steps to Reproduce
- open a blank php file and paste the following code:
<?php
echo '
<td id="card'.$row2["ID"].'" data-open="card" data-cardid="'.$row2["ID"].'" class="card editable" style="width: '.(100/$row2["Tipo"]).'%; '.($i == $result2->num_rows - 1 ? "margin-bottom: 0px !important;" : "").' '.($row2["Foto"] == 1 ? '' : 'min-height: auto !important;').'">
<table style="'.$stile_card_contenuto.' '.($row2["Foto"] == 1 ? '' : 'background-color: transparent !important;').'">
'.($row2["Foto"] == 1 ? '
<tr>
<td style="background-image: url('.$row2["UrlPhoto"].'); background-position: center center; '.$stile_card.'">
</td>
</tr>
' : '').'
'.($row2["Testo"] != "" ? '
<tr>
<td style="'.$stile_text.' '.($row2["Foto"] == 1 ? '' : 'text-align: center !important; font-size: 22px !important;').'">
<span class="title" style="'.$stile_titolo_fascia.'">'.$row2["Titolo"].'</span><br>
'.str_replace(" ", " ", $row2["Testo"]).'
</td>
</tr>
' : '').'
'.($row2["Bottone"] == 1 ? '
<tr>
<td style="padding: 0px; height: 31px; '.($row2["Foto"] == 1 ? 'text-align: right;' : 'text-align: center !important;').'">
<div style="padding: 15px; padding-left: 0px; padding-top: 10px;">
<a href="'.str_replace("{{keyword}}", $id_newsletter, attachUtm($riga["Utm"], $row2["UrlBottone".$url_lang], $riga["Lingua"])).'" class="inbox_button" style="'.$stile_card_bottone.' '.($row2["Foto"] == 1 ? 'text-align: right;' : 'font-size: 20px !important;').'">
'.$row2["TestoBottone"].'
</a>
</div>
</td>
</tr>
' : '').'
</table>
</td>
';
?>
sorry if the code is not displayed correctly, I also upload it as an attached file along with the screenshot
- in the fifth line of the code the syntax highlighting of the string is incorrect
Expected behavior:
the color of the fifth line should be green because it's part of a string
Actual behavior:
the string in the fifth line highlight the html code contained in the string
Reproduces how often:
I tried several times and it happened 100% of the time
Versions
Atom : 1.38.1
Electron: 2.0.18
Chrome : 61.0.3163.100
Node : 8.9.3