コード例 #1
0
ファイル: viewjob.php プロジェクト: edwardshe/sublite-1
    <?php 
vpartial('fb', array('route' => 'jobs/job.php?id=' . vget('_id')));
?>
    <br /><br />
    <?php 
if (vget('Loggedinstudent') || vget('Loggedin')) {
    ?>
        <a href="../redirect.php?<?php 
    echo "id=";
    echo $_GET['id'];
    echo "&url=";
    vecho('link');
    ?>
" onClick="return confirm('You have clicked on an external link and are leaving the pages of SubLite.net. We are not responsible for the accuracy or effectiveness of any content outside of SubLite.net.')"><input type="button" value=<?php 
    if (filter_var(vget('link'), FILTER_VALIDATE_EMAIL)) {
        ?>
"Apply by Email"<?php 
    } else {
        ?>
"Apply Now"<?php 
    }
    ?>
 /></a>
    <?php 
} else {
    echo vlinkto('<input type="button" class="button" value="Login or register to apply for this opening!" />', 'login');
}
?>
  </div>
</panel>
コード例 #2
0
ファイル: messages.php プロジェクト: davidliuliuliu/sublite
    ?>
</text>
              </data></td>
            </tr></table>
          </div>
        </a>
      <?php 
}
?>
    </td>
    <td class="mright">
      <?php 
