示例#1
0
            ?>
            <div class="row file-container">
                <div class="span1 logo-container-file"><img src="/images/icons/f-new-icon.png"> </div>
                <div class="span3 file-name"><a href="<?php 
            echo $file->location;
            ?>
"><?php 
            echo strlen($file->name) > 20 ? substr($file->name, 0, 20) . '...' : $file->name;
            ?>
</a></div>
                <div class="span2 file-type"><?php 
            echo $file->type->name;
            ?>
</div>
                <div class="span2 file-size"><?php 
            echo MyHtml::encode(File::staticBytesToSize($file->size));
            ?>
</div>
                <div class="span1 file-checkbox"><input type="checkbox" ></div>
            </div>
            <?php 
        }
    }
    ?>
	</div>
		
	<div style="clear:both;"></div>	
	<br/>
	<?php 
}
?>
示例#2
0
                    <tr>
                        <?
                        echo $form->hiddenField($file, '[' . $i . ']extension');
                        echo $form->hiddenField($file, '[' . $i . ']id');
                        echo $form->hiddenField($file, '[' . $i . ']dataset_id');
                        echo $form->hiddenField($file, '[' . $i . ']location');
                        echo $form->hiddenField($file, '[' . $i . ']extension');
                        ?>

                        <td class="left"><?php echo $file->name ?></td>
                        <td class="left"><?= CHtml::activeDropDownList($file, '[' . $i . ']code', $samples_data, array('class' => 'span2')); ?></td>

                        <td class="left"><?= CHtml::activeDropDownList($file, '[' . $i . ']type_id', CHtml::listData(FileType::model()->findAll(), 'id', 'name'), array('class' => 'span2')); ?></td>

                        <td> <?= CHtml::activeDropDownList($file, '[' . $i . ']format_id', CHtml::listData(FileFormat::model()->findAll(), 'id', 'name'), array('class' => 'autowidth')); ?></td>
                        <td><span style="display:none"><?= File::staticGetSizeType($file->size) . ' ' . strlen($file->size) . ' ' . $file->size ?></span><?= MyHtml::encode(File::staticBytesToSize($file->size)) ?></td>

                        <td><?php echo $form->textArea($file, '[' . $i . ']description', array('rows' => 3, 'cols' => 30, 'style' => 'resize:none')); ?></td>

                        <td> <?php echo CHtml::submitButton("Update", array('class' => 'update btn', 'name' => $i)); ?> </td>
                    </tr>

                    <?
                    $i++;
                }
                ?>

            </table>
        </div>
        <div class="span12" style="text-align:center">
            <?php
示例#3
0
<div class="news">
	<h3><?php 
echo MyHtml::encode($model->title);
?>
</h3>
	<p><?php 
echo MyHtml::encode($model->body);
?>
</p>
</div>


示例#4
0
    foreach ($datasets as $key=>$dataset){
        if($i%$itemPerSlide==0)  {?>
        <div class="<? echo $active; ?> item">
        <? }?>
            <div class="data-block">
              <?php

              $url = $dataset->getImageUrl();

              echo MyHtml::link(MyHtml::image($url ,'image'), $dataset->shortUrl,array('class'=>'image-hint',  ));
              echo 'DOI: '.MyHtml::link("10.5524/".$dataset->identifier, $dataset->shortUrl);
              echo '<br/><br/>';
              $dtitle = strlen($dataset->title) > 70 ? strip_tags( substr($dataset->title , 0 , 70) ) .'...' : $dataset->title;
              echo $dtitle;
              echo '<br/><br/>';
              echo MyHtml::encode($dataset->publication_date);
              ?>
            </div>
        <?php

        if($i%$itemPerSlide==($itemPerSlide-1) || $i==count($datasets)-1 ) {?>
            </div>
        <? }
        $i++;
        $active="";
    } ?>

  </div>
  <!-- Carousel nav -->
  <a class="carousel-control left homepage-carousel-control" href="#myCarousel" data-slide="prev">&lsaquo;</a>
  <a class="carousel-control right homepage-carousel-control" href="#myCarousel" data-slide="next">&rsaquo;</a>
