Welcome Guest, Not a member yet? Register   Sign In
Do I have to have an index function for the controller?
#1

[eluser]Assim[/eluser]
Well, I just wanted to ask if it is necessary to have an index function in a controller? I fully understand it's job but is it needed?
#2

[eluser]renownedmedia[/eluser]
Your apps will run fine without them.
#3

[eluser]Assim[/eluser]
Cool. Thanks a lot, Thomas!
#4

[eluser]Phil Sturgeon[/eluser]
Did you try it before you posted?

You will get a lot more respect on the forums if you try things out before posting. The test for this would literally be:

Quote:1.) Select index() method
2.) Hit delete
3.) Enter a URL in your browser
4.) Hit enter

I don't want to sound like a a**-hole but you have to see my point? :-)
#5

[eluser]jedd[/eluser]
Phil - give the bloke a break. He declared he 'fully understands it's <sic> job' - so obviously he's just testing us to see if we fully understand its job.

There's no way that someone who fully understands the role of the index() function in a controller would ask a silly question like 'do I need it?'.
#6

[eluser]Assim[/eluser]
[quote author="Phil Sturgeon" date="1257964970"]Did you try it before you posted?

You will get a lot more respect on the forums if you try things out before posting. The test for this would literally be:

Quote:1.) Select index() method
2.) Hit delete
3.) Enter a URL in your browser
4.) Hit enter

I don't want to sound like a a**-hole but you have to see my point? :-)[/quote]
I wish if I could test it, but my webserver isn't working (not at this moment), and I can't install PHP on my computer because there's something wrong with my Ubuntu Linux operating system which doesn't let me open my webroot folder in my computer for some permission setting. Otherwise, I love getting the answers myself rather than asking. So when I'm trying to find an answer and then run into these types of problems, I ask here. Or if I tried and it didn't work, then I would still ask.

So I hope you understand my situation. Smile
#7

[eluser]Phil Sturgeon[/eluser]
Why are you asking theoretical coding questions if you have no current way of coding?

Just wait until you get your environment fixed, test it then work with it.

Either way, asking here before you try is entirely pointless. Whichever answer we give you, there is nothing you can do until you are in a position to get some coding done...
#8

[eluser]n0xie[/eluser]
[quote author="Assim" date="1257969879"]and I can't install PHP on my computer because there's something wrong with my Ubuntu Linux operating system which doesn't let me open my webroot folder in my computer for some permission setting.[/quote]
Are you by any chance referring to the fact that /var/www is owned by 'root' ?
Code:
ls -l /var/www
#9

[eluser]Assim[/eluser]
[quote author="Phil Sturgeon" date="1257970782"]Why are you asking theoretical coding questions if you have no current way of coding?

Just wait until you get your environment fixed, test it then work with it.

Either way, asking here before you try is entirely pointless. Whichever answer we give you, there is nothing you can do until you are in a position to get some coding done...[/quote]
I actually am doing some coding, so it's no theoretical question. I write code and then I test it when I go to college in the next day. Also, there's no need for your spamming posts, I got the short answer, so there's no need to make this into a big discussion. If you don't want to answer my question (which was already answered), then don't answer, or are you trying to increase your post count? Smile
#10

[eluser]Assim[/eluser]
[quote author="n0xie" date="1257971714"][quote author="Assim" date="1257969879"]and I can't install PHP on my computer because there's something wrong with my Ubuntu Linux operating system which doesn't let me open my webroot folder in my computer for some permission setting.[/quote]
Are you by any chance referring to the fact that /var/www is owned by 'root' ?
Code:
ls -l /var/www
[/quote]
Well, I know that, but I found a way to use it without a problem while I was using Ubuntu 9.04, but when I recently upgraded to Ubuntu 9.10, this problem started to occur.

Thanks. Smile




Theme © iAndrew 2016 - Forum software by © MyBB