Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function index_content()
- {
- $string = <<<END
- <div id="container2">
- <div id="container1">
- <div id="col1">
- <!-- First column - Editorial -->
- <h2>Letter from the Editor</h2>
- <br/><p>
- END;
- $string .= file_get_contents('editorial.txt');
- $string .= <<<END
- </p></div>
- <div id="col2">
- <!-- Second Column - News -->
- <h2>Recent News</h2>
- END;
- $news = file('news.txt');
- foreach ($news as $story_split)
- {
- $story = explode("&&",$story_split);
- foreach ($story as $story_print)
- {
- $story_print = explode('|',$story_print);
- $string.=<<<END
- <p><strong>$story_print[0]</strong><br/>
- $story_print[1]<br/>
- $story_print[2]</p>
- <hr/>
- END;
- }
- }
- $string .=<<<END
- </div>
- </div>
- </div>
- END;
- return $string;
- }
Add Comment
Please, Sign In to add comment