示例#5
0
    <? if (Yii::app()->params['less_dev_mode']) { ?>
        <link rel="stylesheet/less" type="text/css" href="/less/site.less?time=<?php 
echo time();
?>
">
        <? Yii::app()->clientScript->registerScriptFile('/js/less-1.3.0.min.js'); ?>
    <? } else { ?>
        <link rel="stylesheet" type="text/css" href="/css/site.css"/>
    <? } ?>

    <?php 
echo $this->renderPartial('//shared/_google_analytics');
?>

    <title><?php 
echo MyHtml::encode($this->pageTitle);
?>
</title>

    <?php 
$url = Yii::app()->createAbsoluteUrl(Yii::app()->request->url);
$split_url = explode("view/id/", $url);
$canon_url = $split_url[0];
if (count($split_url) > 1) {
    $second_split = explode("/", $split_url[1]);
    $canon_url = $canon_url . $second_split[0];
}
?>
    <link rel="canonical" href="<?php 
echo $canon_url;
?>
示例#6
0
<div class="tab-content">
	<?php 
foreach ($datasets as $dataset) {
    ?>
	<div class="search-result-container">
		<!--Dataset section-->		
		<div class="row">
			<div class="span1 logo-container"><img src="/images/icons/g.png"></div>
			<div class="span8 main-content">
				<ul class="nav nav-tabs nav-stacked result-cell">
				  <li><a data-content="<?php 
    echo MyHtml::encode($dataset->description);
    ?>
" class="result-main-link left content-popup" href="/dataset/<?php 
    echo $dataset->identifier;
    ?>
"><?php 
    echo $dataset->title;
    ?>
</a></li>
				  <li>
				  	<strong>
				  		<?php 
    echo $dataset->authorNames;
    ?>
				  	</strong>
				  </li>
				  <li class="searchID"><?php 
    echo Yii::t('app', 'DOI');
    ?>
:<?php 
示例#7
0
<?php 
$this->widget('CLinkPager', array('pages' => $pages));
?>

<div class="item">
<?php 
foreach ($userList as $n => $model) {
    echo MyHtml::encode($model->id);
    ?>
:
<?php 
    echo MyHtml::link($model->email, array('show', 'id' => $model->id));
    ?>
 (<?php 
    echo MyHtml::encode($model->email);
    ?>
)
 (<strong><?php 
    echo MyHtml::encode($model->getRole());
    ?>
</strong>)
<br/>

<?php 
}
?>
</div>
<br/>
<?php 
$this->widget('CLinkPager', array('pages' => $pages));
示例#8
0
        $active="active";
        $itemPerSlide=3;
        $i=0;
        foreach ($news as $key=>$temp_news){
            if($i%$itemPerSlide==0)  {?>
            <div class="<? echo $active; ?> item">
            <? }?> 
                <div class="data-block">
                  <h4><?php echo MyHtml::encode($temp_news->title); ?></h4>
                  <p>
                    <? echo '<br/>';

                    if(strlen($temp_news->body) > 100){
                      echo MyHtml::encode(substr($temp_news->body,0,100)." ...");
                    }else {
                      echo MyHtml::encode($temp_news->body);
                    }
                    ?>
                  </p>
                  <?
                  echo MyHtml::link("See More", array("news/view",'id'=>$temp_news->id));
                  ?>
                </div>
            <?php
            if($i%$itemPerSlide==($itemPerSlide-1) || $i==count($news)-1 ) {?>
                </div>
            <? }
            $i++;
            $active="";
        } ?>
      </div>
示例#9
0
                <? } else { ?>
                    <td class="content-popup" data-content="<? echo MyHtml::encode($data[$i]->description); ?>">
                        <? echo MyHtml::link("10.5524/" . $data[$i]->identifier, "/dataset/" . $data[$i]->identifier, array('target' => '_blank')); ?>
                    </td>
                <? } ?>
                <td class="left content-popup" data-content="<? echo MyHtml::encode($data[$i]->description); ?>"><? echo $data[$i]->title; ?> </td>
                <td><? echo $data[$i]->commonNames; ?> </td>
                <td >
                    <? foreach ($data[$i]->datasetTypes as $type) { ?>
                        <?= $type->name ?>

                    <? } ?>
                </td>
                <td><?= MyHtml::encode($data[$i]->upload_status) ?></td>
                <td><? echo MyHtml::encode($data[$i]->publication_date); ?> </td>
                <td><? echo MyHtml::encode($data[$i]->modification_date); ?> </td>
                <td><? echo count($data[$i]->files); ?></td>
                <td>
                  <? if ($data[$i]->upload_status !='Published' && $data[$i]->upload_status!='Pending' && $data[$i]->upload_status!='Private'){ ?>
                    <a class="update" title="Update" href=<? echo "/dataset/datasetManagement/id/" . $data[$i]->id ?> ><img src="/images/update.png" alt="Update" /></a>
                    <a class="js-delete-dataset" did="<?=$data[$i]->id?>"  title="Delete"><img alt="Delete" src="/images/delete.png"></a>
                  <? } ?>
                </tr>
            <? } ?>
    </table>
