12e3a57053
added position to advertisements. with it, one can choose to either show an horizontal add only at top, bottom or both. removed can_see_ads check from AdvertisementsHelper::print_advertisement() because it's already checked before calling it. horizontal-bottom ads in post#index are centered. removed "Reset hit count" checkbox in ads#edit. Width and Height in ads form are now "number" fields. Width and Height must now be set also for "Html" ads. made ads#show a little nicer. ads#create and ads#update redirect to ads#index if success. some other related changes. made ad#show a little nicer
69 lines
1.1 KiB
PHP
69 lines
1.1 KiB
PHP
<?php
|
|
return array (
|
|
0 =>
|
|
array (
|
|
'id' =>
|
|
array (
|
|
'type' => 'int(11)',
|
|
'default' => NULL,
|
|
),
|
|
'image_url' =>
|
|
array (
|
|
'type' => 'varchar(255)',
|
|
'default' => NULL,
|
|
),
|
|
'referral_url' =>
|
|
array (
|
|
'type' => 'varchar(255)',
|
|
'default' => NULL,
|
|
),
|
|
'ad_type' =>
|
|
array (
|
|
'type' => 'varchar(255)',
|
|
'default' => NULL,
|
|
),
|
|
'status' =>
|
|
array (
|
|
'type' => 'varchar(255)',
|
|
'default' => NULL,
|
|
),
|
|
'hit_count' =>
|
|
array (
|
|
'type' => 'int(11)',
|
|
'default' => '0',
|
|
),
|
|
'width' =>
|
|
array (
|
|
'type' => 'int(11)',
|
|
'default' => NULL,
|
|
),
|
|
'height' =>
|
|
array (
|
|
'type' => 'int(11)',
|
|
'default' => NULL,
|
|
),
|
|
'script' =>
|
|
array (
|
|
'type' => 'text',
|
|
'default' => NULL,
|
|
),
|
|
'html' =>
|
|
array (
|
|
'type' => 'text',
|
|
'default' => NULL,
|
|
),
|
|
'position' =>
|
|
array (
|
|
'type' => 'char(255)',
|
|
'default' => NULL,
|
|
),
|
|
),
|
|
1 =>
|
|
array (
|
|
'pri' =>
|
|
array (
|
|
0 => 'id',
|
|
),
|
|
),
|
|
)
|
|
; |