if (!is_null(vget('current'))) {
    ?>
        <?php 
    foreach (vget('current') as $m) {
        ?>
          <div class="mblockwrapper">
            <table class="mblock"><tr>
              <td class="pp"><profpic style="background-image: url('<?php 
        echo $m['frompic'];
        ?>
');"></profpic></td>
              <td><data>
                <name><?php 
        echo $m['fromname'];
        ?>
</name><time><?php 
        echo $m['time'];
        ?>
</time>
コード例 #3
0
?>

    <?php 
vpartial('buildingtype', array('any' => true));
?>

    <?php 
vpartial('amenities');
?>

    <div class="form-slider"><label for="sortby">Sort By: </label>
      <select id="sortby" name="sortby" required>
        <?php 
$sortby = array('priceIncreasing' => 'Cheapest', 'priceDecreasing' => 'Most Expensive', 'proximityIncreasing' => 'Closest');
if (isset($sortby[vget('sortby')])) {
    vecho('sortby', '<option selected="selected" value="{var}">' . $sortby[vget('sortby')] . '</option>');
}
foreach ($sortby as $val => $in) {
    echo "<option value=\"{$val}\">{$in}</option>";
}
?>
      </select>
    </div>

    <?php 
vnotice();
?>
    <input type="submit" name="search" value="Search" />
  </form>
  <input type="button" class="collapse" value="Show Filters" />
</panel>
コード例 #4
0
ファイル: viewcompany.php プロジェクト: edwardshe/sublite-1
function blurb($name, $title, $color)
{
    global $pointer, $cols;
    if (strlen($val = vget($name)) > 0) {
        $val = html_entity_decode($val);
        $cols[$pointer][] = "<div class=\"blurb {$color}\">\n                                      <subheadline>{$title}</subheadline>\n                                      {$val}\n                                    </div>";
        $pointer = ($pointer + 1) % 3;
    }
}
コード例 #5
0
ファイル: View.php プロジェクト: davidliuliuliu/sublite
 public static function get($varName)
 {
     return vget($varName);
 }
コード例 #6
0
ファイル: subletform.php プロジェクト: edwardshe/sublite-1
?>

      <?php 
vpartial('buildingtype');
?>

      <?php 
vpartial('amenities');
?>

      <?php 
vpartial('s3multiple', array('s3name' => 'photos', 's3title' => 'Photos (recommended: >4 photos):', 's3links' => vget('photos')));
?>

      <?php 
if (vget('submitname') == 'edit') {
    ?>
        <div class="form-slider">
          <label for="fill">Publish:</label>
          <input type="hidden" id="fill" value="blah" />
          <left class="checkboxes">
            <input type="checkbox" name="publish" id="publish" value="true" <?php 
    vchecked('publish', 'true');
    ?>
 /> Make this listing public.
          </left>
        </div>
      <?php 
}
?>
コード例 #7
0
ファイル: companyform.php プロジェクト: edwardshe/sublite-1
    var inputData = formData['input'];
    for (var name in inputData) {
      $(form).find('input[name='+name+']').val(inputData[name]);
    }
    var textareaData = formData['textarea'];
    for (var name in textareaData) {
      $(form).find('textarea[name='+name+']').val(textareaData[name]);
    }
    var selectData = formData['select'];
    for (var name in selectData) {
      var val = selectData[name];
      $(form).find('select[name='+name+']').find("option")
        .filter(function() { return $(this).val() == val; })
        .prop('selected', true);
    }
    var checkboxData = formData['checkbox'];
    for (var i = 0; i < checkboxData.length; i ++) {
      var name = checkboxData[i].name, val = checkboxData[i].val;
      // Fix [] error in selector
      name = name.replace('[]', '\\[\\]');
      $(form).find('input[name='+name+']')
        .filter(function() { return $(this).val() == val; })
        .prop('checked', true);
    }
  }
  <?php 
if (vget('submitname') == 'add') {
    echo "loadForm('#company');";
}
?>
</script>
コード例 #8
0
ファイル: navbar.php プロジェクト: edwardshe/sublite-1
  opt {
    margin-left: 40px;
    cursor: pointer;
    transition: all 0.1s ease-in-out;
    display: inline-block;
    color: #fff;
    margin-top: 10px;
  }
  opt:hover {
    color: #ffd800;
  }
</style>
<?php 
$curdir = dirname($_SERVER['REQUEST_URI'] . '/.');
// Various states the user can be in
$states = array("loggedin" => vget('Loggedin') or vget('Loggedinstudent'), "notloggedin" => !vget('Loggedin') and !vget('Loggedinstudent'), "notloggedin !/employers" => !vget('Loggedin') and !vget('Loggedinstudent') and !preg_match('/^\\/employers/', $curdir), "notloggedin /employers" => !vget('Loggedin') and !vget('Loggedinstudent') and preg_match('/^\\/employers/', $curdir), "recruiter hascompany" => vget('Loggedin') and vget('Lcompany'), "recruiter nocompany" => vget('Loggedin') and !vget('Lcompany'), "student" => vget('Loggedinstudent'), "student /housing" => vget('Loggedinstudent') and preg_match('/^\\/housing/', $curdir), "all" => true);
// Establish relative paths
$path = $GLOBALS['dirpre'] . '../';
// Build the menu items and associate them with a state
$menu = array(array("Blog", "https://sublite.wordpress.com/", "all"), array("List Job", $path . "employers/addjob.php", "recruiter hascompany"), array("Manage", $path . "employers/home.php", "recruiter hascompany"), array("Messages", $path . "employers/messages.php", "recruiter hascompany"), array("Add Company Profile", $path . "employers/addcompany.php", "recruiter nocompany"), array("Housing", $path . "housing/search.php", "student"), array("Jobs", $path . "jobs/search.php", "student"), array("Socialize", $path . "hubs/start.php", "student"), array("Add Sublet", $path . "housing/addsublet.php", "student /housing"), array("Manage", $path . "housing/home.php", "student"), array("Messages", $path . "messages.php", "student"), array("Search Housing", $path . "housing/search.php", "notloggedin !/employers"), array("Search Jobs", $path . "jobs/search.php", "notloggedin !/employers"), array("Summer Social", $path . "hubs/start.php", "notloggedin !/employers"), array("List Sublet", $path . "register.php", "notloggedin !/employers"), array("List Job", $path . "register.php", "notloggedin /employers"), array("Sign Up", $path . "register.php", "notloggedin !/employers"), array("Sign Up", $path . "employers/register.php", "notloggedin /employers"), array("Log In", $path . "employers/login.php", "notloggedin /employers"), array("Log In", $path . "login.php", "notloggedin !/employers"), array("Log Out", $path . "logout.php", "loggedin"));
?>
<navbar class="blackbar">
  <a href="."><logo>SubLite</logo></a><beta>beta</beta>
  <options class="right">
    <?php 
foreach ($menu as $opt) {
    $text = $opt[0];
    $link = $opt[1];
    if (!$states[$opt[2]]) {
        continue;
    }
コード例 #9
0
<?php

$buildingtypes = array("Apartment Building", "Student Housing (Dorm)", "Elevator Building", "Walk-Up", "Town-House", "Brownstone", "Rowhouse", "Duplex", "House", "Other");
if (!is_null(vget('any'))) {
    array_unshift($buildingtypes, 'Any');
}
?>

<div class="form-slider"><label for="buildingtype">Building type: </label>
<select id="buildingtype" name="buildingtype" required>
  <?php 
vecho('buildingtype', '<option selected="selected">{var}</option>');
foreach ($buildingtypes as $buildingtype) {
    echo "<option>{$buildingtype}</option>";
}
?>
</select></div>
コード例 #10
0
<style>
  body {
    background-color: #ffd800;
  }
  confirmation {
    text-transform: uppercase;
    padding: 20px;
    font-size: 1.5em;
    line-height: 1.2em;
    display: block;
  }
</style>

<panel>
  <div class="content">
    <confirmation>A confirmation email has been sent to <strong><?php 
vecho('email');
?>
</strong>. Check your inbox or spam. The email may take up to 24 hours to show up.</confirmation>

    <?php 
vpartial('studentrefer', array('email' => vget('email')));
?>
  </div>
</panel>
コード例 #11
0
ファイル: profile.php プロジェクト: davidliuliuliu/sublite
    }
}
?>

      <?php 
