Welcome to TalkGraphics.com
Results 1 to 5 of 5
  1. #1
    Join Date
    Oct 2010
    Location
    Central Pennsylvania
    Posts
    53

    Default Code after ending html tag?

    I have a php script that I'd like to add to XDPX9 and it requires me to insert a line of code after the ending html tag. I'd like to do this from within xara and not after exporting the html. Can this be done with a special name tag and placeholder?
    Thanks

  2. #2
    Join Date
    Aug 2000
    Location
    Placitas, New Mexico, USA
    Posts
    41,487

    Default Re: Code after ending html tag?

    Not that I am aware of but I am sure one of the members who are more savvy with HTML will have a suggestion.

  3. #3
    Join Date
    Dec 2000
    Location
    Hautes Pyrénées, France
    Posts
    5,083

    Default Re: Code after ending html tag?

    Not tested this but it should work, maybe...

    Put this in a placeholder at the bottom of your page:

    Code:
    <!-- I added this -->
    
     </div>
    </div>
    </div>
    <!--[if lt IE 7]><script type="text/javascript" src="index_htm_files/png.js"></script><![endif]-->
    </body>
    </html>
    
    <?php
    
    // your php script here
    
    ?> 
    
    <?php
    
    //everything below will be ignored by the browser
    
    // end of I added this
    Since the closing PHP tag in your placeholder is missing,the closing HTML inserted automatically by Xara is ignored by the browser.

    Just make sure the number of closing DIVs you put in your placeholder match the number created by Xara.

    If someone tried to make me dig my own grave I would say No.
    They're going to kill me anyway and I'd love to die the way I lived:
    Avoiding Manual Labour.

  4. #4
    Join Date
    Oct 2010
    Location
    Central Pennsylvania
    Posts
    53

    Default Re: Code after ending html tag?

    Thanks for the suggestion! I'm definitely going to play around with this. I never even thought of doing something like that

  5. #5
    Join Date
    Apr 2010
    Location
    Kildare, Ireland
    Posts
    906

    Default Re: Code after ending html tag?

    Similar to Franks suggestion but instead of using a placeholder you can try using Web Properties and put similar code as below into HTML Code (body) and you shouldn't need to worry about the closing divs for placeholders.

    Code:
    </body>
    </html>
    my code after html here
    <?php
    
    or my php code here
    
    // exit will stop rest of exported page being executed/outputted ie. xaras default </body></html>
    exit; 
    
    ?>
    XT-CMS - a self-hosted CMS for Xara Designers - Xara + CMS Demo with blog & ecommerce shopping cart system.

 

 

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •