Beispiel #1
0
  function Render() {
    echo "<table id='".$this->uniqueID."' class='boxtable pagedtable'>\n";
    $headers = array(
      "firstpost"=>"started",
      "userfirstpost"=>"by",
      "category"=>"category",
      "topic"=>"bbs topic",
      "count"=>"replies",
      "lastpost"=>"last post",
      "userlastpost"=>"by",
    );
    echo "<tr><th colspan='".count($headers)."'><h2>the oldskool pouët.net bbs</h2></th></tr>\n";
    echo "<tr class='sortable'>\n";
    foreach($headers as $key=>$text)
    {
      $out = sprintf("<th id='th_%s'><a href='%s' class='%s%s' id='%s'>%s</a></th>\n",
        $key,adjust_query_header(array("order"=>$key)),$_GET["order"]==$key?"selected":"",($_GET["order"]==$key && $_GET["reverse"])?" reverse":"","prodlistsort_".$key,$text);
      if ($key == "type" || $key == "name") $out = str_replace("</th>","",$out);
      if ($key == "platform" || $key == "name") $out = str_replace("<th>"," ",$out);
      echo $out;
    }
    echo "</tr>\n";

    foreach ($this->topics as $p) {
      echo "<tr>\n";

      echo " <td>";
      echo $p->firstpost;
      echo "</td>\n";

      echo " <td>";
      echo $p->firstuser->PrintLinkedAvatar()." ";
      echo $p->firstuser->PrintLinkedName();
      echo "</td>\n";

      echo " <td>"._html($p->category)."</td>\n";

      echo " <td class='topic'>";
      echo "<a href='topic.php?which=".(int)$p->id."'>"._html($p->topic)."</a>";
      echo "</td>\n";

      echo " <td>".$p->count."</td>\n";

      echo " <td title='"._html(dateDiffReadable(time(),$p->lastpost))." ago'>";
      echo $p->lastpost;
      echo "</td>\n";

      echo " <td>";
      echo $p->lastuser->PrintLinkedAvatar()." ";
      echo $p->lastuser->PrintLinkedName();
      echo "</td>\n";

      echo "</tr>\n";
    }

    $perPage = get_setting("bbsbbstopics");

    echo "<tr>\n";
    echo "<td class='nav' colspan=".(count($headers)).">\n";

    $this->page = ((int)$_GET["page"] ? $_GET["page"] : 1);
    if ($this->page > 1)
      echo "  <div class='prevpage'><a href='".adjust_query(array("page"=>($this->page - 1)))."'>previous page</a></div>\n";
    if ($this->page < ($this->count / $perPage))
      echo "  <div class='nextpage'><a href='".adjust_query(array("page"=>($this->page + 1)))."'>next page</a></div>\n";

    echo "  <select name='page'>\n";
    for ($x=1; $x<=($this->count / $perPage) + 1; $x++)
      printf("    <option value='%d'%s>%d</option>\n",$x,$x==$this->page?" selected='selected'":"",$x);
    echo "  </select>\n";
    echo "  <input type='submit' value='Submit'/>\n";
    echo "</td>\n";
    echo "</tr>\n";
    echo "</table>\n";
?>
<script type="text/javascript">
<!--
var threadCategories = $A([<?
foreach($this->categories as $v) echo "'"._js($v)."',";
?>]);
document.observe("dom:loaded",function(){
  var sel = new Element("select",{"id":"categoryFilter"});
  $("th_category").insert(sel);

  var q = location.href.toQueryParams();

  sel.add( new Option("-- filter to","") );
  threadCategories.each(function(item){
    sel.add( new Option(item,item) );
    if (item == q["category"])
      sel.selectedIndex = sel.options.length - 1;
  });
  sel.observe("change",function(){
    if (sel.selectedIndex == 0)
      location.href = "bbs.php";
    else
      location.href = "bbs.php?category=" + sel.options[ sel.selectedIndex ].value;
  });
});
//-->
</script>
<?
    return $s;
  }
<?php