</div>
<script>
    $(".hint").tooltip({'placement': 'left'});

    $(".js-delete-dataset").click(function(e) {
        if (!confirm('Are you sure you want to delete this item?'))
示例#10
0
	<b><?php 
echo MyHtml::encode($data->getAttributeLabel('description'));
?>
:</b>
	<?php 
echo MyHtml::encode($data->description);
?>
	<br />

	<b><?php 
echo MyHtml::encode($data->getAttributeLabel('publisher'));
?>
:</b>
	<?php 
echo MyHtml::encode($data->publisher_id);
?>
	<br />

	<?php 
/*
	<b><?php echo MyHtml::encode($data->getAttributeLabel('dataset_size')); ?>:</b>
	<?php echo MyHtml::encode($data->dataset_size); ?>
	<br />
<b><?php echo MyHtml::encode($data->getAttributeLabel('ftp_site')); ?>:</b>
	<?php echo MyHtml::encode($data->ftp_site); ?>
	<br />
<b><?php echo MyHtml::encode($data->getAttributeLabel('upload_status')); ?>:</b>
	<?php echo MyHtml::encode($data->upload_status); ?>
	<br />
<b><?php echo MyHtml::encode($data->getAttributeLabel('excelfile')); ?>:</b>
示例#11
0
                        if ($project->image_location)
                            echo "<a href='$project->url'><img src='$project->image_location' /></a>";
                        else
                            echo MyHtml::link($project->name, $project->url);

                        echo "<br/>";
                    }
                    ?>
                </p>
                <? } ?>
        </div>


        <!--dataset Image - right slidebar-->
        <div class="span3 data-img">
            <h3><? echo MyHtml::encode(implode(", ", $model->getDatasetTypes()));?></h3>
            <?php if($model->image) { 
                $url = $model->getImageUrl() ? $model->getImageUrl(): $model->image->image('image_upload');
                ?>
            <a href="<?= $url ?>" >
                <?= CHtml::image($url, $url, array('class'=>'image-hint',
                    'title'=>'<ul style="text-align:left;"><li>'.$model->image->tag.'</li><li>'.'License: '.$model->image->license.'</li><li>'.'Source: '.$model->image->source.'</li><li>'.'Photographer: '.$model->image->photographer.'</li></ul>')); ?>
            </a>
            <?php } ?>
            <br/>
            <?php if($model->datasetFunders) { ?>
            <div style="margin-top:20px;">
                <h4>Funding:</h4>
                <!--get information for Funding-->
                    <?php foreach($model->datasetFunders as $fd) { ?>
                    <ul class="funding-list">
示例#12
0
<?php

$this->pageTitle = Yii::app()->name . ' - Error';
$this->breadcrumbs = array('Error');
?>

<h2>Error <?php 
echo $code;
?>
</h2>

<div class="error">
<?php 
echo MyHtml::encode($message);
?>
</div>
示例#13
0
</th>
    <td><?php 
echo MyHtml::encode($user->last_name);
?>
</td>
</tr>

<tr>
	<th class="label"><?php 
echo MyHtml::encode($user->getAttributeLabel('role'));
?>
</th>
    <td><?php 
echo MyHtml::encode($user->role);
?>
</td>
</tr>

<tr>
	<th class="label"><?php 
echo MyHtml::encode($user->getAttributeLabel('newsletter'));
?>
</th>
    <td><?php 
echo $user->newsletter ? 'Yes' : 'No';
?>
</td>
</tr>

</table>