Noob help required! Please!

#1
[eluser]yashzn[/eluser]
Sup, I've installed codeIgniter on my localhost, and it works...but can someone PLEASE guide me in the right direction.

I'm a webdesigner (used to use tables in dreamweaver) but I'd like to start structuring my sites better using php.

How do I make a simple site where the index displays the header/footer, and changes the content when you click a menu item...

I know some basic php, so not a total noob at this...help pls!

#2
[eluser]Jeroen Brussich[/eluser]
You know HTML-code?
You understand CSS?
You can code PHP?

Then you can go on to read the CI user guide

#3
[eluser]yashzn[/eluser]
Thanks for the fast reply! I can't actually code php...but i can understand segments if I have to and use it accordingly...I went to the page and viewed the rest of the topics...but nothing Sad

I'm just looking for a step by step tut on how to get a site structure in place...

#4
[eluser]Jeroen Brussich[/eluser]
Then why would you want to move to CI?

No offence meant, but CI is a PHP framework to build applications (and not really websites... ohoh, don't flame me now, guys....)

As far as I know, you can go a long way with just * Dreamweaver. If you really want to switch, I'm afraid I have to point you to those tutorials in order to get a really basic understanding about HTML, CSS and PHP.

* again: no offence
** English not being my mothertongue, I'm apologizing if I'm too rude...

#5
[eluser]jedd[/eluser]
[quote author="yashzn" date="1259370203"]
I can't actually code php...
[/quote]

I would suggest that CodeIgniter might not be the answer to your question, then.

Do extant CMS products like Joomla, Drupal, Mindtouch, Moodle, etc provide the functionality you seek? They're probably going to be far more useful to you if your goal is to build sites without writing code.

And Jeroen - don't panic - you're being way too polite. Wink

#6
[eluser]GamingFusion[/eluser]
for my site i used a very simple template structure.

in the folder i created a folder called "template".

then created the following file inside of it.

template.php
header.php
footer.php

As far as code goes i created my template in dreamweaver(1 file) and then cut the code from the top to the end of my sidebar.php code and pasted it into header.php then i took the code from the start of my footer code to the end of the file and put that into footer.php

also in the header i did some extra stuff for titles and such. for a css file i put this

Code:
<link rel="stylesheet" href="http://localhost:888.com/css/<?php if(!isset($css)){ echo 'styles.css';}else{echo $css . '.css';;} ?>" type="text/css" media="screen" />

which basically says if the variable $css is set then place the value if not then place a default value(which can be a css file or nothing)

for template.php i did this

Code:
<?php
$this->load->view('includes/header.php');

$this->load->view($content);

$this->load->view('includes/footer.php');
?>

now for loading the content when you load the view in the controller dont load the view file you want to load, load the template file. For example

Code:
function index()
{
     $data['title'] = 'Page Title';
     $data['css'] = 'style';
     $data['content'] = 'main';

     $this->load->view('template/template', $data);
}

now if you watched the video tutorials you will know what that code does.

The content variable is the view file you want to load.(the .php extension is not needed).

if any of that is confusing here a video i a guy using the same system in his video. His video is for a website login/register but the template system is all the same.

http://net.tutsplus.com/videos/screencas...y-6-login/

or pm me

#7
[eluser]yashzn[/eluser]
@ Jedd, thanks for the cms tips but thankfully your message has helped me to explain exctly what I want to do. I've downloaded some Lynda.com video tutorials on how to Create a CMS using php, with having no knowledge of php to start off with, and a basic knowledge o at the end.

@ Jeroen, no worries you weren't rude in the slightest. I appreciate your help!

You see I know I said:

"I can't actually code php"

But its only becuase I had no source to learn it towards building a basic cms.

@ GamingFusion, your code is looking familiar based on what I've learned so far, i'll have a look at your links. Thanks!

#8
[eluser]überfuzz[/eluser]
[quote author="yashzn" date="1259420531"]@ Jeroen, no worries you weren't rude in the slightest. I appreciate your help!

You see I know I said:

"I can't actually code php"

But its only becuase I had no source to learn it towards building a basic cms.

[/quote]

I'd say it's a big draw back not knowing php if you're planning to use CI. However, I know dudes with very limited coding skills using CI. So keep at it!

#9
[eluser]GamingFusion[/eluser]
Quote:@ GamingFusion, your code is looking familiar based on what I’ve learned so far, i’ll have a look at your links. Thanks!

like i said if you watched the video tutorials on this site, then you would know what that code does. The code is of simplicity.

and no problem


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.