Mobile Directory Not Updating....
8 posts by 2 authors in: Forums > CMS Builder
Last Post: August 28, 2015 (RSS)
By osga - August 26, 2015
Hi All...
We've just setup a mobile site and are trying to include headlines on the news page. The code is working to the extent that it produces the right headlines from the right categories, but its still registering the same headlines from when i first put the code in... it hasnt been updating the headlines. Any and all clues would be appreciated!
This is the page in question:
http://www.osga.com/mobile/bonuses.html
We're using the standard virtual include to produce the headlines on the page:
<!--#include virtual="mheadlines.php?categoryNum=23" -->
Headline Generating page page:
http://www.osga.com/mobile/mheadlines.php
Heres the code we're using for the generating page:
<?php header('Content-type: text/html; charset=utf-8'); ?>
<?php
// load viewer library
$libraryPath = '../cmsAdmin/lib/viewer_functions.php';
$dirsToCheck = array('/var/www/html/osga.com/','','../','../../','../../../');
foreach ($dirsToCheck as $dir) { if (@include_once("$dir$libraryPath")) { break; }}
if (!function_exists('getRecords')) { die("Couldn't load viewer library, check filepath in sourcecode."); }
// load records
list($articlesRecords, $articlesMetaData) = getRecords(array(
'tableName' => 'articles',
'limit' => '10',
));
?>
<div>
<?php foreach ($articlesRecords as $record): ?>
<a href="http://www.osga.com/mobile/article_blank.php<?php echo $record['_link'] ?>" target="_blank"><?php echo $record['title'] ?></a><br/>
<?php echo $record['summary'] ?><br/>
<?php foreach ($record['images'] as $upload): ?>
<?php if ($upload['hasThumbnail']): ?>
<img src="<?php echo $upload['thumbUrlPath'] ?>" width="<?php echo $upload['thumbWidth'] ?>" height="<?php echo $upload['thumbHeight'] ?>" alt="" /><br/>
<?php elseif ($upload['isImage']): ?>
<img src="<?php echo $upload['urlPath'] ?>" width="<?php echo $upload['width'] ?>" height="<?php echo $upload['height'] ?>" alt="" /><br/>
<?php endif ?>
<?php endforeach ?><br/>
<!-- STEP2a: /Display Uploads -->
<?php endforeach ?>
<?php if (!$articlesRecords): ?>
No records were found!<br/><br/>
<?php endif ?>
<!-- /STEP2: Display Records -->
</div>
By Damon - August 26, 2015
Hi,
My first thought is that this may be a caching issue.
Can you create a copy of the bonuses.html page with the virtual include changed to be a PHP include for testing and send me a link ?
Damon Edis - interactivetools.com
Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/
By osga - August 26, 2015 - edited: August 26, 2015
im hoping this is a cache issue too, but just today a new art came to the top, but the headlines dont match the org bonuses page on the reg website (that page uses almost the same code as the one we're playing with)
heres the php include
http://www.osga.com/mobile/bonuses_test.html
Reg bonus page
http://www.osga.com/online_gaming.php?categoryNum=23
By Damon - August 26, 2015
On this page:
http://www.osga.com/mobile/bonuses_test.html
Nothing is appearing for SPORTSBOOK BONUSES.
Can you change the page extension from .html to .php and see if that works?
Damon Edis - interactivetools.com
Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/
By osga - August 27, 2015
Already tried that it didnt help..
http://www.osga.com/mobile/bonuses_test.php
By Damon - August 28, 2015
Have you had any success using a PHP include?
Can you attach the bonuses_test.php file so I can take a look?
Damon Edis - interactivetools.com
Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/
By osga - August 28, 2015
as requested!
<!DOCTYPE html>
<html>
<head>
<title>OSGA Gaming Bonuses!</title>
<link rel="stylesheet" href="rmm-css/responsivemobilemenu.css" type="text/css"/>
<link rel="stylesheet" href="http://www.osga.com/mobile/mstyle.css">
<script type="text/javascript" src="http://code.jquery.com/jquery.min.js"></script>
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no"/>
</head>
<body class="mainbody">
<div class="header">
<!--#include virtual="mheader.html" -->
</div>
<div class="border">
<!-- CONTENT START -->
<div style="font-family: lucida grande, Arial; font-size: 1.5EM; padding: 10px 0px 40px 20px; text-align: center; font-weight: bold;">OSGA BONUSES! </div>
<div style="margin: auto;">
<ul style=" list-style-type: none; margin: auto; width: 300px;">
<li style="float: left; "><a href="#sportsbooks"><b>Sportsbooks</b></a></li>
<li style="float: left; padding: 0px 15px;"><a href="#casino"><b>Casino</b></a></li>
<li style="float: left;"><a href="#poker"><b>Poker</b></a></li>
</ul>
</div>
<div style="margin: auto; width: 86%">
<p id="sportsbooks"><br /><br /></p>
<div style="padding: 0px 0px 20px 20px;">
<div style="color: #900;" ><h3><B>SPORTSBOOK BONUSES:</B></h3></div>
<?php include 'mheadlines.php?categoryNum=23';?>
</div>
<p id="casino"></p><br />
<div style="padding: 0px 0px 20px 20px;">
<div style="color: #900;" ><h3><B>CASINO BONUSES:</B> </h3></div>
<!--#include virtual="mheadlines.php?categoryNum=44" -->
</div>
<p id="poker"></p><br />
<div style="padding: 0px 0px 20px 20px;">
<div style="color: #900;" ><h3><B>POKER BONUSES:</B></h3></div>
<!--#include virtual="mheadlines.php?categoryNum=28" -->
</div>
</div>
</div>
<!-- CONTENT END -->
<div class="footer">
<!--#include virtual="mfooter.html" -->
</div>
<!-- OPENTRACKER HTML START -->
<script defer src="http://server1.opentracker.net/?site=www.osga.com"></script>
<noscript><a href="http://www.opentracker.net" target="_blank"><img src="http://img.opentracker.net/?cmd=nojs&site=www.osga.com" alt="website metrics" border="0"></a>
</noscript>
<!-- OPENTRACKER HTML END -->
</body>
</html>
By Damon - August 28, 2015
Hi,
Trying changing the PHP include to this:<?php include("mheadlines.php?categoryNum=23"); ?>
If this doesn't pull in the content then contact the host with a link to the page so they can explain why PHP includes aren't working.
Damon Edis - interactivetools.com
Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/