![]() |
|
Welcome to the Computer Webmaster Gaming Console Graphics Forum forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact contact us. |
| |||||||
| PHP PHP for some can be one of the hardest website programming codes, so do you need help on your PHP script, if it is php4, php5 or lower this is the place for you for any PHP help. |
![]() |
| | LinkBack | Thread Tools | Display Modes |
| | #1 | ||
| i realise that this may not be a php realted question and i apologise before i begin.. I have a site header and footer that i include in all my pages. They both have pictures in them that are stored in the pictures folder. these are found using <img src="./pictures/picturename.jpg"> This is fine for all the pages in the root directory, but when i login and it takes me to pages in the admin directory (or any other directory) when the site_header or site_footer are displayed all the pictures are broken. the structure is like this ROOT Pictures Administration Adminmenu Users etc I guess its to do with the directory structure and that it changes the link source as you change down directories.. but i just cant figure out how to fix it... as all i really want is to be able to include a header and footer file in all pages. I spose i could do it if i include the pics under the root directory rather than in a pics directory but i was hoping not to do that. Jake | |||
|
| Advertisements |
| | #2 | ||
| "Jake" <jgriffi1@bigpond.net.au> wrote: > i realise that this may not be a php realted question and i apologise > before i begin.. I have a site header and footer that i include in > all my pages. They both have pictures in them that are stored in the > pictures folder. these are found using <img > src="./pictures/picturename.jpg"> > > This is fine for all the pages in the root directory, but when i login > and it takes me to pages in the admin directory (or any other > directory) when the site_header or site_footer are displayed all the > pictures are broken. <img src="/pictures/picturename.jpg"> JOn | |||
|
| | #3 | ||
| You can use images-urls in such way <IMG src="<?=$PATH2ROOT?>/images/image1.jpg"> where $PATH2ROOT - address from this directory to the root directory For examle: "../../" In the begin of yours script (before including header or footer) set $PATH2ROOT = "yours path to root from this directory"; "Jake" <jgriffi1@bigpond.net.au> wrote in message news:3f0cf690@news.comindico.com.au... > i realise that this may not be a php realted question and i apologise before > i begin.. I have a site header and footer that i include in all my pages. > They both have pictures in them that are stored in the pictures folder. > these are found using <img src="./pictures/picturename.jpg"> > > This is fine for all the pages in the root directory, but when i login and > it takes me to pages in the admin directory (or any other directory) when > the site_header or site_footer are displayed all the pictures are broken. > > the structure is like this > ROOT > Pictures > Administration > Adminmenu > Users > > etc > I guess its to do with the directory structure and that it changes the link > source as you change down directories.. but i just cant figure out how to > fix it... as all i really want is to be able to include a header and footer > file in all pages. I spose i could do it if i include the pics under the > root directory rather than in a pics directory but i was hoping not to do > that. > > Jake > > | |||
|
| Featured Websites | ||||
|
![]() |
| Tags: broken, help, links |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Broken Borders. | sTony | CSS | 0 | 07-01-2007 2:17 PM |
| Looks like mine's broken already :( | Alai | New Users Help And FAQ | 10 | 06-26-2007 10:24 AM |
| Broken keyboard pin | Yojimbo | Motherboards | 1 | 06-11-2007 1:09 PM |
| Broken 360 out of warranty | cNp | Console Subjects | 18 | 06-11-2007 9:59 AM |
| Is Google... broken? (it seems to be, how can I fix?) | Rob | Google questions | 0 | 05-28-2007 1:46 AM |
| Featured Websites | ||||
|