[PHP] Stupid Question Alert - part 2

2002-01-07 Thread tim at 10Kv

Thanks for everyone's comments. If I understand what you are saying it
should be possible to fill the content of a layer by issuing some sort of
server include command.. (?)  So, for example, rather than have a something
that looks like this:

div id=haiti style=position:absolute; left:752px; top:321px;
width:166px; height:162px; z-index:14; visibility: hidden
  table width=166 border=0 cellpadding=0 cellspacing=0
tr 
  td img src=Atlas/images/photolayer_11.gif width=81
height=55/td
  td img src=Atlas/images/photolayer_12.gif width=85
height=55/td
/tr
tr 
  td img src=Atlas/images/photolayer_14.gif width=81
height=53/td
  td img src=Atlas/images/photolayer_15.gif width=85
height=53/td
/tr
tr 
  td img src=Atlas/haiti_17.gif width=81 height=55/td
  td img src=Atlas/haiti_18.gif width=85 height=55/td
/tr
  /table
/div

It should be possible to have some code that gives the layer position but
rather than then having all the other code describing the layer contents,
have some sort of php command that says 'get the contents from file
xxx.php'. If this is the case what should I be learning about to make this
happen?

Thanks again,

Tim

(standing on the shoulders of giants)

---


 Your question is not stupid - it's just uninformed, and that's easily
 understandable if you never used PHP.
 
 The concept is dynamically creating the page SERVER-SIDE. That is, use some
 databases or some nifty code to dynamically build a page using specific
 parameters. Unforunately for you, this means that all the fun ends on the
 server
 side. Once PHP ends its job, Apache takes over and serves the content
 generated
 by PHP as it would serve any regular file. What you actually pass to the
 client
 is dead information - it's not dynamic unless you echo some JavaScript code
 or
 something similar from PHP (which is the same as writing the respective code
 in
 a regular file, unless you create some custom parameters in JavaScript based
 on
 some other parameters you pass to PHP).
 
 Hope my explanation makes sense... ;-)
 
 Bogdan
 
 tim at 10Kv wrote:
 
 Hi,
 
 first of all apologise to the list ­ this is a very basic question for you
 I¹m sure. I have tried to find an answer on the web but the problem is
 knowing HOW to ask the question ­ and I hoping you can provide me with a
 starting point.
 
 Anyway.. I design a lot of graphic intensive pages which rely heavily on
 layers that contain images, mouseovers and image swaps. The trouble is, when
 there are more than a couple of these layers on a page the code gets long
 and over complicated.  For example, if I have a page which on one side
 contains an image map with 5 clickable points that shows one of 5 possible
 layers on the other side of the page  (each with different content)  this is
 automatically a page with lots of code which is slow to load ­ especially if
 the page already has a layer based navigation bar!
 
 My question is: is there a way to use a language like php to make this
 process easier? For example populate the layers from a different file rather
 than have all the code on the same page and perhaps slim the page down a
 little ­ or is this missing the point of what a language like php is about.
 
 Thanks for your help and my apologies if this is the worst question of the
 week.
 
 Tim Rogers
 


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]



[PHP] ... [PHP] Stupid question alert

2002-01-06 Thread tim at 10Kv


Thanks for everyone's comments. If I understand what you are saying it
should be possible to fill the content of a layer by issuing some sort of
server include command.. (?)  So, for example, rather than have a something
that looks like this:

div id=haiti style=position:absolute; left:752px; top:321px;
width:166px; height:162px; z-index:14; visibility: hidden
  table width=166 border=0 cellpadding=0 cellspacing=0
tr 
  td img src=Atlas/images/photolayer_11.gif width=81
height=55/td
  td img src=Atlas/images/photolayer_12.gif width=85
height=55/td
/tr
tr 
  td img src=Atlas/images/photolayer_14.gif width=81
height=53/td
  td img src=Atlas/images/photolayer_15.gif width=85
