Jump to content


Photo

page title function


  • Please log in to reply
2 replies to this topic

#1 Joe Gimeno

Joe Gimeno
  • New Members
  • Pip
  • Newbie
  • 2 posts

Posted 12 June 2006 - 05:53 PM

I am new to PHP and have tried hard to find a function that would return the title of the page in which the php script is contained.

Explanation....

I am using "jalbum" a skin generator program written in java to generate slide HTML pages for my images with a htt template.
Within the template I have my html code and the link to the css styles file. Now I want to insert a basic php script which will retrive the page title and send it to another php script for further processing. i.e. query the database so that the item(which happens to be the page title) information is retreived and put into a shopping cart ....among other things..
I would appreciate any help ...

Joseph

something like a summit button that calls another script and returns the page title of the calling script as an argument.....



#2 ober

ober
  • Staff Alumni
  • Advanced Member
  • 5,337 posts
  • LocationEast Coast, USA

Posted 12 June 2006 - 06:02 PM

That's a somewhat vague question as we don't know how the template interacts with your code and you haven't really told us where or how you store the page titles.

If it's as simple as pulling it from the database and you understand the PHP side of interacting with a database, I suggest you try to hack something up and post it.

Until then, it's hard for us to get a handle on how to attack the problem.

Info: PHP Manual


#3 Joe Gimeno

Joe Gimeno
  • New Members
  • Pip
  • Newbie
  • 2 posts

Posted 12 June 2006 - 07:04 PM

Further explanation....

there is no interaction . The template htt is written in java and it generates as many HTML pages as I have images.....
Each page has a unique name (the image name ext html).
There is no Databse interaction so far....strictly HTML

I can include a php script which will then be part of each page.

<HTML........
<Title ..............
<Head..................

Contents..........................
Image....................
Text info .....................
The script goes here............
<?php
$title="Title" from top of page
/* This script should retrive the "<Title>Image_name</title> to a variable $title and post it to another script with a submit button, for further processing"

The $title variable already exists in java but I don't know how to have php see it .
?>

</HTML>





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users