当前位置: 首页>>代码示例>>PHP>>正文


PHP vget函数代码示例

本文整理汇总了PHP中vget函数的典型用法代码示例。如果您正苦于以下问题:PHP vget函数的具体用法?PHP vget怎么用?PHP vget使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了vget函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: vpartial

    <?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>
开发者ID:edwardshe,项目名称:sublite-1,代码行数:30,代码来源:viewjob.php

示例2: foreach

    ?>
</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>
开发者ID:davidliuliuliu,项目名称:sublite,代码行数:31,代码来源:messages.php

示例3: vpartial

?>

    <?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>
开发者ID:davidliuliuliu,项目名称:sublite,代码行数:31,代码来源:subletsearchform.php

示例4: blurb

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;
    }
}
开发者ID:edwardshe,项目名称:sublite-1,代码行数:9,代码来源:viewcompany.php

示例5: get

 public static function get($varName)
 {
     return vget($varName);
 }
开发者ID:davidliuliuliu,项目名称:sublite,代码行数:4,代码来源:View.php

示例6: vpartial

?>

      <?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 
}
?>
开发者ID:edwardshe,项目名称:sublite-1,代码行数:30,代码来源:subletform.php

示例7:

    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>
开发者ID:edwardshe,项目名称:sublite-1,代码行数:31,代码来源:companyform.php

示例8: dirname

  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;
    }
开发者ID:edwardshe,项目名称:sublite-1,代码行数:31,代码来源:navbar.php

示例9: array

<?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>
开发者ID:davidliuliuliu,项目名称:sublite,代码行数:17,代码来源:buildingtype.php

示例10: vecho

<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>
开发者ID:davidliuliuliu,项目名称:sublite,代码行数:25,代码来源:registerfinish.php

示例11: vecho

    }
}
?>

      <?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>
开发者ID:davidliuliuliu,项目名称:sublite,代码行数:31,代码来源:profile.php

示例12: vnotice

                    $('#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');
开发者ID:davidliuliuliu,项目名称:sublite,代码行数:31,代码来源:index.php

示例13: vget

      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 
}
开发者ID:davidliuliuliu,项目名称:sublite,代码行数:31,代码来源:graph.php

示例14: save_order_new

 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;
//.........这里部分代码省略.........
开发者ID:snamper,项目名称:CI_xiaoshuhaochi,代码行数:101,代码来源:common.php

示例15: vecho

  <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>
开发者ID:davidliuliuliu,项目名称:sublite,代码行数:31,代码来源:viewsublet.php


注:本文中的vget函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。