Hm. Anyone on my f-list know how to set up the .php code for a 'rotating' set of banners on a regular webpage? Anyone on my f-list know how to explain to me how to set up the .php code for a 'rotating' set of banners on a regular webpage?
Whereby you insert this code where the image goes, you change the extension to whatever image type you are using, and the images in the rotation are numbered from 1-10 and placed in the same folder as the file containing this script. Of course, this has to be a .php file for this to work...
If you have another code in mind, let me have it and I might be able to help you with that...
Okay, I admit to knowing very little about .php scripts and how they work.
(I should probably research this. I just wanted a rotating banner and knew that .php code was involved somehow.)
I'm presuming that .php works in concert with html, rather than instead of html, mostly because I'm a lazy ass and don't want to completely recode my pages. Under this assumption, at some point in the html page code, a .php script would be declared, and the script is stored in the same directory as the .html file for the page.
the images in the rotation are numbered from 1-10
So it would be 1.jpg, 2.jpg...etc? Or could you call it header1.jpg, header2.jpg...etc and then tell the script to look for a file called "headern.jpg"?
Files can be a combination of HTML and PHP, however, for this code to work, all the pages need the extention .php rather than .html. No recoding is necessary - you'd just put this code in the HTML where the existing image is.
There are ways to do it with scripts that are linked in - these are more flexible - however they still require a .php extension to run since they use an include to make the script execute.
Ergo, whichever way you do it, to use PHP to do this, you have a lot of extension renaming in your future.
Whereby you insert this code where the image goes, you change the extension to whatever image type you are using, and the images in the rotation are numbered from 1-10 and placed in the same folder as the file containing this script. Of course, this has to be a .php file for this to work...
If you have another code in mind, let me have it and I might be able to help you with that...
Okay, I admit to knowing very little about .php scripts and how they work.
(I should probably research this. I just wanted a rotating banner and knew that .php code was involved somehow.)
I'm presuming that .php works in concert with html, rather than instead of html, mostly because I'm a lazy ass and don't want to completely recode my pages. Under this assumption, at some point in the html page code, a .php script would be declared, and the script is stored in the same directory as the .html file for the page.
the images in the rotation are numbered from 1-10
So it would be 1.jpg, 2.jpg...etc? Or could you call it header1.jpg, header2.jpg...etc and then tell the script to look for a file called "headern.jpg"?
Files can be a combination of HTML and PHP, however, for this code to work, all the pages need the extention .php rather than .html. No recoding is necessary - you'd just put this code in the HTML where the existing image is.
There are ways to do it with scripts that are linked in - these are more flexible - however they still require a .php extension to run since they use an include to make the script execute.
Ergo, whichever way you do it, to use PHP to do this, you have a lot of extension renaming in your future.
no subject
Whereby you insert this code where the image goes, you change the extension to whatever image type you are using, and the images in the rotation are numbered from 1-10 and placed in the same folder as the file containing this script. Of course, this has to be a .php file for this to work...
If you have another code in mind, let me have it and I might be able to help you with that...
no subject
(I should probably research this. I just wanted a rotating banner and knew that .php code was involved somehow.)
I'm presuming that .php works in concert with html, rather than instead of html, mostly because I'm a lazy ass and don't want to completely recode my pages. Under this assumption, at some point in the html page code, a .php script would be declared, and the script is stored in the same directory as the .html file for the page.
the images in the rotation are numbered from 1-10
So it would be 1.jpg, 2.jpg...etc? Or could you call it header1.jpg, header2.jpg...etc and then tell the script to look for a file called "headern.jpg"?
no subject
There are ways to do it with scripts that are linked in - these are more flexible - however they still require a .php extension to run since they use an include to make the script execute.
Ergo, whichever way you do it, to use PHP to do this, you have a lot of extension renaming in your future.
no subject
Eek. *rethinks this*
no subject
no subject
no subject
You could probably folderise by adding folder/ before the PHP code in the img attribute.
no subject
JavaScript (http://javascript.internet.com/miscellaneous/rotating-banner.html)
no subject
no subject
no subject
Whereby you insert this code where the image goes, you change the extension to whatever image type you are using, and the images in the rotation are numbered from 1-10 and placed in the same folder as the file containing this script. Of course, this has to be a .php file for this to work...
If you have another code in mind, let me have it and I might be able to help you with that...
no subject
(I should probably research this. I just wanted a rotating banner and knew that .php code was involved somehow.)
I'm presuming that .php works in concert with html, rather than instead of html, mostly because I'm a lazy ass and don't want to completely recode my pages. Under this assumption, at some point in the html page code, a .php script would be declared, and the script is stored in the same directory as the .html file for the page.
the images in the rotation are numbered from 1-10
So it would be 1.jpg, 2.jpg...etc? Or could you call it header1.jpg, header2.jpg...etc and then tell the script to look for a file called "headern.jpg"?
no subject
There are ways to do it with scripts that are linked in - these are more flexible - however they still require a .php extension to run since they use an include to make the script execute.
Ergo, whichever way you do it, to use PHP to do this, you have a lot of extension renaming in your future.
no subject
Eek. *rethinks this*
no subject
no subject
no subject
You could probably folderise by adding folder/ before the PHP code in the img attribute.
no subject
JavaScript (http://javascript.internet.com/miscellaneous/rotating-banner.html)
no subject
no subject