|
homepage content beauty & style profile about the site archives poetry & fiction inspiring words tagboard affiliates |
Here is my walkthrough on how to create your php include files and insert them into your pages! All images were created by me (nothing to be proud of...kinda looks like a 2 year old made them. HAHA! As Dane Cook would say "I did my best! I did my best!!!" :P ) So please do not redistribute in any way. If you would like to link or feature on your site, please email me. Credit back is required. Enjoy!
Step One: Make Your Content Folder Go to your website file manager. In the root folder, which is the folder where your "index/home" page is located, along with maybe an "images" folder and the like, you need to create a new folder. When it prompts you to name it, call it "content". click ok/save, and were done! Onto step 2...
Step Two: Create A New File When inside your new "content" folder we are going to create a new file by clicking "new file"
Step Three: Copy or Create Your New File Text/Html Now you need to copy (if you have existing code you'd like to use) by left clicking your mouse and dragging the highlighted area around the desired text. Once you've highlighted what you want, right click and select "copy", or press Ctrl+C
Step Four: Paste Your Text/Html Into Your New File In the area where you can type text, right click your mouse and select "paste". Or press Ctrl+V. When your text/html is there, doublecheck it for any errors. Once everything looks good click save!
Step Five: Save Your File Do you see your new file in the content folder? Success!
Step Six: Choose the File To Insert Your PHP Include Code Into Choose Your desired file to put the PHP include code into. Click "edit" . This brings up the text editor where you will see your html code for that page. If this defaults to a WYSIWIG editor, choose to show it in "normaltextarea" or "html editor" , ect...
Step Seven: Insert The PHP Include on Your Page Now that we see the html of our page, insert the code in the appropriate area! Where the "sidebar" html was located is where im going to put my sidebar php include. Depending on the codes and php's that come before and after the code we just put in, might effect where it shows up on the page. In this case, if the "sidebar" shows up on my page where its not supposed to be, try putting it somewhere else. Example: my "sidebar" comes after by "most recent blogs" php, so i could try putting sidebar first, and then blog posts. Dont be intimidated. This is super easy, and if you follow the layout of the html code and put your php's where the original codes went (put sidebar php where sidebar html was, place blog php where blog html coding was, ect...) you'll be just fine! On a final note, you can see i still have some html between my phps. There really arent any rules for this. you can include html like div's, text, images, styles, formatting,ect...within your phps, or just have text only phps, or a little of both! (i do). No rules here. Just whatever makes sense for you. we did it! look! you did it! Now that wasnt so hard was it? Nah, your a natural :) . Good Job! |