if (!defined('ROOT')) {
    exit('No direct script access allowed');
}
_js(array("validator"));
?>
<style>
#wrapper {
	padding-left: 0px;
}
#wrapper #footer {
	left:0px;
}
.registraion{
	margin:0px;
	padding:0px;
	max-width: 380px;
	margin: auto;
	margin-top: 50px;
}
.form-signin {
  margin: 0 auto;
  background-color: #fff;
  
	}
  .form-signin-heading,
	.checkbox {
	  margin-bottom: 30px;
	
	}
Beispiel #3
0
<?php

if (!defined('ROOT')) {
    exit('No direct script access allowed');
}
session_check(true);
_css(array("jquery.tagit"));
_js(array("jquery.tagit", "validator", "jquery.form.min"));
loadHelpers('uicomponents');
loadModule("editor");
loadEditor("cleditor");
if (isset($_REQUEST['refid'])) {
    loadModuleLib('api', 'api');
    $apiDetails = getApiDetails($_REQUEST['refid']);
} else {
    $apiDetails['editable'] = true;
}
if ($apiDetails['editable'] == 'true') {
    ?>
<style>
.cleditorMain {
	height: auto !important;
}
</style>
<div class="container-fluid">
	<div class="row">
		<div class="col-lg-12">

			<form  name="apiForm" id="apiForm" class='apiForm' onsubmit="return validateForm('#apiForm');">
				<input type="hidden" name="id" id="id" value="<?php 
    if (isset($apiDetails['id'])) {
  function RenderBody()
  {
    echo "<div class='content'/>";
    echo "  <p>To make sure you want to delete <b>this</b> party, type \"".$this->checkString."\" here:</p>";
    echo "  <input name='checkOrig' type='hidden' value='"._html($this->checkString)."'/>";
    echo "  <input id='check' name='check' autocomplete='no'/>";
    echo "</div>";
    echo "<div class='foot'/>";
    echo "  <input type='submit' value='Submit' />";
    echo "</div>";
    ?>
<script type="text/javascript">
document.observe("dom:loaded",function(){
  $("pouetbox_partydelete").up("form").observe("submit",function(e){
    if ($F("check") != "<?php 
echo _js($this->checkString);
?>
")
    {
      alert("Enter the verification string!");
      e.stop();
      return;
    }
    if (!confirm("ARE YOU REALLY SURE YOU WANT TO DELETE \"<?php 
echo _js($this->party->name);
?>
\"?!"))
      e.stop();
  });
});
</script>
    <?
  }
Beispiel #5
0
function module_js($uri, $tag = true)
{
    $path_js = module_url(assets_dir('js') . '/' . $uri);
    return _js($path_js, $uri, $tag);
}
Beispiel #6
0
<?php

if (!defined('ROOT')) {
    exit('No direct script access allowed');
}
session_check(true);
_css(array("jquery.tagit"));
_js(array("jquery.tagit", "validator"));
if (isset($_REQUEST['refid'])) {
    $id = $_REQUEST['refid'];
    $exampleDetails['editable'] = 'true';
} elseif (isset($_REQUEST['egid'])) {
    $eg_id = $_REQUEST['egid'];
    loadModuleLib('api', 'api');
    $exampleDetails = getExampleDetails($eg_id);
} else {
    echo "<h1 align=center>Something Went Wrong</h1>";
}
if ($exampleDetails['editable'] == 'true') {
    ?>
<div class="container-fluid">
	<div class="row">
		<div class="col-lg-12">

			<form role="form" name="exampleForm" id="exampleForm" class='apiForm' onsubmit="return validateForm('#exampleForm');">
				<div class="form-group">
					<label> Example Description *</label>
					<textarea class="form-control required" rows="3" name="eg_descs" id="eg_descs" required><?php 
    if (isset($exampleDetails['eg_descs'])) {
        echo $exampleDetails['eg_descs'];
    }
Beispiel #7
0
<?php

_js("jquery.form.min");
?>
<div style="display:none">
	<form id='api_upload_form' method="post" enctype="multipart/form-data" action="<?php 
echo SiteLocation;
?>
services/?scmd=api&site=<?php 
echo SITENAME;
?>
&action=upload-tmp-file">
		<input type='hidden' id='upload_tmp_api' name='api_id'/>
		<input type='file' id='upload_tmp_photo'  name='file' multiple />
		<div id='output' style="display:none">Output</div>
	</form> 
</div>
<script>
var cle,option={ target:'#output',beforeSubmit:beforeSubmit,success:afterSuccess,resetForm:true }

function loadCleditor() {
	loadEditor("#descs_long");
	cle=$("#descs_long").cleditor({
			width: '100%',
            height: '99%',
            controls: "bold italic underline strikethrough subscript superscript | size " +//font 
					"style | color highlight removeformat | bullets numbering | outdent " +
					"indent | alignleft center alignright justify | undo redo | " +
					"rule image link unlink | cut copy paste pastetext | print source",
			fonts:"Arial, Arial Black, Helvetica, sans-serif",
			sizes:"1,2,3,4,5,6,7",
Beispiel #8
0
<?php

if (!defined('ROOT')) {
    exit('No direct script access allowed');
}
loadModuleLib('api', 'api');
loadModuleLib("markitup", "api");
$login = session_check();
$page = $_REQUEST['page'];
$pageArr = explode("/", $page);
if (count($pageArr) > 1) {
    $title = end($pageArr);
    $titleArr = explode("-", $title);
    $id = md5(end($titleArr));
    $apiDetails = getApiDetails($id);
    _js(array("jquery.snippet.min"));
    _css(array("jquery.snippet.min"));
    ?>
 
<div class="apiContent container-fluid">
	<div class="row">
		<div class="col-lg-12">
			<?php 
    if (session_check(false)) {
        ?>
			<div id='toolbar' class="text-right">
				<a href="<?php 
        echo _link("api/create");
        ?>
">Create</a> |
				<?php 
Beispiel #9
0
            <?php 
include smart_view('header');
?>
        </div>
        <div class="content-wrap <?php 
echo $content;
?>
-wrap">
            <?php 
include smart_view($content);
?>
        </div>
        <div class="footer-wrap">
            <?php 
include smart_view('footer');
?>
        </div>
        <?php 
echo js_node('jquery-1.7.2.min'), "\n";
echo js_var('_G', array('ROOT' => ROOT)), "\n";
echo js_node('every'), PHP_EOL;
if (file_exists(_js($controller))) {
    $page['scripts'][] = $controller;
}
foreach ($page['scripts'] as $script) {
    echo js_node($script), PHP_EOL;
}
?>
    </body>
</html>
Beispiel #10
0
<link rel="canonical" href="<?php 
echo _canonical();
?>
" />
<?php 
_hreflang();
?>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" /> <?php 
// remove this line if your website isn't specifically designed to be responsive
_metaSeoTags();
?>
<link rel="shortcut icon" href="<?php 
echo _img('favicon.ico');
?>
" type="image/x-icon" />
<?php 
_css('base.css');
_css('base.' . _lang() . '.css');
_css('jquery-ui');
_js('jquery');
_js('jquery-ui');
_script();
_js('LC.js');
_js('site.js');
Beispiel #11
0
<?php

define("WEBAPPROOT", SiteLocation . BASEPATH);
_css(explode(",", "bootstrap.min,font-awesome.min"));
_js(explode(",", "jquery,bootstrap.min"));
?>
<style>
body {
	padding-top: 40px;
	padding-bottom: 40px;
		margin:0px;
	background-color: #eee;
	box-shadow: inset -4px -3px 42px -3px #9B9B9B;
	-webkit-box-shadow: inset -4px -3px 42px -3px #9B9B9B;
	-moz-box-shadow: inset -4px -3px 42px -3px #9B9B9B;
	-o-box-shadow: inset -4px -3px 42px -3px #9B9B9B;
	-webkit-transition: all 0.5s ease;
	-moz-transition: all 0.5s ease;
	-o-transition: all 0.5s ease;
	transition: all 0.5s ease;
		height:100%;
}

.panel-heading {
    padding: 5px 15px;
}

.panel-footer {
	padding: 5px 15px;
	color: #A0A0A0;
	font-size: 12px;