if (vget('Loggedinstudent')) {
    ?>
        <br /><br />
        <?php 
    View::partial('newmessage', ['from' => View::get('L_id'), 'to' => View::get('recruiterid'), 'text' => 'Message']);
    ?>
      <?php 
}
?>
    </div>

    <a href="search.php?byrecruiter=<?php 
vecho('recruiterid');
?>
"><input type="button" value="View Job Listings" /></a>

    <?php 
if (vget('isme')) {
    ?>
      <br /><br />
      <a href="editprofile.php"><input type="button" value="Edit Profile" /></a>
    <?php 
}
?>
  </div>
</panel>
コード例 #12
0
ファイル: index.php プロジェクト: davidliuliuliu/sublite
                    $('#switchhub').click(function () {
                      $('#cityform').show();
                      $(this).hide();
                    });
                  </script>
                </div>
              </div>
            <?php 
    }
    ?>

            <?php 
    vnotice();
    ?>
            <?php 
    if (!vget('signedup')) {
        ?>
              <form id="cityform" method="post">
                <div class="whitetext">Where are you this summer?</div>
                <div class="form-slider">
                  <label for="city">(eg. New York City, Boston, San Francisco)</label>
                  <input type="text" id="city" name="city" required />
                </div>
                <input type="submit" name="signup" value="Sign up now" />
              </form>
            <?php 
    }
    ?>
        <?php 
} else {
    echo vlinkto('<input type="button" class="button" value="Login or register to sign up for the social hubs!" />', $GLOBALS['dirpre'] . '../register');
コード例 #13
0
ファイル: graph.php プロジェクト: davidliuliuliu/sublite
      labels: [
      <?php 
    $data = vget('searchcities');
    foreach ($data as $label => $count) {
        echo "'{$label}',";
    }
    ?>
      ],
      datasets: [
        {
          label: "Cities",
          fillColor: "rgba(220,220,220,0.5)",
          strokeColor: "rgba(220,220,220,0.8)",
          highlightFill: "rgba(220,220,220,0.75)",
          highlightStroke: "rgba(220,220,220,1)",
          data: [
            <?php 
    $data = vget('searchcities');
    foreach ($data as $count) {
        echo "'{$count}',";
    }
    ?>
          ]
        }
      ]
    };
    var ctx4 = $("#chart4").get(0).getContext("2d");
    var chart4 = new Chart(ctx4).Bar(data4, options);
  </script>
