CodeIgniter Forums
Presentation Page before index.php - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23)
+--- Thread: Presentation Page before index.php (/showthread.php?tid=14899)



Presentation Page before index.php - El Forum - 01-19-2009

[eluser]ferex[/eluser]
Hi

is there a way to make a presentation page

like to have

presentation.php
index.php
...


so when I access the site it first goes to presentation
to choose the desired language accompanied with a nice logo image
and then, after a language has been chosen
the index page comes in


Another question please

Is there a way to while looking at this presentation page
the index is being loaded? to save time.


Thank you for reading.


Presentation Page before index.php - El Forum - 01-19-2009

[eluser]Andrew A.[/eluser]
In your default controller, create a function _presentation() to load the presentation files. Then in index(), check if the language has been set yet (I assume via sessions or cookies?) via an if/else. If the variable is not set, return _presentation(). If it is set, then show the index.


Presentation Page before index.php - El Forum - 01-19-2009

[eluser]ferex[/eluser]
Thank you very much Andrew for your sugestion

I'll do that

is there an answer for the second question?

to preload the site while the presentation is being showed?

because i have lot of images

thank you.


Presentation Page before index.php - El Forum - 01-20-2009

[eluser]Andrew A.[/eluser]
Sorry i didn't even see the second part. I'm actually not quite sure what is the best method for this, as I have never had to encounter it in my work. The best thing i can think of now is having a hidden div with images that can load into the cache, but i'll leave it to other members in the community who might have experience with pre-loading.


Presentation Page before index.php - El Forum - 01-20-2009

[eluser]ferex[/eluser]
Ok, thank you, once again.

Hope to hear some advice of that question.