function verAction()
 {
     $this->view->subtitle = $this->info->sitio->noticias->ver->titulo;
     $noticia = new Noticias();
     $id = (int) $this->_request->getParam('id', 0);
     if ($id > 0) {
         $this->view->noticia = $noticia->fetchRow('id=' . $id);
     }
 }
 public function run()
 {
     $fecha = Carbon\Carbon::now();
     DB::table('noticias')->delete();
     Noticias::create(array('titulo' => 'Bienvenidos', 'contenido' => 'Tenemos el agrado de presentarte tu nuevo sistema web de control e información de condominios <br> Echa Un vistazo a traves de las opciones presentadas, ven uestros videos demostrativos o lee nuestro manual del usuario', 'persona' => 'Sistema', 'fecha' => $fecha));
     Noticias::create(array('titulo' => 'Informacion', 'contenido' => 'Puedes agregar tus propias noticias para compartirlas con el resto de los usuarios, aprovecha y promociona tus productos, o comparte imagenes de tus juntas de condominio, Se precavido', 'persona' => 'Sistema', 'fecha' => $fecha));
     DB::table('eventos')->delete();
     Eventos::create(array('razon' => 'Junta de Condominio', 'fecha_ini' => $fecha, 'fecha_fin' => $fecha, 'tiempo_ini' => $fecha->format('H:i:s'), 'tiempo_fin' => $fecha->addHours(2)->format('H:i:s')));
     db::Table('portadas')->delete();
     db::Table('portadas')->insert(array("id" => 1, "titulo" => "Mi Residencia esta la WEB!!", "media" => "slider1.jpg", "contenido" => "ResidenciasOnline.com"));
     db::Table('portadas')->insert(array("id" => 2, "titulo" => Config::get('var.nombre'), "media" => "slider0.jpg", "contenido" => "Bienvenido"));
     $this->command->info('Noticias Table Seed!');
 }
Example #3
1
 public function eliminarnoticia($id)
 {
     $noticia = Noticias::find($id);
     if ($noticia->user_id == Auth::user()->id || Auth::user()->admin == 1) {
         $noticia->delete();
         Session::flash('message', 'Noticia Borrada Correctamente');
         return Redirect::to("ver-noticias");
     } else {
         flashMessage("No posee los permisos para realizar esta acción", 'red');
         return Redirect::back();
     }
 }
 /**
  * Remove the specified resource from storage.
  *
  * @param  int  $id
  * @return Response
  */
 public function destroy($id)
 {
     if (Auth::user()->id == Noticias::find($id)->user_id || Auth::user()->admin == 1) {
         Noticias::destroy($id);
         return "true";
     } else {
         return "false";
     }
 }
<?php

