php


Display posts on homepage - Custom PHP CMS


So I had recently viewed a tutorial on how to build my own CMS Codecourse CMS tutorials and after watching all videos I still have a problem.
I want to display in my frontpage the articles published but no as a series of list items. I want to show them more like the wordpress type.
this is the code inserted in the index.php file:
<?php
require 'app/start.php';
$pages = $db->query("
SELECT id, label, slug
FROM pages
")->fetchAll(PDO::FETCH_ASSOC);
require VIEW_ROOT . '/home.php';
?>

Related Links

How to check if a string contains a substring - mysql
Check, if is allowed embedding ( youtube video ) PHP, new youtube API [closed]
XAMPP .htaccess mod_rewrite not working
connect php with access database without using odbc bridge
PHP and JSON. How to get a specific element? //Multidimensional Array
Way to add multiple documents to Solr V5 from Mysql results in PHP
Yii2 migration problems
PHP can't pass a variable from one file to an include file : Undefined variable
Deploying Zend Application gives error Autoloader class must implement Zend\Loader\SplAutoloader
How to make normal arrays become a dimension array based on the first item?
How to sort sql output by division of two rows?
How to align left and right on same line in mpdf
Email div text content using PHP mail function
store multiple images for one product
How to make a dynamic json list/array with database values
programming, logic using gloabal variables

Categories

HOME
spring-data
windows-8.1
focus
ios-simulator
navigation
share
cisco
gtk
fasm
buffer
mahout-recommender
pinterest
l20n
rpmbuild
google-sites
tfsbuild
nullreferenceexception
spring-shell
activeadmin
coreldraw
function-points
fstar
clipboard
bonita
microprocessors
objectmapper
cucumber-junit
overwrite
android-canvas
stackpanel
cartopy
recovery
grunt-contrib-watch
game-center
resampling
robust
jenkins-slave
adblock
icecast
brightscript
non-linear-regression
jgrapht
dblink
yargs
nunit-console
nsdata
cdo.message
powerpoint-2013
adjacency-list
textblock
mercurial-extension
gdl
mousehover
mixins
canopy
unhandled
search-form
green-threads
google-gdk
unidata
whitespace-language
iplimage
visual-c++-2012
coding-efficiency
senchatouch-2.4
neo4jphp
pageviews
windows-taskbar
saga
ggts
pacman
html-frames
cgrectmake
popup-blocker
exponent
haiku
datacontracts
qt-mobility
upshot
css-friendly
pyjamas
hungarian-notation
resharper-5.1
aspbutton
oracle-pro-c
facebook-fbml
spring-modules
powergui
.net-client-profile
efs
rootkit

Resources

Encrypt Message