Random Number between 1-10 (with no 0) in MySQL
FLOOR( 1 + RAND( ) *10 )

祝日 / Permanent Vacation

Andulka
🪼
RMH
YOU ARE THE REASON
Stranger Things
Today's Document
DEAR READER

Origami Around
hello vonnie
$LAYYYTER

No title available
he wasn't even looking at me and he found me
Monterey Bay Aquarium

@theartofmadeline
art blog(derogatory)
One Nice Bug Per Day
styofa doing anything
No title available

#extradirty
seen from United Kingdom
seen from United States
seen from Mexico

seen from United States

seen from United Kingdom
seen from Belgium
seen from Mexico

seen from United States

seen from Türkiye

seen from United States
seen from United States
seen from United States
seen from United States
seen from United States
seen from United States

seen from United States
seen from United States

seen from Canada

seen from United Arab Emirates
seen from France
@rafaelcerrejon
Random Number between 1-10 (with no 0) in MySQL
FLOOR( 1 + RAND( ) *10 )
Plugin des Monat :)
Fluid template, get the uri from a file reference object: {variableName.originalResource.identifier}
Rafael Cerrejon
Error Display in Typo3
(In localconf.php): $TYPO3_CONF_VARS['SYS']['displayErrors'] = '1'; OR $TYPO3_CONF_VARS['SYS']['displayErrors'] = '2'; $TYPO3_CONF_VARS['SYS']['devIPmask'] = 'Ihre IP Adresse'; it´s like (plain PHP): ini_set('display_errors', 1); error_reporting(E_ALL);
Typoscript to remove clear.gif in Typo3
Constants:
content.headerSpace = 0|0 content.space = 0|0
Setup:
tt_content.image.20.spaceBelowAbove = 0 tt_content.header.stdWrap.space = 0|0 tt_content.stdWrap.space = 0|0 tt_content.stdWrap.spaceBefore = 0 tt_content.stdWrap.spaceAfter = 0 tt_content.textpic.20.spaceBelowAbove = 0 tt_content.image.20.spaceBelowAbove = 0 tt_content.textpic.20.noStretchAndMarginCells = 1 tt_content.image.20.noStretchAndMarginCells = 1 lib.stdheader.stdWrap.space = 0|0 lib.stdheader.10.stdWrap.wrap = |
This Frontend editor it´s just AWESOME, give it a try !
CSS Div List even/odd
Typo3 Extbase FindBy m:m relation
Repository
public function findByCategories($categories) { $query = $this->createQuery(); foreach ($categories as $category) { $constraint[] = $query->contains('category', $category); } $result = $query->matching($query->logicalAnd($query->logicalAnd($constraint)))->execute(); if (count($result) > 0) { return $result; } }
Controller
//Find items by Categories $itemByCat = $this->yourRepository->findByCategories($item->getCategory()); $this->view->assign('itemsbycategories', $itemByCat);
Typo3: Change html "Lang" attribute
If you want to change the language of <html lang="es">
Just add this to your TypoScript Setup with your language:
config.htmlTag_langKey = de
CSS: Absolute Center Horizontal and Vertical
CSS in order to center an element (with position absolute) in a container:
.zoomIcon { background: url("/fileadmin/images/zoomIcon.png") no-repeat transparent; width:64px; height:64px; position:absolute; left:50%; top:50%; margin-left:-32px; /* half of the width */ margin-top:-32px; /* half of the height */ }
Typo3: Extension Builder, upload multiple images
I found a problem with the Extension builder to upload multiple images, because when you set multiple files in the backend from your extension, only one it´s uploaded:
Here it´s my solution:
The Configuration/TCA/your_tca.php (minitems and maxitems IMPORTANT):
'gallery' => array( 'exclude' => 0, 'label' => 'LLL:EXT:yourgallery/Resources/Private/Language/locallang_db.xlf:tx_yourgallery_domain_model_gallery.gallery', 'config' => array( 'type' => 'group', 'internal_type' => 'file', 'uploadfolder' => 'uploads/tx_yourgallery', 'show_thumbs' => 1, 'size' => 5, 'allowed' => $GLOBALS['TYPO3_CONF_VARS']['GFX']['imagefile_ext'], 'disallowed' => '', 'minitems' => '0', 'maxitems' => '99' ), ),
Now let´s take a look in our model, we have the problem because it return a string and we need an Array, solution (of course in "\Classes\Domain\Model\YourModel.php"):
/** * Returns the gallery * * @return string $gallery */ public function getGallery() { $imagesArray = array(); if(empty($this->gallery)){ return false; } else { $imagesArray = explode(',', $this->gallery); } return $imagesArray; }
Finally, we can use that array as always in our "\Resources\Private\Partials\Gallery\Properties.html" Fluid Template:
<f:for each="{gallery.gallery}" as="image"> <a href="uploads/tx_yourgallery/{image}" class="lightbox" style="display: none;"></a> </f:for>
If you have a better solution, leave a comment, but I think it´s pretty simple approach. Viel Spaß.
The Responsinator is designed to test responsive websites on different device resolutions
<LOAD “CAS:”,R> Blog turned 1 today!
Awesome
Database replace bad characters to german characters (SQL)
Browser Statistics December 2013