Ejemplo n.º 1
0
#!/usr/bin/php
<?php 
include "/home/websites/browserplus/php/site.php";
include "/home/websites/browserplus/php/forum.php";
// DOK_BASE - normally set in apache, but not available to scripts
putenv("DOK_BASE=/home/websites/browserplus/data");
$f = new Forum();
$secret = $f->get_cache_secret();
$host = get_cfg_var('bp_env') == "local" ? "borg" : "browserplus.org";
fetch("http://{$host}/site/cache_forums.php?s={$secret}");
Ejemplo n.º 2
0
<?php

include "../../php/site.php";
include "../../php/forum.php";
$f = new Forum();
// to make sure we're the ones calling
if (isset($_GET["s"]) && $_GET["s"] == $f->get_cache_secret()) {
    echo ($f->fetch_forums() ? "cached" : "error caching") . " forums\n";
}