<?php 
}
コード例 #14
0
ファイル: common.php プロジェクト: snamper/CI_xiaoshuhaochi
 function save_order_new($uid, $order_type, $c, $event = array(), $invate_code)
 {
     $pay_config = trim($_POST['payway']);
     $comment = trim($_POST['comment_input']);
     if ($uid) {
         $sql = "SELECT t_shipping_address.*,t_service_buildings.address as building_address, t_companys.event_id,t_companys.id,t_companys.name as company_name,t_companys.address as company_address, t_province.province, t_city.city, t_area.area FROM t_companys,t_shipping_address, t_city, t_province, t_service_buildings,t_area WHERE t_shipping_address.tsa_company= t_companys.id and t_shipping_address.tsa_province = t_province.province_id\nAND t_shipping_address.tsa_city = t_city.city_id\nand t_shipping_address.tsa_building_id = t_service_buildings.id\nAND t_shipping_address.tsa_district = t_area.area_id and t_shipping_address.tsa_uid=" . $uid;
         $default_address = $this->tickets->personal_select($sql . " and t_shipping_address.tsa_default=1");
     }
     $building_id = $default_address[0]->tsa_building_id;
     if (!$default_address) {
         echo json_encode(array('success' => 'no', 'msg' => '请选择配送地址'));
         exit;
     }
     $address = $default_address[0];
     //$goods = $this->_get_cookie_good_detail($c,$event);
     $new_website = $this->config->item('new_website');
     $this->load->helper('curl');
     $goods_json = vget($new_website . "/cart/getCart", array('Cookie:this_week_cart=' . $_COOKIE['this_week_cart'] . ';next_week_cart=' . $_COOKIE['next_week_cart']));
     $goods = json_decode($goods_json, TRUE);
     //$this->load->model('cart_model');
     //$goods = $this->cart_model->getCartInfo();
     if (empty($goods['cart_goods'][0]) && empty($goods['cart_goods'][1])) {
         echo json_encode(array('success' => 'no', 'msg' => '商品过期或者购物车没商品'));
         exit;
     }
     if ($goods['cart_goods'][0] || $goods['cart_goods'][1]) {
         //判断库存
         $cart_goods_list = array_merge($goods['cart_goods'][0], $goods['cart_goods'][1]);
         if ($_COOKIE["set_building"] == 143) {
             $building_id = 143;
         } else {
             $building_id = 43;
         }
         foreach ($cart_goods_list as $k => $v) {
             //if($v['week_count']['count']){
             //更新库存
             $temp_stock = $this->tickets->api_select('good_supplier_buildings', 'id,stock', array('good_id' => $v['goods_id'], 'building_id' => $building_id));
             $stock = $temp_stock[0];
             $final_stock = $stock->stock - $v['goods_num'];
             if ($final_stock < 0) {
                 $temp_goods = $this->tickets->api_select('goods', 'name', array('id' => $v['goods_id']));
                 if ($temp_goods) {
                     $good_name = $temp_goods[0]->name;
                     echo json_encode(array('success' => 'no', 'msg' => $good_name . '库存不足,剩余' . $stock->stock . '份'));
                     exit;
                 }
             }
             //}
         }
         //邀请码活动
         if (!empty($invate_code)) {
             $code = strtolower($invate_code);
             //邀请码
             echo 5555;
             exit;
             $invate_code = $this->tickets->select("users", array("tu_invate_code" => $code));
             $tu_id = $invate_code[0]->tu_id;
             //邀请人的ID
             //$uid自己的ID
             $arr['in_tu_id'] = $tu_id;
             //邀请人的ID
             $arr['in_self_id'] = $uid;
             //自己的ID
             $arr['in_invate_code'] = $code;
             //邀请码
             $arr['in_used'] = date('Y-m-d H:i:s', time());
             //使用时间
             $id = $this->tickets->insert("invate_code", $arr);
             if ($id) {
                 $price = 15;
             } else {
                 $price = 0;
             }
             //以上是在今日增加使用邀请码
             $cut_down = $goods['goods_count'] * 15;
             //有多少份就减少多少个15元
         }
         //$promote_price=$this->promote_price();
         $promote_price = 0;
         //2015/5/4暂时不用组合价格
         $total_count = $goods['goods_count'];
         $total_price = $goods['total_price'] - $cut_down - $promote_price;
         $orignal_amount = $goods['total_price'];
         $coupons_id = $_POST['coupons_id'];
         $coupon_price = 0;
         if ($coupons_id) {
             $sq = "select t_coupons_record.*,t_coupons.tc_price from t_coupons,t_coupons_record where t_coupons_record.tcr_id=" . $coupons_id . " and t_coupons.tc_id=t_coupons_record.tcr_tc_id and t_coupons_record.tcr_status= 0 and t_coupons_record.tcr_uid=" . $uid;
             $coupon_check = $this->tickets->personal_select($sq);
             if (!$coupon_check) {
                 echo json_encode(array('success' => 'no', 'msg' => '此优惠券无效,请核对'));
                 exit;
             } else {
                 $coupon_price = $coupon_check[0]->tc_price;
             }
         }
         $order_sn = 'S' . date('YmdHis') . $this->_generate_code(4);
         $real_pay_price = $total_price - $coupon_price;
         $order_status = 10;
         if ($real_pay_price <= 0) {
             $real_pay_price = 0;
             $order_status = 20;
         }
         //判断活动的可用性
         $current_time = date('Y-m-d');
         $event_check = $this->tickets->api_select('event', '', array('start_time >=' => $current_time, 'end_time <=' => $current_time, 'id' => $address->event_id));
         if ($event_check) {
             $event_id = $address->event_id;
         } else {
             $event_id = 0;
         }
         $order_data = array('to_comment' => $comment, 'to_event_id' => $event_id, 'to_company' => $address->tsa_company, 'to_receiver' => $address->tsa_nickname, 'to_mobile' => $address->tsa_mobile, 'to_address' => $address->province . ' ' . $address->city . ' ' . $address->area . ' ' . $address->building_address . ' ' . $address->company_address, 'to_order_sn' => $order_sn, 'to_pay_way' => $pay_config, 'to_created' => date('Y-m-d H:i:s'), 'to_uid' => $uid, 'to_order_type' => $order_type, 'to_order_amount' => $real_pay_price, 'to_total_amount' => $total_price, 'to_orignal_amount' => $orignal_amount, 'to_coupon_id' => $coupons_id, 'to_shipping_id' => $address->tsa_id, 'to_status' => $order_status);
         $temp_valid_date = $this->tickets->select('configs', array('tc_type' => 'order_date'));
         $valid_time = $temp_valid_date[0]->tc_title;
         $current_time = date('H:i');
         $current_date = date('Y/m/d');
         $order_id = $this->tickets->insert('orders', $order_data);
         if ($order_status == 20) {
             error_log(print_r($order_data, true), 3, '/data/www/orginal_main_price.txt');
         }
         if ($order_id) {
             foreach ($cart_goods_list as $k => $v) {
                 //if($v['week_count']['count']){
                 $temp_date = array('service_date' => $v['date'], 'good_id' => $v['goods_id'], 'o_count' => $v['goods_num'], 'o_perprice' => $v['price'], 'count' => $v['goods_num'], 'perprice' => $v['price'] - $price, 'order_id' => $order_id, 'order_status' => 10, 'created' => date('Y-m-d H:i:s'));
                 $this->tickets->insert('order_good', $temp_date);
                 //更新库存
                 $temp_stock = $this->tickets->api_select('good_supplier_buildings', 'id,stock', array('good_id' => $v['goods_id'], 'building_id' => $building_id));
                 $stock = $temp_stock[0];
                 $final_stock = $stock->stock - $v['goods_num'];
                 if ($final_stock >= 0) {
                     $this->tickets->update('good_supplier_buildings', array('stock' => $final_stock), array('id' => $stock->id));
                 }
                 //}
             }
             //如果有使用优惠券,则冻结此优惠券
             if ($coupons_id) {
                 $this->tickets->update('coupons_record', array('tcr_status' => 1, 'tcr_updated' => date('Y-m-d H:i:s')), array('tcr_id' => $coupons_id));
             }
             //setcookie('goods_cart','',time()+3600*24,'/');
             $this->load->helper('cookie');
             delete_cookie('this_week_cart');
             delete_cookie('next_week_cart');
             //setcookie('next_week_cart','',time()+3600*24,'/');
             echo json_encode(array('success' => 'yes', 'order_sn' => $order_sn, 'pay_config' => $pay_config, 'order_price' => $real_pay_price));
             exit;
         }
     }
 }