include_once "../models/Datasource.php";
include_once "../models/NoticiasDao.php";
include_once "../models/Noticias.php";
include_once "../models/Variables.php";
$conn = new Datasource($dbhost, $dbName, $dbUser, $dbPassword);
$ndao = new NoticiasDao();
$titulo = $_POST["titulo"];
$enlace = $_POST["enlace"];
$descripcion = $_POST["descripcion"];
$nomfoto = $_POST["nomfoto"];
$noticia = new Noticias();
$dirnot = $_FILES["foto"]["tmp_name"];
$formatonot = substr($_FILES["foto"]["name"], strrpos($_FILES["foto"]["name"], "."));
//Obtener la última aparición del punto y por consiguiente, el formato
$destinonot = $notLocation . "/noti_" . $nomfoto . $formatonot;
$ruta = substr($destinonot, 3);
$noticia->setTitulo($titulo);
$noticia->setEnlace($enlace);
$noticia->setRuta($ruta);
$noticia->setDescripcion($descripcion);
if ($ndao->create($conn, $noticia) && move_uploaded_file($dirnot, $destinonot)) {
    ?>
		<meta http-equiv="REFRESH" content="0,url=../admin_noticias.php">
		<script type="text/javascript">
			alert("Noticia creada");
		</script>
		<?php 
} else {
    ?>
function PageNews(&$smarty, &$form)
{
    $tabela = $smarty->cfg['prefix'] . 'news';
    $smarty->assign($smarty->actualpage);
    $news = new Noticias($smarty, $form);
    $cfg = array("SetTable" => $tabela, "SetOrdenar" => $news->uri['por'], "SetOrder" => $news->uri["ord"], "SetCaption" => "*");
    $news->CreateSelectSQL($cfg, $smarty);
    $smarty->register_object("noticias", $news);
    $news->uri['tabela'] = $tabela;
    $news->uri['coluna'] = 'ID_NEWS';
    return $smarty->fetch("noticias_page.tpl");
}
        <section class="content">
          <div class="row">
            <div class="col-lg-12">
              <!-- Horizontal Form -->
              <div class="box box-info">
                <div class="box-header with-border">
                  <h3 class="box-title">Notícias</h3>
                  <!-- tools box -->
                  <div class="pull-right box-tools">
                    <button class="btn btn-info btn-sm" data-widget="collapse" data-toggle="tooltip" title="Collapse"><i class="fa fa-minus"></i></button>
                  </div><!-- /. tools -->
                </div><!-- /.box-header -->
                  <?php 
$id = $_POST["id"];
if (isset($_POST["exibir"])) {
    $exib = new Noticias();
    $comp = $exib->ShowNoticias($id);
    if ($exib != null) {
        ?>
                <div class="box-body">
                  <div class="form-group">
                    <div class="col-sm-7">
                      <?php 
        echo $comp->texto;
        ?>
                      <br>
                      <dl>
                        <dt>Escrito por:</dt>
                        <dd><?php 
        echo $comp->autor;
        ?>
                </div><!-- /.box-header -->
                <div class="box-body">
                  <div class="table-responsive">
                  <table id="dataT" class="table table-bordered table-hover dt-responsive nowrap">
                    <thead>
                      <tr>
                        <th>ID</th>
                        <th>Data</th>
                        <th>Notícia</th>
                        <th>Status</th>
                        <th>Opções</th>
                      </tr>
                    </thead>
                    <tbody>
                    <?php 
$listar = new Noticias();
$list = $listar->ListarNoticias();
//print_r($list);
if ($list != null) {
    foreach ($list as $line) {
        ?>
                    <tr class="odd gradeX">
                      <form name="view" action="EditNoticiaObj.php" method="post">
                        <td><?php 
        echo $line->id;
        ?>
</td>
                        <td><?php 
        echo date('d/m/Y', strtotime($line->data));
        ?>
</td>
Example #9
0
<?php

session_start();
if (empty($_SESSION['usuario'])) {
    echo '<script language="javascript">window.location="index.php"</script>';
}
require '../clases/class.db.php';
require '../clases/class.pagina.php';
require '../clases/class.noticias.php';
$configura = new Pagina();
$nombre = $configura->rescata('web');
$numero = $configura->rescata('numero');
$secciones = $configura->rescataSecciones($numero);
$noticias = new Noticias();
if (isset($_POST["crear"])) {
    $noticias->guarda();
}
if (isset($_POST["elimina"])) {
    $noticias->elimina($id = $_POST['id'], $titular = $_POST['titular'], $imagen = $_POST['imagen'], 'noticias');
    $noticias->eliminaNoticia($titular = $_POST['titular']);
}
if (isset($_POST["actualiza"])) {
    $noticias->actualiza();
}
?>

<!DOCTYPE html>
<html>
<head>
  <title><?php 
echo $nombre;
Example #10
0
        <section class="content-header">
            <h1>Noticias</h1>
        </section>
        <!-- Main content -->
        <section class="content">
          <div class="row">
            <div class="col-lg-12">
              <!-- Horizontal Form -->
              <div class="box box-success">
                <div class="box-header with-border">
                  <h3 class="box-title">Noticias</h3>
                </div><!-- /.box-header -->
                <?php 
$id = $_POST["id"];
if (isset($_POST["editar"])) {
    $edit = new Noticias();
    $comp = $edit->EditarNoticias($id);
    print_r($comp);
    var_dump($comp);
    if ($edit != null) {
        ?>
                <!-- form start -->
                <form class="form-horizontal" id="form" method="post" action="CrudNoticias.php" enctype="multipart/form-data">
                  <div class="box-body">
                      <div class="form-group">
                        <label class="col-sm-2 control-label"> Autor: </label>
                        <div class="col-sm-10">
                           <input type="text" value="Mercer" class="form-control" disabled>
                           <input type="hidden" name="autor" value="<?php 
        echo $comp->autor;
        ?>
Example #11
0
<?php

include 'includes/conf.inc.php';
include MODELS_PATH . 'model.Noticias.php';
$noticias_model = new Noticias();
$noticias = $noticias_model->fetchAllByPortada();
?>
<!doctype html>
<html lang="es">
<head>
	<meta charset="UTF-8">
	<title><?php 
echo TITLE;
?>
</title>
	<link rel="stylesheet" href="<?php 
echo CSS_PATH;
?>
styles.css">
	<link rel="stylesheet" href="<?php 
echo CSS_PATH;
?>
flexslider.css">
	<?php 
if (strpos($_SERVER['HTTP_USER_AGENT'], 'Chrome') == false) {
    ?>
<link rel="stylesheet" href="<?php 
    echo CSS_PATH;
    ?>
supersized.css"><?php 
}
<?php

include_once "../Librerias/Datasource.php";
include_once "../Librerias/Noticias.php";
include_once "../Librerias/NoticiasDao.php";
include_once "../Librerias/Variables.php";
$conn = new Datasource($dbhost, $dbName, $dbUser, $dbPassword);
$ndao = new NoticiasDao();
$titulo = $_POST["titulo"];
$contenido = $_POST["descripcion"];
$noticia = new Noticias();
$noticia->setTitulo($titulo);
$noticia->setContenido($contenido);
if ($ndao->create($conn, $noticia)) {
    ?>
		<meta http-equiv="REFRESH" content="0,url=../Interfaces/admon.php">
		<script type="text/javascript">
			alert("Noticia creada");
		</script>
		<?php 
} else {
    ?>
		<meta http-equiv="REFRESH" content="0,url=../Interfaces/admonNoticias.php">
		<script type="text/javascript">
			alert("Error creando la noticia");
		</script>
		<?php 
}
        <section class="content-header">
          <h1>Notícias</h1>
        </section>
        <!-- Main content -->
        <section class="content">
          <div class="row">
            <div class="col-lg-12">
              <!-- Horizontal Form -->
              <div class="box box-info">
                <div class="box-header with-border">
                  <h3 class="box-title">Confirmar exclusão da notícia</h3>
                </div><!-- /.box-header -->
               <?php 
$id = $_POST["id"];
if (isset($_POST["excluir"])) {
    $exib = new Noticias();
    $comp = $exib->SelectInfoNoticias($id);
    if ($exib != null) {
        ?>
                  <div class="box-body">
                     <div class="form-group">
                        <dl class="dl-horizontal">
                           <dt>Titulo da notícia:</dt>
                           <dd><?php 
        echo $comp->titulo;
        ?>
</dd>
                           <dt>Status:</dt>
                           <dd><?php 
        $badge = new Select();
        $badge->labelStatus($comp->status);
Example #14
0
<?php

session_start();
if (empty($_SESSION['usuario'])) {
    echo '<script language="javascript">window.location="index.php"</script>';
}
require '../clases/class.db.php';
require '../clases/class.pagina.php';
require '../clases/class.noticias.php';
$configura = new Pagina();
$nombre = $configura->rescata('web');
$opcion = $configura->rescata('slider');
$noticias = new Noticias();
if (isset($_POST["crear"])) {
    $noticias->guardaSlider();
}
if (isset($_POST["elimina"])) {
    $noticias->elimina($_POST['Eliid'], $_POST['Elititular'], $_POST['Eliimagen'], 'slider');
}
if (isset($_POST["actualiza"])) {
    $noticias->actualizaSlider();
}
?>

<!DOCTYPE html>
<html>
<head>
  <title><?php 
echo $nombre;
?>
 : Gestor</title>
Example #15
0
 ?>
                     </span>
                       </div>
                 <div>
                     <?php 
 echo CHtml::link(CHtml::image($rutabase . '/img/page_white_gear.png', "hola"), '#', '');
 ?>
                     <?php 
 echo CHtml::link('Opciones Documentos', Yii::app()->baseUrl . '/documentos/prefdoc', '');
 ?>
                 </div>
                 <div>
                 <?php 
 echo CHtml::link(CHtml::image($rutabase . '/img/ruler_triangle.png', "hola"), Yii::app()->user->ui->userManagementAdminUrl, '');
 ?>
                 <?php 
 echo CHtml::link(' Mi cuenta', Yii::app()->baseUrl . '/trabajadores/perfil', '');
 ?>
                 </div>
                <?php 
 if (Noticias::isAdminTablon()) {
     ?>
                         <div>
                              <?php 
     echo CHtml::link(CHtml::image($rutabase . '/img/sound.png', "hola"), Yii::app()->baseUrl . '/noticias/poraprobar', '');
     ?>
                             <?php 
     echo CHtml::link(' Avisos porpabrobar ', Yii::app()->baseUrl . '/noticias/poraprobar', '');
     ?>
                             <span class="label badge-warning">
                     <?php 
Example #16
0
 public static function consultaBusquedaPer($buscar, $id, $id2, $id3, $id4, $id5, $id6, $fi, $ff)
 {
     $seleccionar = Noticias::leftJoin('asignaciones', 'noticias.notAsignaciones', '=', 'asignaciones.asiId')->leftJoin('fuentes', 'asignaciones.asiFuentes', '=', 'fuentes.fueId')->leftJoin('responsables', 'asignaciones.asiResponsables', '=', 'responsables.resId')->where('notFecha', '>=', $fi)->where('notFecha', '<=', $ff)->where('notTitulo', 'like', $buscar)->where(function ($query) use($id, $id2, $id3, $id4, $id5, $id6) {
         $query->where('fueId', $id)->orWhere('fueId', $id2)->orWhere('fueId', $id3)->orWhere('fueId', $id4)->orWhere('fueId', $id5)->orWhere('fueId', $id6);
     })->orderBy('fueid')->orderBy('notFecha')->get(array('fueNombre', 'resNombre', 'notFecha', 'notTitulo', 'notContenido', 'notEnlace', 'notAutor'))->toArray();
     return $seleccionar;
     /*
         $queryFuentes="";
         $queryMatch= ' AND (MATCH (nt.notTitulo) AGAINST ("'.$buscar.'" IN NATURAL LANGUAGE MODE)) ';
         $queryFecha = ' AND notFecha >="'.$fi.'" AND notFecha <= "'.$ff.'" ';
         $querySelect='SELECT nt.notTitulo, nt.notContenido, nt.notAutor, nt.notEnlace, f.fueNombre, nt.notFecha, r.resNombre FROM noticias nt, asignaciones a, fuentes f, responsables r';
         if ($buscar!="") {
           $busqueda = DB::select($querySelect.' WHERE nt.notAsignaciones = a.asiId AND a.asiFuentes = f.fueId AND a.asiResponsables = r.resId '.$queryFuentes.$queryFecha.$queryMatch.' ;');
     
         }
     
         return $busqueda;
     */
 }
Example #17
0
        } else {
            $noImage = new Noticias();
            $noImage->noImageUp();
        }
        header("Location:ViewNoticiasObj.php?success");
    } else {
        header("Location:NoticiaObj.php?erro");
    }
} elseif (isset($_POST['excluir'])) {
    $object = new Noticias();
    $object->id = $_POST['id'];
    //print_r($object);
    $object->ExcluirNoticias();
    header("Location:ViewNoticiasObj.php?excluirOK");
} elseif (isset($_POST['atualizar'])) {
    $object = new Noticias();
    $object->id = $_POST['id'];
    $object->autor = $_POST['autor'];
    $object->data = $_POST['data'];
    $object->hora = $_POST['hora'];
    $object->titulo = $_POST['titulo'];
    $object->linha_apoio = $_POST['linha_apoio'];
    $object->status = $_POST['status'];
    $object->categoria = $_POST['categoria'];
    $object->noticia = $_POST['noticia'];
    $object->url = $_POST['url'];
    $object->AtualizarNoticias();
    $myUpload = new Upload($_FILES["imagem"]);
    $Up = $myUpload->noticiaUploadUpdate($_POST['id']);
    header("Location:ViewNoticiasObj.php");
}
 public function getPaginacion()
 {
     $datos = Noticias::paginate(3);
     return $this->layout->content = View::make('test.paginacion', compact("datos"));
 }
        </style>

       <link rel="stylesheet" href="styleIndex.css" type="text/css"/>
    <?php 
require_once 'clientes.inc.php';
require_once 'noticias.inc.php';
session_start();
$usuario = $_SESSION['user'];
$cliente = $_SESSION['cliente'];
$datos = $cliente->obtenerDatos($usuario);
$_SESSION['datos'] = $datos;
$nombre = $datos["Nombre"];
//Si la noticia esta creada la insertamos
if ($_REQUEST["nombreNoticia"] != null) {
    $noticia = new Noticias();
    $nombreNoticia = $_REQUEST["nombreNoticia"];
    $descripcionNoticia = $_REQUEST["noticia"];
    $urlNoticia = $_REQUEST["urlNoticia"];
    $noticia->insertarNoticia($nombreNoticia, $descripcionNoticia, $urlNoticia);
}
?>
        
        <title>PCNow! - Gestion Noticias :<?php 
echo $usuario;
?>
</title>
        <meta charset="UTF-8">
         
        <script type="text/javascript">
            function funcionGoogle(){
Example #20
0
 public static function InsertaCumple()
 {
     $matr = Trabajadores::model()->findall("cumple=:dato", array(":dato" => date("Y-m-d")));
     //solo puede haber un mensaje de onomastico por dia
     //
     //
     //
     /*echo "<br><br><br><br><br>".count($matr)."<br>";
     	 echo date("Y-m-d").'';*/
     $esto = Noticias::model()->find("tiponoticia='02' and aprobado='1' and fecha>=:fechita", array(":fechita" => date("Y-m-d")));
     /*var_dump($esto);
       yii::app()->end();*/
     //print_r($matr);
     //echo gettype($esto);
     if (count($matr) > 0 and $esto == null) {
         $cadena = "Feliz cumpleaños , el dia de hoy  :  ";
         for ($i = 0; $i < count($matr); ++$i) {
             $cadena = $cadena . $matr[$i]['nombres'] . " " . $matr[$i]['ap'] . " " . $matr[$i]['am'] . "   ";
         }
         $cadena = $cadena . "\n";
         $cadena = $cadena . "Muchas felicidades en este dia ....!";
         $mensaje = new Noticias();
         $mensaje->txtnoticia = $cadena;
         $mensaje->iduser = Confignoticias::model()->findBypK(1)->iduseradm;
         $mensaje->autor = Yii::app()->user->um->loadUserById($mensaje->iduser)->username;
         $mensaje->tiponoticia = '02';
         $mensaje->aprobado = 1;
         $mensaje->fechapropuesta = date('Y-m-d');
         $mensaje->fexpira = date('Y-m-d');
         if (!$mensaje->save()) {
             throw new CHttpException(500, 'NO s peudo grabra el noticin del cumple.');
         }
     }
     return 1;
 }
Example #21
0
<?php

class Noticias extends Eloquent
{
    protected $table = "noticias";
    protected $fillable = array('titulo', 'contenido', 'persona', 'user_id', 'fecha', 'media');
    public function user()
    {
        return $this->belongsTo('User');
    }
}
Noticias::observe(new NoticiaObserver());
class NoticiaObserver
{
    public function created($model)
    {
        if (Config::get('var.push', false)) {
            $dispositivos = Dispositivo::active()->mensajes()->get();
            $disp = [];
            foreach ($dispositivos as $dispositivo) {
                $disp[] = PushNotification::Device($dispositivo->token);
            }
            $actions = [];
            $actions[0] = new stdClass();
            $actions[0]->icon = 'eye';
            $actions[0]->title = 'ver';
            $actions[0]->callback = 'mycallback';
            $devices = PushNotification::DeviceCollection($disp);
            $message = PushNotification::Message($model->user->nombre . ' ha agregado una nueva noticia', ['badge' => 1, 'image' => 'www/logo.png', 'soundname' => 'alert', "ledColor" => [0, 146, 234, 255], 'title' => 'Nueva Noticia', 'actions' => $actions]);
            $collection = PushNotification::app('android')->to($devices)->send($message);
            // return $collection;
Example #22
0
 public function noticias($action)
 {
     if (isset($action)) {
         if ($action == "create") {
             $data = Noticias::firstOrCreate(Input::all());
             return $respuesta = array('Record' => $data, 'Result' => "OK");
         }
         if ($action == "edit") {
             Noticias::where("id", Input::get("id"))->update(Input::except("id"));
             return $respuesta = array('Record' => Noticias::find(Input::get('id')), 'Result' => "OK");
         }
         if ($action == "remove") {
             $path = Noticias::find(Input::get("id"))->media;
             Event::fire('eliminarArchivo', public_path() . "/images/" . $path);
             Noticias::where('id', Input::get("id"))->delete();
             return '{"Result":"OK"}';
         }
         if ($action == "list") {
             $Records = Noticias::get();
             $respuesta = array('Records' => $Records, 'Result' => "OK");
             return json_encode($respuesta);
         }
     }
 }
Example #23
0
 public static function getNoticia($id)
 {
     $noticias = new Noticias();
     return $noticias->fetchRow("id = '{$id}'");
 }
Example #24
0
 /**
  * Returns the data model based on the primary key given in the GET variable.
  * If the data model is not found, an HTTP exception will be raised.
  * @param integer $id the ID of the model to be loaded
  * @return Noticias the loaded model
  * @throws CHttpException
  */
 public function loadModel($id)
 {
     $model = Noticias::model()->findByPk($id);
     if ($model === null) {
         throw new CHttpException(404, 'The requested page does not exist.');
     }
     return $model;
 }
Example #25
0
        echo CHtml::link("Configuracion", Yii::app()->baseUrl . "/configuracion");
        ?>
</span>
            </li>
            <li>
                <span class="summary-icon2">
                    <img src="<?php 
        echo $baseUrl;
        ?>
/img/lock.png" width="25" height="25" alt="Datos maestros">
                </span>
                <span class="summary-title"> <?php 
        echo CHtml::link("Seguridad", Yii::app()->user->ui->userManagementAdminUrl);
        ?>
</span>
            </li>
            <li>
                <span class="summary-icon2">
                                        <img src="<?php 
        echo $baseUrl;
        ?>
/img/Cluster.png" width="20" height="20" alt="Datos maestros">
                </span>
                <span class="summary-title"> <?php 
        echo CHtml::link("Base de datos", Yii::app()->baseUrl . "/backup");
        ?>
</span>
            </li>
             <li>
                <span class="summary-icon2">
                    <img src="<?php 
            #iframeid{
                float: top;
            }

        </style>

       <link rel="stylesheet" href="styleIndex.css" type="text/css"/>
    <?php 
require_once 'clientes.inc.php';
require_once 'noticias.inc.php';
session_start();
$usuario = $_SESSION['user'];
$cliente = $_SESSION['cliente'];
$datos = $cliente->obtenerDatos($usuario);
$_SESSION['datos'] = $datos;
$noticia = new Noticias();
$nombre = $datos["Nombre"];
$vectorNoticias = $noticia->obtenerNoticias();
//Si no es el usuario el administrador
if ($usuario != "userAdmin") {
    echo '<script>alert("zona restringida solo administrador");</script>';
} else {
    //Si la noticia esta creada la insertamos
    if ($_REQUEST["nombreNoticia"] != null) {
        $nombreNoticia = $_REQUEST["nombreNoticia"];
        $descripcionNoticia = $_REQUEST["noticia"];
        $urlNoticia = $_REQUEST["urlNoticia"];
        //Variable guardamos si hay noticia repetida
        $notiRepetida = false;
        for ($i = 0; $vectorNoticias[$i] != null && $notiRepetida == false; $i++) {
            //Si hay una noticia con el mismo titulo no permitimos insertar
Example #27
0
 /**
  * Clone will return identical deep copy of this valueObject.
  * Note, that this method is different than the clone() which
  * is defined in java.lang.Object. Here, the retuned cloned object
  * will also have all its attributes cloned.
  */
 function cloneObject()
 {
     $cloned = new Noticias();
     $cloned->setIdNoticia($this->idNoticia);
     $cloned->setTitulo($this->titulo);
     $cloned->setContenido($this->contenido);
     return $cloned;
 }
To change this template file, choose Tools | Templates
and open the template in the editor.
-->
<html>
    <head>
    <?php 
require_once 'clientes.inc.php';
require_once 'noticias.inc.php';
session_start();
$usuario = $_SESSION['user'];
$cliente = $_SESSION['cliente'];
$datos = $cliente->obtenerDatos($usuario);
$_SESSION['datos'] = $datos;
$nombre = $datos["Nombre"];
//Para mostrar las noticias
$noticia = new Noticias();
$vectorNoticias = $noticia->obtenerNoticias();
?>


        <style type="text/css">
            
            #iframeid{
                float: top;
            }

        </style>
       <link rel="stylesheet" href="styleIndex.css" type="text/css"/>

        <title>PCNow!</title>
        <meta charset="UTF-8">
Example #29
0
<?php

/* @var $this NoticiasController */
/* @var $model Noticias */
/* @var $form CActiveForm */
?>

<div class="division">

<div class="wide form">

    <?php 
$administra = Noticias::isAdminTablon();
$form = $this->beginWidget('CActiveForm', array('id' => 'noticias-form', 'enableAjaxValidation' => false));
?>

    <?php 
echo "<div class='botones'>";
echo CHtmL::imageButton(Yii::app()->getTheme()->baseUrl . '/img/save.png', array());
echo "</div>";
?>


               <div class="row">

						<?php 
echo $form->labelEx($model, 'tiponoticia');
?>
						<?php 
$datos = array('01' => 'Aviso', '02' => 'Onomastico', '03' => 'Efemeride');
echo $form->DropDownList($model, 'tiponoticia', $datos, array('empty' => '--Seleccione un tipo--'));