BG cuts out chunk of code when opening php file

31 views
Skip to first unread message

Dominik Lenné

unread,
Oct 28, 2016, 12:15:25 PM10/28/16
to bluegriffon
Hi folks, 

the following code:

            <h4>Einzelveranstaltungen</h4>
            <table>
              <colgroup> <col width="35%"> <col width="40%"> <col width="25%">
              </colgroup>
              <tbody>
                <?php if(stillvalid(20,8,2016,10)): ?>
                <?php endif;
                   if(stillvalid(24,8,2016,10)): ?>
                <?php endif; 
                   if(stillvalid(27,8,2016,10)): ?>
                <?php endif; ?>
                <?php if(stillvalid(16,9,2016,19,30)): ?>
                <?php endif; ?>
                <?php if(stillvalid(24,9,2016)): ?>
                <?php endif; ?>
                <?php if(stillvalid(3,10,2016)): ?>
                <?php endif; ?>
                <?php if(stillvalid(9,10,2016)): ?>
                <?php endif; ?>
                <?php if(stillvalid(9,10,2016)): ?>
                <?php endif; ?>
                <?php if(stillvalid(16,10,2016)): ?>
                <tr>
                  <td>Fr., 14.- Sa., 16.10.</td>
                  <td><a href="worksh.php#shantidharma">Heart Dance Weekend</a></td>
                  <td>Shantidharma</td>
                </tr>
                <tr>
                  <td>Sa. 22.10.<br>
                    19.30 Uhr</td>
                  <td><a href="file:///C:/Users/dlenn/Mauz/Website/WebsiteSpiegel/abendgr.html#aum">Awareness
                      Understanding Meditation (AUM)</a></td>
                  <td>Mauz-AUM-Team</td>
                </tr>
                <?php endif; ?>
                <?php if(stillvalid(29,10,2016)): ?>
                <tr>
                  <td>Sa., 29.10.<br>
                  12 - 18 Uhr</td>
                  <td><a href="worksh.php#leelanandawgcfem">Wild Graceful Conscious Feminine</a></td>
                  <td>Irina Livija</td>
                </tr>
                <?php endif; ?>
                
                <?php if(stillvalid(31,10,2016,10)): ?>
                <tr>
                  <td>Mo., 31.10 - Di., 1.11.<br>
                  10 - 16 Uhr</td>
                  <td><a href="worksh.php#alexthaimassage">Thaimassage Workshop</a></td>
                  <td>Alexander Orth</td>
                </tr>
                <?php endif; ?>
                
                <?php if(stillvalid(4,11,2016,19,30)): ?>
                <tr>
                  <td>Fr., 4.11<br>
                  19.30 Uhr</td>
                  <td><a href="worksh.php#michaelekuhnoffenerabend">Liebe Leben - Offener Abend</a></td>
                  <td>Michaele Kuhn</td>
                </tr>
                <?php endif; ?>
                <?php if(stillvalid(5,11,16)): ?>
                <tr>
                <td>Sa, 5.11. - So,6.11.<br>10 - 18 Uhr</td><td><a href="worksh.php#learninglove">Learning Love - Presence &amp; vulnerability</a></td><td>Tabish &amp; Jayen</td>
                </tr>
                <?php endif; ?>
                
                <?php if(stillvalid(6,11,2016,19)): ?>
                <tr>
                  <td>So., 6.11.<br>
                 19 Uhr</td>
                  <td><a href="worksh.php#eifersuchtundmitfreude">Von der Eifersucht zur Mitfreude</a></td>
                  <td>Christopher Gottwald</td>
                </tr>
                <?php endif; ?>

                <?php if(stillvalid(20,11,2016)): ?>
                <tr>
                  <td>Sa., 19.11. & So., 20.11.<br>
                  10 Uhr</td>
                  <td><a href="worksh.php#monjaipurtanzworkshop">Tanz Dich frei!</a></td>
                  <td>Monjaipur</td>
                </tr>
                <?php endif; ?>

<?php 
$kuschelparty = '<tr><td>%s</td><td><a href="abendgr.html#kuschelparty">Kuschelparty</a></td><td>Monjaipur</td></tr>';
            if(stillvalid(19,11,16)) printf($kuschelparty,"<b>So,</b> 20.11.<br><b>15 Uhr</b>");
?>




looked like this after opening in BG and opening source view:

            <h4>Einzelveranstaltungen</h4>
            '; if(stillvalid(19,11,16)) printf($kuschelparty,"<b>So,</b> 20.11.<br>
            <b>15 Uhr</b>"); ?&gt;

All trailing PHP was ruined.

Any ideas?

Thx.

    
Message has been deleted

Dominik Lenné

unread,
Oct 28, 2016, 1:34:48 PM10/28/16
to bluegriffon
After some lengthy trials, i could limit the possible causes of the bug to the occurrence of HTML-tags within strings within quotes within php parts, i.e.

<?php
if(stillvalid(19,11,16)) printf($kuschelparty,"auch normaler text");
?>

works , while

<?php
if(stillvalid(19,11,16)) printf($kuschelparty,"<b>So,</b> 20.11.<br><b>15 Uhr</b>");
?>


breaks the BG interpretation of the code.

Reply all
Reply to author
Forward
0 new messages