height=53/td
/tr
tr 
  td img src=Atlas/haiti_17.gif width=81 height=55/td
  td img src=Atlas/haiti_18.gif width=85 height=55/td
/tr
  /table
/div

It should be possible to have some code that gives the layer position but
rather than then having all the other code describing the layer contents,
have some sort of php command that says 'get the contents from file
xxx.php'. If this is the case what should I be learning about to make this
happen?

Thanks again,

Tim

(standing on the shoulders of giants)




 Your question is not stupid - it's just uninformed, and that's easily
 understandable if you never used PHP.
 
 The concept is dynamically creating the page SERVER-SIDE. That is, use some
 databases or some nifty code to dynamically build a page using specific
 parameters. Unforunately for you, this means that all the fun ends on the
 server
 side. Once PHP ends its job, Apache takes over and serves the content
 generated
 by PHP as it would serve any regular file. What you actually pass to the
 client
 is dead information - it's not dynamic unless you echo some JavaScript code
 or
 something similar from PHP (which is the same as writing the respective code
 in
 a regular file, unless you create some custom parameters in JavaScript based
 on
 some other parameters you pass to PHP).
 
 Hope my explanation makes sense... ;-)
 
 Bogdan
 
 tim at 10Kv wrote:
 
 Hi,
 
 first of all apologise to the list ­ this is a very basic question for you
 I¹m sure. I have tried to find an answer on the web but the problem is
 knowing HOW to ask the question ­ and I hoping you can provide me with a
 starting point.
 
 Anyway.. I design a lot of graphic intensive pages which rely heavily on
 layers that contain images, mouseovers and image swaps. The trouble is, when
 there are more than a couple of these layers on a page the code gets long
 and over complicated.  For example, if I have a page which on one side
 contains an image map with 5 clickable points that shows one of 5 possible
 layers on the other side of the page  (each with different content)  this is
 automatically a page with lots of code which is slow to load ­ especially if
 the page already has a layer based navigation bar!
 
 My question is: is there a way to use a language like php to make this
 process easier? For example populate the layers from a different file rather
 than have all the code on the same page and perhaps slim the page down a
 little ­ or is this missing the point of what a language like php is about.
 
 Thanks for your help and my apologies if this is the worst question of the
 week.
 
 Tim Rogers
 


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] Stupid question alert

2002-01-04 Thread tim at 10Kv

Hi, 

first of all apologise to the list ­ this is a very basic question for you
I¹m sure. I have tried to find an answer on the web but the problem is
knowing HOW to ask the question ­ and I hoping you can provide me with a
starting point.

Anyway.. I design a lot of graphic intensive pages which rely heavily on
layers that contain images, mouseovers and image swaps. The trouble is, when
there are more than a couple of these layers on a page the code gets long
and over complicated.  For example, if I have a page which on one side
contains an image map with 5 clickable points that shows one of 5 possible
layers on the other side of the page  (each with different content)  this is
automatically a page with lots of code which is slow to load ­ especially if
the page already has a layer based navigation bar!

My question is: is there a way to use a language like php to make this
process easier? For example populate the layers from a different file rather
than have all the code on the same page and perhaps slim the page down a
little ­ or is this missing the point of what a language like php is about.

Thanks for your help and my apologies if this is the worst question of the
week.

Tim Rogers



Re: [PHP] Stupid question alert

2002-01-04 Thread Bogdan Stancescu

Your question is not stupid - it's just uninformed, and that's easily
understandable if you never used PHP.

The concept is dynamically creating the page SERVER-SIDE. That is, use some
databases or some nifty code to dynamically build a page using specific
parameters. Unforunately for you, this means that all the fun ends on the server
side. Once PHP ends its job, Apache takes over and serves the content generated
by PHP as it would serve any regular file. What you actually pass to the client
is dead information - it's not dynamic unless you echo some JavaScript code or
something similar from PHP (which is the same as writing the respective code in
a regular file, unless you create some custom parameters in JavaScript based on
some other parameters you pass to PHP).

