This question is not answered. Helpful answers available: 2. Correct answers available: 1.


Permlink Replies: 2 - Pages: 1 - Last Post: 16-May-2008 14:50 Last Post By: piran
piran

Posts: 2
Registered: 31-Mar-2008
How does PHP get interpreted as PHP inside HTM rendered by Java/Jalbum?
Posted: 16-May-2008 12:08
 
  Click to reply to this thread Reply
(as subject) Put another way I'm having difficulty
getting my PHP code snippets to function;~/
----best wishes, Robert
jGromit

Posts: 8,351
Registered: 31-Jan-2006
Re: How does PHP get interpreted as PHP inside HTM rendered by Java/Jalbum?
Posted: 16-May-2008 13:33   in response to: piran in response to: piran
 
  Click to reply to this thread Reply
This doesn't really have anything to do with Java or Jalbum. Jalbum produces normal, plain-vanilla HTML. Including PHP snippets in it is the same as including PHP snippets in any HTML file, even one you created by hand.

Google for execute PHP in HTML, and you'll find a number of discussions about various ways of doing this. A couple of quick options:

First option: put a .php extension on the file, and include your PHP snippet like this:

(html stuff)
 
<? include('mysnippet.php'); ?>
 
(more html stuff)

Second option: put a .shtml extension on the file, and include your PHP snippet like this:

<!--#include virtual="mysnippet.php"-->

This one requires server-side includes.
piran

Posts: 2
Registered: 31-Mar-2008
Re: How does PHP get interpreted as PHP inside HTM rendered by Java/Jalbum?
Posted: 16-May-2008 14:50   in response to: jGromit in response to: jGromit
 
  Click to reply to this thread Reply
EarlyOut----
...err, red-face time;~) Absolutely EVERYTHING like this I've
ALWAYS done on the server and pretty much always in PHP.
This 'ere Java/Jalbum thingummy is a new vector for me.
It's being done on a local workstation (w2k)... no interpreter.
More caffeine required and thanks for the wake up call;~)
----best wishes, Robert
Legend
Forum admins
Helpful Answer
Correct Answer

Point your RSS reader here for a feed of the latest messages in all forums