Create new page? |
[eluser]eperez[/eluser]
A friend create a website for some software I made, towards the beginning of the year. Since I'm not a web developer, I'm having a hard time figuring everything out. I'm trying to create a new web page. And in doing so, I just copy the code I've seen everywhere else through out the site, but with the new page's name. But that didn't work. If I wanted to create a link to the "download.php" page, all I'd have to do is create an anchor with that name, but without ".php." Code: a href="download"Download And if I wanted to link to my FAQ page, I'd do the same, but also put "info" in there since it's within the "info" folder on my server: Code: a href="info/faq"FAQ So, copied one of the pages, renamed it to "albums.php" and put it in the "info" folder. I then created an anchor for it: Code: a href="info/albums"Photo Albums But all I get is a 404 when I click the link. So, I thought there was maybe another file somewhere on the server that handled the URIs like this. I've been through a couple that appeared to be what I was looking for, like "routes.php" and "url_helper.php." But after looking through these files, I didn't see any thing that the original guy would have coded, in order to link URIs together. Anyone have any ideas?
[eluser]theprodigy[/eluser]
Make sure your 'albums.php' file contains at a minimum code that looks like: Code: <?php
[eluser]eperez[/eluser]
[quote author="theprodigy" date="1306116334"]Make sure your 'albums.php' file contains at a minimum code that looks like: Code: <?php theprodigy, Thanks for the information. I'll try that, but none of my other pages are extending any controllers. You can take a look at the source of of pages here: http://avertsoftware.com/download
[eluser]theprodigy[/eluser]
I can't view server side code through the browser.
[eluser]eperez[/eluser]
[quote author="theprodigy" date="1306118188"]I can't view server side code through the browser.[/quote] I was just referring to the HTML code. If there's a particular document you need to see, I can upload it. I'm looking through all of the pages in the "controllers" folder and found the "info.php." Within the main folder, this file is just a normal webpage, but within this one, it contains the following code: Code: <?php This looks like what I'm looking for. I'm going to play around with it to see what I get.
[eluser]eperez[/eluser]
Eureka! That's what did it. I bypassed up files in the folder before, because they were named the same as the normal webpage files. But, after you mentioned "controllers", I took another look and it works great. Well, mostly great. For some reason, none of the pages within the "info" directory load CSS or Javascript. In order to get the page to work, I just added a new method similar to the others: Code: function albums() |
Welcome Guest, Not a member yet? Register Sign In |