Hope my explanation makes sense... ;-)

Bogdan

tim at 10Kv wrote:

 Hi,

 first of all apologise to the list ­ this is a very basic question for you
 I¹m sure. I have tried to find an answer on the web but the problem is
 knowing HOW to ask the question ­ and I hoping you can provide me with a
 starting point.

 Anyway.. I design a lot of graphic intensive pages which rely heavily on
 layers that contain images, mouseovers and image swaps. The trouble is, when
 there are more than a couple of these layers on a page the code gets long
 and over complicated.  For example, if I have a page which on one side
 contains an image map with 5 clickable points that shows one of 5 possible
 layers on the other side of the page  (each with different content)  this is
 automatically a page with lots of code which is slow to load ­ especially if
 the page already has a layer based navigation bar!

 My question is: is there a way to use a language like php to make this
 process easier? For example populate the layers from a different file rather
 than have all the code on the same page and perhaps slim the page down a
 little ­ or is this missing the point of what a language like php is about.

 Thanks for your help and my apologies if this is the worst question of the
 week.

 Tim Rogers


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[Fwd: [PHP] Stupid question alert]

2002-01-04 Thread Bogdan Stancescu

(Inadvertedly only sent to me)

---BeginMessage---

Object and events that occur in the browser window are controlled by
client-side scripts (JavaScript, VB).

Objects and events that occur on the server are controlled by server-side
scripts (PHP, ASP, etc.)

Since PHP is a server-side scripting language it can not react to
client-side events (onClick, onMouseOver, etc.) or access client-side
objects (window, document, etc.). So it's impossible to get PHP (or any
other server-side scripting language) to reduce the amount of code needed
for client-side interactions (your images swaps and mouseovers).

what u can do is put all the scripts in an external .js file and reduce the
size of the file by removing white spaces (spaces, tabs, line
feeds/carriage returns). i'm not sure if this would significantly reduce ur
file size but it's an option.

CJ


 - Original Message -
From: Bogdan Stancescu [EMAIL PROTECTED]
Newsgroups: php.general
To: tim at 10Kv [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: Friday, January 04, 2002 6:17 PM
Subject: Re: [PHP] Stupid question alert


 Your question is not stupid - it's just uninformed, and that's easily
 understandable if you never used PHP.

 The concept is dynamically creating the page SERVER-SIDE. That is, use
some
 databases or some nifty code to dynamically build a page using specific
 parameters. Unforunately for you, this means that all the fun ends on the
server
 side. Once PHP ends its job, Apache takes over and serves the content
generated
 by PHP as it would serve any regular file. What you actually pass to the
client
 is dead information - it's not dynamic unless you echo some JavaScript
code or
 something similar from PHP (which is the same as writing the respective
code in
 a regular file, unless you create some custom parameters in JavaScript
based on
 some other parameters you pass to PHP).

 Hope my explanation makes sense... ;-)

 Bogdan

 tim at 10Kv wrote:

  Hi,
 
  first of all apologise to the list ­ this is a very basic question for
you
  I¹m sure. I have tried to find an answer on the web but the problem is
  knowing HOW to ask the question ­ and I hoping you can provide me with a
  starting point.
 
  Anyway.. I design a lot of graphic intensive pages which rely heavily on
  layers that contain images, mouseovers and image swaps. The trouble is,
when
  there are more than a couple of these layers on a page the code gets
long
  and over complicated.  For example, if I have a page which on one side
  contains an image map with 5 clickable points that shows one of 5
possible
  layers on the other side of the page  (each with different content)
this is
  automatically a page with lots of code which is slow to load ­
especially if
  the page already has a layer based navigation bar!
 
  My question is: is there a way to use a language like php to make this
  process easier? For example populate the layers from a different file
rather
  than have all the code on the same page and perhaps slim the page down a
  little ­ or is this missing the point of what a language like php is
about.
 
  Thanks for your help and my apologies if this is the worst question of
the
  week.
 
  Tim Rogers



---End Message---

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]