コード例 #15
0
ファイル: viewsublet.php プロジェクト: davidliuliuliu/sublite
  <div id="map-canvas"></div>
</panel>

<div class="pop">
  <div class="poptable">
    <div class="popphoto"><img src="" /></div>
  </div>
</div>
<div class="popshare">
  <div class="poptable">
    <div class="popcell">
      <div class="popsharetext">
        Share your listing on social media such as Facebook groups to advertise your listing!
        <br />Copy and paste the link below into posts:
        <br /><br />
          <copy>www.sublite.net/housing/sublet.php?id=<?php 
vecho('_id');
?>
</copy>
        <br />
        or Like and Share below: <br /><br />
        <?php 
vpartial('fb', array('route' => 'housing/sublet.php?id=' . vget('_id')));
?>
        <br /><br /><br />
        <input type="button" id="soundsgood" value="Sounds good!" />
        <input type="button" id="hideshare" style="background: #999;" value="Don't show this again." />
      </div>
    </div>
  </div>
</div>
コード例 #16
0
ファイル: managejobs.php プロジェクト: edwardshe/sublite-1
<panel class="jobs">
  <div class="content">
    <headline>Manage Job Listings</headline>
    <?php 
function jobBlock($job)
{
    $title = $job['title'];
    $location = $job['location'];
    $desc = strmax($job['desc'], 300);
    $deadline = $job['deadline'];
    if ($job['locationtype'] == 'home') {
        return "\n          <div class=\"jobblock\">\n            <div class=\"title\">{$title} | Work at home</div>\n            <div class=\"desc\">{$desc}</div>\n            <div class=\"info\">Deadline: {$deadline}</div>\n          </div>\n        ";
    }
    return "\n          <div class=\"jobblock\">\n            <div class=\"title\">{$title} | {$location}</div>\n            <div class=\"desc\">{$desc}</div>\n            <div class=\"info\">Deadline: {$deadline}</div>\n          </div>\n        ";
}
$jobs = vget('jobs');
$totalViewCount = 0;
$totalApplyCount = 0;
foreach ($jobs as $job) {
    $totalViewCount += $job['stats']['views'];
    $totalApplyCount += $job['stats']['clicks'];
}
echo '<div style="font-size: 16px;">You have a total of <b>' . $totalViewCount . "</b> views on your listings and <b>" . $totalApplyCount . '</b> clicks on the "Apply Now" button.</div>';
foreach ($jobs as $job) {
    echo vlinkto(jobBlock($job), 'editjob', array('id' => $job['_id']->{'$id'}));
}
if ($jobs->count() == 0) {
    echo "<b style=\"font-size: 1.5em;\">Congratulations! You have completed your company profile and are on your way to recruiting the most talented students. Just take a moment to complete your job listing(s) by clicking the button below and you'll be all set!</b><br /><br />" . vlinkto('<input type="button" value="List Job" />', 'addjob');
}
?>
  </div>
