I'm implementing a scrolling horizontal template and this is the code to divs that are the pages of the template.
<?php for($i=1;$i<=2;$i++) { ?>
<div class="container" id="page-<?php echo $i ?>">
<div class="left278">
<?php
$specialPosts = new WP_Query();
$specialPosts->query('pagename=page-'.$i.'');
$mykey_values = get_post_custom_values('custom_select');
foreach ( $mykey_values as $key => $value ) {
if ($value='one') {
include 'templates/slideshow-template.php'; }
else if ($value=='two') {
include 'templates/full-page.php';
} ?>
</div>
</div>
<?php } ?>
As you can see I get the page name, and I have a custom field where you can choose the template page.
The problem is that it get always the custom field value of the first page. So if i choose option one in the first page and option two in the second page it shows always the first template.
How can I fix that?