• Jetzt anmelden. Es dauert nur 2 Minuten und ist kostenlos!

Frage zu foreach (array()

burn4ever

Mitglied
Hallo,
ich arbeite mit einer Typo3 Extension
und habe u.a. folgendes Skript:
PHP:
    /**
     * Creates the single view.
     *
     * @param integer UID of the realty object for which to create the single
     *                view, must be > 0
     */
    private function createSingleView($uid) {
        $this->setPageTitle($uid);

        $hasTextContent = FALSE;
        $configuredViews = t3lib_div::trimExplode(
            ',', $this->getConfValueString('singleViewPartsToDisplay'), TRUE
        );

        foreach (array(
            'nextPreviousButtons', 'heading', 'address', 'description', 'price', 'provision',
            'overviewTable', 'offerer', 'contactButton', 'googleMaps',
            'addToFavoritesButton', 'furtherDescription', 'imageThumbnails',
            'backButton', 'printPageButton',
        ) as $key) {
            $viewContent = in_array($key, $configuredViews)
                ? $this->getView($uid, $key)
                : '';

            $this->setSubpart($key, $viewContent, 'field_wrapper');
            if (($viewContent != '') && ($key != 'imageThumbnails')) {
                $hasTextContent = TRUE;
            }
        }

        $this->hideActionButtonsIfNeccessary($configuredViews);
        // Sets an additional class name if the "image thumbnails" view
        // is activated.
        $this->setMarker(
            'with_images',
            in_array('imageThumbnails', $configuredViews) ? ' with-images' : ''
        );

        if (!$hasTextContent) {
            $this->hideSubparts('field_wrapper_texts');
        }
    }
Ich möchte nun das html Template mit einem weiter Parameter (PROVISION) erweitern.
Diesen habe ich auch oben in der php bereits eingetragen, unter "foreach (array(.....provision..... Ich gehe mal davon aus das dieser bezeichner richtig ist da er auch an anderen stellen via Typoscript im Backend so verwendet wird.

Mein html Template habe ich um den Parameter <!-- ###FIELD_WRAPPER_PROVISION### --> erweitert.

Das Label ###LABEL_PROVISION### wird mir auch im Frontend richtig ausgegeben nur der Parameter ###PROVISION### nicht

Hier ein Auszug aus dem html Template:
HTML:
        <!-- ###FIELD_WRAPPER_PRICE### -->
        <div class="price">
            <!-- ###FIELD_WRAPPER_RENT_EXCLUDING_BILLS### -->
            <h4>###LABEL_RENT_EXCLUDING_BILLS###</h4>
            <p>###RENT_EXCLUDING_BILLS###</p>
            <!-- ###FIELD_WRAPPER_RENT_EXCLUDING_BILLS### -->
            <!-- ###FIELD_WRAPPER_BUYING_PRICE### -->
            <h4>###LABEL_BUYING_PRICE###</h4>
            <p>###BUYING_PRICE###</p>
               <!-- ###FIELD_WRAPPER_BUYING_PRICE### -->
              
            <!-- ###FIELD_WRAPPER_PROVISION### --><h4>###LABEL_PROVISION###</h4><p>###PROVISION###</p><!-- ###FIELD_WRAPPER_PROVISION### -->
            
         </div>
        <!-- ###FIELD_WRAPPER_PRICE### -->

Hat jemand eine Idee warum er das Label dargestellt wird aber der Preis (Provisione) nicht?

Ich poste auch gerne beide Dokumente komplett, wenn gewünscht.
 
Zurück
Oben