コード例 #17
0
<style>
  subheadline {
    line-height: 2em;
    margin-top: 0.5em;
  }
</style>

<panel class="form">
  <div class="content">
    <headline>Edit Profile</headline>
    <form method="post">
      <?php 
echo ' &nbsp; ' . vlinkto('<input type="button" value="View Profile" /><br /><br />', 'recruiter', array('id' => vget('L_id')->{'$id'}));
?>

      <?php 
vnotice();
?>

      <div class="form-slider"><label for="firstname">First Name:</label><input type="text" id="firstname" name="firstname" value="<?php 
vecho('firstname');
?>
" required /></div>

      <div class="form-slider"><label for="lastname">Last Name:</label><input type="text" id="lastname" name="lastname" value="<?php 
vecho('lastname');
?>
" required /></div>

      <div class="form-slider"><label for="title">Job Title:</label><input type="text" id="title" name="title" value="<?php 
vecho('title');
コード例 #18
0
ファイル: manage.php プロジェクト: davidliuliuliu/sublite
function subletBlock($sublet)
{
    $title = $sublet['title'];
    $location = $sublet['address'];
    if ($sublet['city'] != '') {
        $location .= $sublet['city'];
    }
    if ($sublet['state'] != '') {
        $location .= $sublet['state'];
    }
    $summary = strmax($sublet['summary'], 300);
    $price = $sublet['price'];
    $pricetype = $sublet['pricetype'];
    $publish = $sublet['publish'];
    if ($publish) {
        $published = '<green>Public</green>';
    } else {
        $published = '<red>Private (Publish to have listing show up in search results)</red>';
    }
    return "\n          <div class=\"subletblock\">\n            <div class=\"title\">{$title} | {$location}</div>\n            <div class=\"summary\">{$summary}</div>\n            <div class=\"info\">Price: {$price} /{$pricetype} | {$published}</div>\n          </div>\n        ";
}
$sublets = vget('sublets');
foreach ($sublets as $sublet) {
    echo vlinkto(subletBlock($sublet), 'editsublet', array('id' => $sublet['_id']->{'$id'}));
}
if ($sublets->count() == 0) {
    echo "<b style=\"font-size: 1.5em;\">Congratulations! You have completed your profile and are on your way to finding tenants for the summer. Just take a moment to complete your sublet listing(s) by clicking the button below and you'll be all set!</b><br /><br />" . vlinkto('<input type="button" value="List Sublet" />', 'addsublet');
}
?>
  </div>
</panel>
コード例 #19
0
ファイル: jobform.php プロジェクト: davidliuliuliu/sublite
<panel class="form">
  <div class="content">
    <headline><?php 
