Multiple Pages (404 errors) |
[eluser]ehicks727[/eluser]
[quote author="benaroia" date="1219551576"]hahaha. I get it. The MVC bit is kinda throwing me for a loop. I want to be able to call a domain name and get it routed to a default view. Then be able to change that view, without changing the domain. From product.com to product.com/buysomething to product.com/buysomething/[product-id] My problem is that I'm not sure where to place the required files (images, css, etc) relative to the domain (default view that is). I'm also not sure how to move the controller from the default for product.com to product.com/buysomething...[/quote] You really need to read through the user guide http://ellislab.com/codeigniter/user-guide/toc.html Try all the examples, then I found it helpful when I was learning all this to follow through and do the video tutorials. In particular, you need to read up on views. Do the examples and it should start making sense. http://ellislab.com/codeigniter/user-gui...views.html As far as where to keep your assets (css, images, etc.. ) keep them in your root. /css /img /video etc.. The way I use views is that I have one file that is my template. The template references all my css, images, etc. I have a designated area for content that changes from page to page. Create another view, specific to your page (i.e. about.php, contactus.php) and pass that view designation from your controller to your template view. I hope that makes sense. I should probably throw up some code, but it's better if you try to figure it out first... you learn better that way. If you're still struggling after you done some reading and tried the tutorials, let me know, I can give you some pointers. |
Messages In This Thread |
Multiple Pages (404 errors) - by El Forum - 08-22-2008, 09:16 AM
Multiple Pages (404 errors) - by El Forum - 08-22-2008, 02:28 PM
Multiple Pages (404 errors) - by El Forum - 08-22-2008, 04:08 PM
Multiple Pages (404 errors) - by El Forum - 08-23-2008, 12:19 PM
Multiple Pages (404 errors) - by El Forum - 08-23-2008, 05:12 PM
Multiple Pages (404 errors) - by El Forum - 08-23-2008, 05:19 PM
Multiple Pages (404 errors) - by El Forum - 08-23-2008, 05:20 PM
Multiple Pages (404 errors) - by El Forum - 08-23-2008, 05:32 PM
Multiple Pages (404 errors) - by El Forum - 08-23-2008, 06:57 PM
Multiple Pages (404 errors) - by El Forum - 08-23-2008, 07:13 PM
Multiple Pages (404 errors) - by El Forum - 08-23-2008, 07:25 PM
Multiple Pages (404 errors) - by El Forum - 08-23-2008, 08:59 PM
Multiple Pages (404 errors) - by El Forum - 08-23-2008, 09:40 PM
|