[eluser]richzilla[/eluser]
What would cause a php parse error in a view file? ive checked all of my php tags and theyve all been closed properly, and my html all looks good, yet i consistently get a parse error for the last line of my view. I Thought it might be white space after the closing div tag, but no, still no luck. I have just switched to wampserver and a windows box, and the problem only occurs here, on my linux comp all is well. If anybody has any ideas (or a better lamp stack for windows, wampserver has caused me no end of headaches) id greatly appreciate the assist. The offending code:
Code:
<div class="grid_10 omega" id="content">
<div>
<h2>News</h2>
<h4>Existing</h4>
</div>
<table id="newsTable" class="tablesorter">
<thead>
<tr>
<th>Title</th>
<th>Tagline</th>
<th>Posted By</th>
<th>Posted</th>
<th></th>
<th></th>
</tr>
</thead>
<?php foreach ($posts as $indpost) : ?>
<tr>
<td class="wide"><?php echo $indpost->title; ?></td>
<td class="wide"><?php echo $indpost->tagline; ?></td>
<td class="wide"><?php echo $indpost->userName; ?></td>
<td class="wide"><?php echo $indpost->postDate; ?></td>
<td class="narrow"><?php echo anchor('news/delete/'.$indpost->id,'Delete'); ?></td>
<td class="narrow"><?php echo anchor('news/view/'.$indpost->id.'?TB_iframe=true&height=400&width=800','View',array('class' => 'thickbox')); ?></td>
</tr>
<? endforeach; ?>
</table>
<div>
<h4>Add New</h4>
</div>
<?php echo form_open('news/add',array('class' => 'form form_320')); ?>
<div>
<?php echo form_error('title'); ?>
<label for="title">Title: </label>
<input type="text" name="title" value="<?php echo set_value('title'); ?>" class="newsinput"/>
</div>
<div>
<?php echo form_error('tagline'); ?>
<label for="tagline">Tagline: </label>
<input type="text" name="tagline" value="<?php echo set_value('tagline'); ?>" class="newsinput" />
</div>
<div>
<?php echo form_error('news_content'); ?>
<label for="content">Content: </label>
<textarea name="news_content" value="<?php echo set_value('news_content'); ?>" class="newsinput" style="height: 100px;"></textarea>
</div>
<div>
<input type="submit" value="Submit"/> <input type="reset" value="Reset" />
</div>
<?php if ($this->session->flashdata('status')) { echo $this->session->flashdata('status'); } ?>
<?php echo form_close(); ?>
</div>
</div>
The error comes up on line 66 (the last one)
Again any help would be appreciated.