vecho('headline');
?>
 Job Listing</headline>
    <form method="post">
      <?php 
if (vget('_id') !== null) {
    $id = vget('_id');
    echo ' &nbsp; ' . vlinkto('<input type="button" value="View Job Listing" /><br /><br />', 'job', array('id' => $id), true);
}
?>
      <?php 
vnotice();
?>
      <div class="form-slider"><label for="title">Job Title:</label><input type="text" id="title" name="title" value="<?php 
vecho('title');
?>
" required /></div>
      <left>
        <input type="radio" name="jobtype" id="fulltime" value="fulltime" <?php 
vchecked('jobtype', 'fulltime');
?>
 required /><label for="fulltime"> Full-time position</label>
        <input type="radio" name="jobtype" id="parttime" value="parttime" <?php 
vchecked('jobtype', 'parttime');
?>
 required /><label for="parttime"> Part-time position</label>
        <input type="radio" name="jobtype" id="internship" value="internship" <?php 
vchecked('jobtype', 'internship');
コード例 #20
0
ファイル: s3multiple.php プロジェクト: davidliuliuliu/sublite
?>
">None</div>

<script>
  function addImg<?php 
vecho('s3name');
?>
(url, name) {
    if ($('.img[name='+name+']').html() == 'None') $('.img[name='+name+']').html('');

    $('.inputs[name='+name+']')
      .prepend('<input class="imginput" type="hidden" name="'+name+'[]" value="' + url + '" />');
    $('.img[name='+name+']')
      .prepend('<img class="img" src="' + url + '" />');

    $('.img[name='+name+'] img[src="'+url+'"]').click(function() {
      $('.inputs[name='+name+'] .imginput[value="'+url+'"]').remove();
      $(this).remove();

      if ($('.img[name='+name+']').html() == '') $('.img[name='+name+']').html('None');
    });
  }
  <?php 
if (!is_null(vget('s3links'))) {
    $name = vget('s3name');
    foreach (vget('s3links') as $link) {
        echo "addImg{$name}('{$link}', '{$name}');";
    }
}
?>
</script>
コード例 #21
0
ファイル: viewjob.php プロジェクト: davidliuliuliu/sublite
assets/gfx/salaryico.png');">
              <div class="cell">
                <subheadline>
                <?php 
if (vget('salarytype') != "other") {
    echo '$';
}
vecho('salary');
if (vget('salarytype') != "other") {
    echo ' / ';
    vecho('salarytype');
}
?>
                </subheadline>
                <small>Compensation</small>
              </div>
            </div>

          </td>
        </tr>
      </table>
    </div>

    <?php 
vpartial('fb', array('route' => 'jobs/job.php?id=' . vget('_id')));
?>
    <br /><br />

    <apply></apply>
  </div>
</panel>
コード例 #22
0
  }
  .thread .reply {
    display: none;
    padding: 1em;
    border: 1px solid #ccc;
  }
  .brief {
    cursor: pointer;
    background: #f8dd00;
    padding: 1em;
  }
</style>

<messagestats>
  <?php 
$mlist = vget('mlist');
foreach ($mlist as $m) {
    ?>
      <div class="thread">
        <div class="brief">
          <?php 
    $count = count($m['replies']);
    $participants = array();
    foreach ($m['participants'] as $p) {
        $pname = $p['name'];
        $pemail = $p['email'];
        $participants[] = "{$pname} ({$pemail})";
    }
    $participants = implode(", ", $participants);
    $lasttime = $m['lasttime'];
    ?>
コード例 #23
0
ファイル: results.php プロジェクト: davidliuliuliu/sublite
    vecho('delay', '<div style="text-align: center;"><i>Results returned in {var} ms</div><br />');
}
foreach ($sublets as $sublet) {
    echo subletBlock($sublet);
}
if (count($sublets) == 0) {
    echo "No sublets matching your query. But don't fret! New sublets are being added regularly.";
}
?>
      </div>
  <?php 
