Exemple #1
0
<div id="story-end">
	<p class="unfinished">Sorry, you've reached an end point.
	<?php 
if (!empty($_SESSION['story_id'])) {
    $first_chapter = get_first_chapter($_SESSION['story_id']);
    ?>
		  <a href="read_chapter.php?chapter=<?php 
    print $first_chapter;
    ?>
">Start again?</a>
	  <?php 
}
?>
	</p>
</div> <!-- story end -->
Exemple #2
0
        }
        echo "<br />";
        foreach ($errors as $error) {
            echo "-" . $error;
        }
    }
}
include "includes/header.php";
if (!empty($message)) {
    echo "ALERT: {$message} <br />";
}
?>
	<!-- TITLE -->
		<h2 class="page-title">
			 <a href="read_chapter.php?chapter=<?php 
print get_first_chapter($story['id']);
?>
"><?php 
print $story['title'];
?>
</a>
		</h2>

		<!-- Show the form -->
		<form action="edit_chapter.php?chapter=<?php 
echo urlencode($select_chapter['id']);
?>
" method="post" class="edit-form" accept-charset="utf-8">
			<?php 
include "includes/page_form.php";
?>
Exemple #3
0
}
?>
		</div> <!-- #alert -->
		<h2 class='page-title'>Your Stories</h2>
		<?php 
$message = "";
global $connection;
$pager = new Pager($connection, "user-stories");
$result = $pager->getResult();
?>

				<ul class="story-list">	
				<?php 
//	Loop through stories to create a list
while ($story = mysql_fetch_array($result)) {
    $chapter_id = get_first_chapter($story['id']);
    // Get the specific chapter
    // Find how many chapters are in a story. This is just for fun -- to show how long or full a given story is.
    $total = get_story_children_n($story['id']);
    ?>
					<li class="my-story">
					  <a href="start_new_story.php?story=<?php 
    echo $story['id'];
    ?>
&chapter=<?php 
    echo $chapter_id;
    ?>
" 
										class="title"><?php 
    print $story['title'];
    ?>