if (!is_null(vget('recent'))) {
    ?>
      <a href="?showMore">Show More</a>
      <?php 
    if (vget('showMore')) {
        ?>
        <script>scrollTo('.subletblock', <?php 
        vecho('showMore');
        ?>
-7);</script>
      <?php 
    }
    ?>
    </div>
  <?php 
}
?>
</panel>
<div class="clear"></div>
コード例 #24
0
ファイル: form.php プロジェクト: davidliuliuliu/sublite
    echo "<option>{$industry}</option>";
}
?>
      </select></div>
      <script>
        function changeIndustryLabel(bool) {
          if (bool) {
            $('#ilabel').css('left', '-4.5em');
          } else {
            $('#ilabel').css('left', '0.5em;');
          }
        }
        $('#industry')
          .change(function() { changeIndustryLabel($(this).val().length > 0); })
          .ready(function() { changeIndustryLabel(<?php 
if (strlen(vget('industry')) > 0) {
    echo 'true';
} else {
    echo 'false';
}
?>
) });
      </script>

      <div class="form-slider"><label for="city">City:</label><input type="text" id="city" name="city" value="<?php 
vecho('city');
?>
" /></div>

      <div class="form-slider"><label for="company">Company:</label><input type="text" id="company" name="company" value="<?php 
vecho('company');
コード例 #25
0
ファイル: index.php プロジェクト: davidliuliuliu/sublite
      scrollTo('panel.why');
    });
  });
</script>

<panel class="main">
  <div class="cell">
    <div class="banner">
      <div class="content">
        <div class="tagline">MORE INTERNSHIPS, MORE HOUSING<br>AND LESS HASSLE</div>
        <div class="slogan">
          Maximize your next summer experience with your one-stop shop for internships and housing.
          <div style="font-size: 0.7em;"><br />Verify your ".edu" email address to get started! It's completely free!</div>
        </div>
        <a href="register.php<?php 
if (!is_null($r = vget('r'))) {
    echo "?r={$r}";
}
?>
">
          <input type="button" class="registerlogin" value="Get Started" />
        </a>
        <div class="switch"><a href="../employers">switch to RECRUITER</a></div>
      </div>
    </div>
  </div>
  <div class="arrow-down"></div>
</panel>
<panel class="stats">
  <div class="content">
    <div class="stat"><num><?php 
コード例 #26
0
ファイル: home.php プロジェクト: davidliuliuliu/sublite
<panel>
  <div class="content">
    <?php 
$id = vget('_id');
$company = vget('company');
echo vlinkto('<input type="button" value="Edit Recruiter Profile" />', 'editprofile');
echo vlinkto('<input type="button" value="Edit Company Profile" />', 'editcompany');
?>
  </div>
</panel>
コード例 #27
0
ファイル: confirm.php プロジェクト: davidliuliuliu/sublite
        </select>
      </div>

      <div class="form-slider"><label for="gender">Gender </label>
        <select id="gender" name="gender" required>
          <?php 
vecho('gender', '<option selected="selected">{var}</option>');
?>
          <option value="male">Male</option>
          <option value="female">Female</option>
          <option value="other">Other</option>
        </select>
      </div>

      <?php 
vpartial('s3single', array('s3name' => 'photo', 's3title' => 'Upload a profile picture *: ', 's3link' => vget('photo')));
?>

      <?php 
vnotice();
?>

      <p style="text-align:left;margin-bottom:0px">What are you looking for? Please select all that apply. <br> Your answers to the following will help us find better opportunities for you.</p>
      <label for="looking">Internship</label><input class="internship" onchange="lookingForValueChanged()" type="checkbox" id="internship" name="internship" value="<?php 
vecho('internship');
?>
" />
      <label for="looking">Full-Time</label><input class="fulltime" onchange="lookingForValueChanged()" type="checkbox" id="fulltime" name="fulltime" value="<?php 
vecho('fulltime');
?>
" />
コード例 #28
0
ファイル: htmlheader.php プロジェクト: edwardshe/sublite-1
    <?php 
if (vget('search')) {
    if (vget('search') == 'housing') {
        $data = vget('data');
        ?>
          <title>
            SubLite &ndash; Search for Sublets, Rentals, and Other Housing
            <?php 
        if ($data) {
            echo ' - ' . $data['location'];
        }
        ?>
          </title>
    <?php 
    }
    if (vget('search') == 'jobs') {
        ?>
          <title>SubLite &ndash; Search for Jobs and Internships</title>
    <?php 
    }
} else {
    ?>
        <title>SubLite &ndash; Find internships and housing and sublets for rent!</title>
    <?php 
}
?>

    <meta property="og:type" content="website" />
    <meta property="og:site_name" content="SubLite" />

    <link rel="icon" type="image/png" href="<?php